There is/was a bug in the ntpdate implementation that set the clock
to a completely bogus value. So I’ve since written a simple script that
cron to fetch the time from a near NTP server.
You can find several download methods on the ntpsec website.
As of 2017-07-29, the is no port for ntpsec yet. So on FreeBSD you have to compile it yourself. Fortunately, this is not difficult.
You will need Python to build
ntpsec. Additionally, many of the helper
programs are written in Python. In this article, I’ll be using Python 3.6.
asciidoc program and the DocBook style sheets are needed to build the documentation.
Building the software
To build the software, I downloaded the source distribution from the FTP site. Cloning the repo from gitlab also worked.
Downloading a tarball from gitlab or github would complain about a missing
.autorevision-cache file during the build.
> python3 waf configure --prefix=/usr/local --python=/usr/local/bin/python3 > python3 waf build > cd build/main/ntpclients/ > sed -i '' -e 's/env python/env python3/' ntp* > cd - # python3 waf install
sed command is necessary because the scripts call python, not python3.
/etc/rc.d/ntpd seems to work well, provided I set the
following in my
ntpd_enable="YES" ntpd_program="/usr/local/sbin/ntpd" ntpd_sync_on_start="YES"
For comments, please send me an e-mail.
- Decoding temperature data logger files
- On the nature of GUI programs
- Have Python log to syslog
- Including binary data in Python scripts
- A simple feed reader for Youtube