Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 26 May 2008 13:02:25 -0400
From:      "Jim Stapleton" <stapleton.41@gmail.com>
To:        freebsd-questions@freebsd.org
Subject:   ntpd - I'm sure I'm setting it up wrong, but I can't figure out how.
Message-ID:  <80f4f2b20805261002x3a875b36s88dc1ea4b38bca87@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
I'm trying to run ntpd to auto-update my computer's time (since I'm
not supposed to use ntpdate).

/etc/ntp.conf (I've tried without the restrict line):
========================================
server sushi.lyon.edu
restrict default ignore
driftfile /var/db/ntp.drift
========================================

I can get ntpdate to work fine with this command:
$ sudo ntpdate sushi.lyon.edu


I have tried this command (with and without the -g), with no success.
If I don't have an /etc/ntp.conf, it complains, and it stops
complaining when I put /etc/ntp.conf back where it belongs:
$ sudo  /usr/sbin/ntpd -q -g -f /var/db/ntpd.drift -l /var/log/ntpd.log

The contents of /var/log/ntpd.log:
========================================
26 May 11:46:43 ntpd[16353]: logging to file /var/log/ntpd.log
26 May 11:46:43 ntpd[16353]: ntpd 4.2.0-a Mon May 12 20:39:20 EDT 2008 (1)
26 May 11:46:43 ntpd[16353]: precision = 1.676 usec
26 May 11:46:43 ntpd[16353]: kernel time sync status 2040
26 May 11:47:04 ntpd[16353]: no reply; clock not set
========================================


To verify from the man page
  -q   update MY time, and exit
  -g   if the time difference is huge, just update, don't complain
  -f    drift file for heuristics so I don't have to update from the net.
  -l    log file


I've probably made a stupid mistake, but as far as I can gather from
the man pages, a few google searches, etc. This should work fine.

Any suggestions?
Thanks,
-Jim Stapleton



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?80f4f2b20805261002x3a875b36s88dc1ea4b38bca87>