Date: Thu, 24 Apr 2008 06:39:46 -0700 From: David Newman <dnewman@networktest.com> To: freebsd-questions@freebsd.org Subject: ntpd not starting at boot time Message-ID: <48108DA2.1000502@networktest.com>
next in thread | raw e-mail | index | archive | help
I've installed ntp-4.2.4p4 from ports on a FreeBSD 6.3/i386 system. The ntpd process does not start at boot time. These lines exists in /etc/rc.conf: ntpd_enable="YES" ntpd_program="/usr/local/bin/ntpd" ntpd_flags="-c /etc/ntp.conf -p /var/run/ntpd.pid" ntpd_sync_on_start="YES" Manually running '/etc/rc.d/ntpd start' produces this error: Starting ntpd. ERROR: only one configfile option allowed I've pasted the contents of ntp.conf and /etc/rc.d/ntpd files below. Thanks in advance for clues as to what's missing. dn ###### # BEGIN /etc/ntp.conf ###### server 127.127.26.0 fudge 127.127.26.0 time1 -0.949 server t1.timegps.net server t2.timegps.net restrict 207.181.8.128 mask 255.255.255.192 nomodify notrap driftfile /var/db/ntp.drift ###### # END /etc/ntp.conf ###### ###### # BEGIN /etc/rc.d/ntpd ###### # PROVIDE: ntpd # REQUIRE: DAEMON ntpdate cleanvar devfs # BEFORE: LOGIN # KEYWORD: nojail . /etc/rc.subr name=ntpd rcvar=`set_rcvar` #command="/usr/sbin/${name}" command="/usr/local/bin/${name}" pidfile="/var/run/${name}.pid" start_precmd="ntpd_precmd" load_rc_config $name required_files="${ntpd_config}" ntpd_precmd() { rc_flags="-c ${ntpd_config} ${ntpd_flags}" if checkyesno ntpd_sync_on_start; then rc_flags="-g $rc_flags" fi if [ -z "$ntpd_chrootdir" ]; then return 0; fi # If running in a chroot cage, ensure that the appropriate files # exist inside the cage, as well as helper symlinks into the cage # from outside. # # As this is called after the is_running and required_dir checks # are made in run_rc_command(), we can safely assume ${ntpd_chrootdir} # exists and ntpd isn't running at this point (unless forcestart # is used). # if [ ! -c "${ntpd_chrootdir}/dev/clockctl" ]; then rm -f "${ntpd_chrootdir}/dev/clockctl" ( cd /dev ; /bin/pax -rw -pe clockctl "${ntpd_chrootdir}/dev" ) fi ln -fs "${ntpd_chrootdir}/var/db/ntp.drift" /var/db/ntp.drift # Change run_rc_commands()'s internal copy of $ntpd_flags # rc_flags="-u ntpd:ntpd -i ${ntpd_chrootdir} $rc_flags" } run_rc_command "$1" ###### # END /etc/rc.d/ntpd ######
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?48108DA2.1000502>