mirror of
https://github.com/opennetworkinglab/onos.git
synced 2025-10-16 18:02:05 +02:00
This commit bumps up karaf to 3.0.5. This commit also bumps up the jetty to 8.1.18.v20150929. Change-Id: I52849c38b535205db8c4e00e799b332f63b7e3f2
24 lines
703 B
Bash
Executable File
24 lines
703 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# Check if onos is running; if it is, stop onos
|
|
[ -z "$(status onos 2>/dev/null | grep start)" ] && echo "onos is not running." || (
|
|
stop onos
|
|
|
|
# Wait for onos to stop up to 5 seconds
|
|
for i in $(seq 1 5); do
|
|
[ -z "$(ps -ef | grep karaf.jar | grep -v grep)" ] && break
|
|
sleep 1
|
|
done
|
|
[ -z "$(ps -ef | grep karaf.jar | grep -v grep)" ] && echo 'Stopped onos service' || echo 'Failed to stop onos'
|
|
)
|
|
|
|
# Clean up onos runtime directories
|
|
# TODO don't hardcode karaf version
|
|
rm -rf /opt/onos/apache-karaf-3.0.5/
|
|
rm -rf /opt/onos/var/*
|
|
rm -rf /opt/onos/config
|
|
rm -rf /opt/onos/options
|
|
rm -rf /opt/onos/log
|
|
|
|
#TODO consider removing the sdn user if we created it
|