aboutsummaryrefslogtreecommitdiffstats
path: root/meta-networking
diff options
context:
space:
mode:
authorWenzong Fan <wenzong.fan@windriver.com>2014-10-20 02:30:18 -0400
committerJoe MacDonald <joe_macdonald@mentor.com>2014-10-21 15:07:12 -0400
commit273ae8399e2bfa3b67bf062ced8e9291b58bba7b (patch)
tree138e52807f71b77f1e112029fb75a03b3559f627 /meta-networking
parentc78397ecdf85d25a31d2bfe0829abc933f25ee81 (diff)
downloadmeta-openembedded-contrib-273ae8399e2bfa3b67bf062ced8e9291b58bba7b.tar.gz
ntp: add status for initscript
Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com> Signed-off-by: Joe MacDonald <joe_macdonald@mentor.com>
Diffstat (limited to 'meta-networking')
-rwxr-xr-xmeta-networking/recipes-support/ntp/files/ntpd9
1 files changed, 8 insertions, 1 deletions
diff --git a/meta-networking/recipes-support/ntp/files/ntpd b/meta-networking/recipes-support/ntp/files/ntpd
index 3cd1c6c585e..d1b9c490762 100755
--- a/meta-networking/recipes-support/ntp/files/ntpd
+++ b/meta-networking/recipes-support/ntp/files/ntpd
@@ -20,6 +20,9 @@ test -x $DAEMON -a -r /etc/ntp.conf || exit 0
# rcS contains TICKADJ
test -r /etc/default/rcS && . /etc/default/rcS
+# Source function library.
+. /etc/init.d/functions
+
# Functions to do individual actions
settick(){
# If TICKADJ is set we *must* adjust it before we start, because the
@@ -68,8 +71,12 @@ case "$1" in
stopdaemon
startdaemon
;;
+ status)
+ status /usr/sbin/ntpd;
+ exit $?
+ ;;
*)
- echo "Usage: ntpd { start | stop | restart | reload }" >&2
+ echo "Usage: ntpd { start | stop | status | restart | reload }" >&2
exit 1
;;
esac