You are not logged in.
Pages: 1
Hi all!
My system clock is perpetually off by 4 hours, and I've narrowed it down to an issue with Openntpd; it seems to be refusing to start at boot time. Here are the relevant lines from daemon.log:
Sep 1 21:30:26 raskolnikov ntpd[1440]: Terminating
and the output of ps aux | grep ntpd:
[raskolnikov@raskolnikov ~]$ ps aux | grep ntpd
ntp 1323 0.0 0.0 3184 700 ? S 17:32 0:00 /usr/sbin/ntpd -s
root 1332 0.0 0.0 3292 256 ? Ss 17:32 0:00 /usr/sbin/ntpd -s
1000 1412 0.0 0.0 3616 800 pts/0 S+ 17:33 0:00 grep ntp
I can manually restart the daemon via /etc/rc.d/openntpd restart, which works fine, and the time is set correctly. However, when I reboot, the adjustments are wiped out, and the daemon does not start again (same message in daemon.log). I have the default ntpd.conf. I have found very little helpful information on Google, I would greatly appreciate it if someone could point me in the right direction, I've wasted quite a few hours this evening working on this problem! Thanks!
Edit: Just in case it's helpful, here is my daemons array from rc.conf:
DAEMONS=(syslog-ng !network acpid eee hal networkmanager netfs crond openntpd bitlbee)
Last edited by happycodemonkey (2009-09-02 03:55:46)
<3 Arch
Offline
I've had this problem too, although I do not use networkmanager. I've found that openntpd fails to configure itself properly if the network is not up when it starts (in my case this happens when I background the network daemon and start openntpd in the daemons array).
My current working solution* is to add this line to rc.local:
(sleep 300 && /etc/rc.d/openntpd start) &
That will wait 5 minutes before starting the openntpd daemon which gives the network more than sufficient time to start. An alternative would be run "/etc/rc.d/openntpd restart" in an hourly cronjob if your network settings change often.
* Why not just unbackground the network daemon you ask? If the network isn't up then it takes a while to timeout and I don't want to wait to boot in that case.
Last edited by Xyne (2009-09-02 02:05:52)
My Arch Linux Stuff • Forum Etiquette • Community Ethos - Arch is not for everyone
Offline
Perfect! Thanks so much
<3 Arch
Offline
This has nothing to do with networkmanager, but if you use netcfg profiles, you could run "/etc/rc.d/openntpd start" as a POST_UP command. Thus it would run at the earliest possible time and it also wouldn't interfere with your daemons, Xyne.
Offline
@Runiq
I don't use netcfg, but I'll keep that in mind in case I ever do. Thanks.
My Arch Linux Stuff • Forum Etiquette • Community Ethos - Arch is not for everyone
Offline
Thank you for this solution!
joe@trusktr.io - joe at true skater dot io.
Offline
You could also maybe try static IP instead of dhcp. Static IP comes up in a snap, so there shouldn't be that dhcp lag which ntpd will be waiting on.
Offline
I have an idea! If you use networkmanager, why not put the "/etc/rc.d/openntpd" file into /etc/NetworkManager/dispatcher.d/ then that way openntpd will start as soon as networkmanager makes a connection.
In the wiki it says to put a slightly modified version into that folder, but it doesn't appear to work for me.
joe@trusktr.io - joe at true skater dot io.
Offline
In case anyone's wondering, my method in the previous post isn't working for some reason for me. Stick to the method detailed further above (for now).
joe@trusktr.io - joe at true skater dot io.
Offline
Pages: 1