diff options
author | Denys Vlasenko <vda.linux@googlemail.com> | 2018-07-26 13:45:33 +0200 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2018-07-26 13:45:33 +0200 |
commit | 871bd2abaccd042cba757831fc4461806e8f446d (patch) | |
tree | ab221fc5926efe14a09881b3da373785321e5637 | |
parent | 79153cb6bc5a39b00e3c43988a265804ac609837 (diff) | |
download | busybox-w32-871bd2abaccd042cba757831fc4461806e8f446d.tar.gz busybox-w32-871bd2abaccd042cba757831fc4461806e8f446d.tar.bz2 busybox-w32-871bd2abaccd042cba757831fc4461806e8f446d.zip |
examples/var_service: add /var/run flag file to ntp.script
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-rwxr-xr-x | examples/var_service/ntpd/ntp.script | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/examples/var_service/ntpd/ntp.script b/examples/var_service/ntpd/ntp.script index 8542181eb..6cd81014d 100755 --- a/examples/var_service/ntpd/ntp.script +++ b/examples/var_service/ntpd/ntp.script | |||
@@ -1,5 +1,4 @@ | |||
1 | #!/bin/sh | 1 | #!/bin/sh |
2 | |||
3 | # Note that there is no provision to prevent several copies of the script | 2 | # Note that there is no provision to prevent several copies of the script |
4 | # to be run in quick succession. In fact, it happens rather often | 3 | # to be run in quick succession. In fact, it happens rather often |
5 | # if initial syncronization results in a step. | 4 | # if initial syncronization results in a step. |
@@ -8,6 +7,9 @@ | |||
8 | # | 7 | # |
9 | # Script should be ready to deal with this. | 8 | # Script should be ready to deal with this. |
10 | 9 | ||
10 | # For other parts of the system which prefer to run only on the stable clock | ||
11 | echo "$1" >rundir/sync_status | ||
12 | |||
11 | dt=`date '+%Y-%m-%d %H:%M:%S'` | 13 | dt=`date '+%Y-%m-%d %H:%M:%S'` |
12 | 14 | ||
13 | echo "`tail -n 199 -- "$0.log" 2>/dev/null`" >"$0.log.$$" | 15 | echo "`tail -n 199 -- "$0.log" 2>/dev/null`" >"$0.log.$$" |