athlon1800 peter # /etc/init.d/ntpd restart
* Stopping ntpd ...
start-stop-daemon: warning: failed to kill 347: No such process
1 pids were not killed
No process in pidfile `/var/run/ntpd.pid' found running; none killed.
* Failed to stop ntpd [ !! ]
* Starting ntpd ... [ ok ]
Apperently ntpd was no longer running. Looking at the logging might show the reason it is not running.
athlon1800 peter # cat /var/log/ntp.log
21 Feb 19:27:31 ntpd[347]: synchronized to 132.163.4.101, stratum 1
21 Feb 19:27:31 ntpd[347]: time correction of 4079 seconds exceeds sanity limit (1000); set clock manually to the correct UTC time.
Which I find ok, but I don't like it tries to kill 347 if this is no longer the ntp process. What happens if this pid is used for something else by the time I do a restart?
Reproducible: Didn't try
Steps to Reproduce:
1. distroy local time
2. wait for ntpd to complain in the log
3. /etc/init.d/ntpd restart
Actual Results:
See details
Expected Results:
ntpd should delete the /var/run/ntpd.pid file when it discovers an error and
terminates itself (just a guess)