openbsc: Improve the init scripts, do not write counters
Make the start/stop of the NITB, BSC and MGCP HW work, remove the
force-reload option as it didn't do anything and omit writing counters
into the database.
diff --git a/recipes-osmocom/openbsc/openbsc.inc b/recipes-osmocom/openbsc/openbsc.inc
index 1f71e4d..a372005 100644
--- a/recipes-osmocom/openbsc/openbsc.inc
+++ b/recipes-osmocom/openbsc/openbsc.inc
@@ -9,7 +9,7 @@
SRC_URI = "file://osmo-nitb.init \
file://osmo-bsc_mgcp.init \
file://osmo-bsc.init"
-INC_PR = "r12.${META_TELEPHONY_OSMO_INC}"
+INC_PR = "r13.${META_TELEPHONY_OSMO_INC}"
EXTRA_OECONF += " --enable-nat --enable-osmo-bsc "
diff --git a/recipes-osmocom/openbsc/openbsc/osmo-bsc.init b/recipes-osmocom/openbsc/openbsc/osmo-bsc.init
index dd0479a..c75e2db 100755
--- a/recipes-osmocom/openbsc/openbsc/osmo-bsc.init
+++ b/recipes-osmocom/openbsc/openbsc/osmo-bsc.init
@@ -34,14 +34,13 @@
start-stop-daemon -K -x "$DAEMON"
echo "$NAME."
;;
- restart|force-reload)
- echo -n "Restarting $DESC: "
- start-stop-daemon -K -x "$DAEMON"
- echo "$NAME."
+ restart)
+ $0 stop
+ $0 start
;;
*)
N=/etc/init.d/$NAME
- echo "Usage: $N {start|stop|restart|force-reload}" >&2
+ echo "Usage: $N {start|stop|restart}" >&2
exit 1
;;
esac
diff --git a/recipes-osmocom/openbsc/openbsc/osmo-bsc_mgcp.init b/recipes-osmocom/openbsc/openbsc/osmo-bsc_mgcp.init
index bfddac9..badd954 100755
--- a/recipes-osmocom/openbsc/openbsc/osmo-bsc_mgcp.init
+++ b/recipes-osmocom/openbsc/openbsc/osmo-bsc_mgcp.init
@@ -34,14 +34,13 @@
start-stop-daemon -K -x "$DAEMON"
echo "$NAME."
;;
- restart|force-reload)
- echo -n "Restarting $DESC: "
- start-stop-daemon -K -x "$DAEMON"
- echo "$NAME."
+ restart)
+ $0 stop
+ $0 start
;;
*)
N=/etc/init.d/$NAME
- echo "Usage: $N {start|stop|restart|force-reload}" >&2
+ echo "Usage: $N {start|stop|restart}" >&2
exit 1
;;
esac
diff --git a/recipes-osmocom/openbsc/openbsc/osmo-nitb.init b/recipes-osmocom/openbsc/openbsc/osmo-nitb.init
index 86c7f75..bd74cc0 100755
--- a/recipes-osmocom/openbsc/openbsc/osmo-nitb.init
+++ b/recipes-osmocom/openbsc/openbsc/osmo-nitb.init
@@ -11,7 +11,7 @@
DAEMON=/usr/bin/osmo-nitb
NAME=osmo-nitb
DESC="Osmocom GSM Network in the Box"
-NORMAL_ARGS="-D -c /etc/osmocom/osmo-nitb.cfg -l /var/lib/osmocom/hlr.sqlite3"
+NORMAL_ARGS="-C -D -c /etc/osmocom/osmo-nitb.cfg -l /var/lib/osmocom/hlr.sqlite3"
OSMOBTS_EXTRA_ARGS=""
NO_START=1
@@ -35,13 +35,12 @@
echo "$NAME."
;;
restart|force-reload)
- echo -n "Restarting $DESC: "
- start-stop-daemon -K -x "$DAEMON"
- echo "$NAME."
+ $0 stop
+ $0 start
;;
*)
N=/etc/init.d/$NAME
- echo "Usage: $N {start|stop|restart|force-reload}" >&2
+ echo "Usage: $N {start|stop|restart}" >&2
exit 1
;;
esac