I'm behind a firewall, so I can't access pool.ntp.org or Ubuntu's own time servers directly, and I'd like to change the time servers for my system. When googling, I find references to missing manpages like ntpd.conf(5) and ntpd(8), to a missing GUI for setting the time servers, and to a cron script (/etc/cron.daily/ntpdate) that doesn't seem to exist on my system. I've also found a reference to there being changes to ntpd.conf, so I'm hesitant to just create that file in /etc. How is one supposed to change the time servers in 11.10?
- 91
2 Answers
I don't know of the GUI you mention, but all the missing files sound like they're part of the ntp package.
sudo apt-get install ntp
should install them, then you'll have /etc/ntp.conf which you can edit. Once done, do:
service ntp restart
to reload your new config. The command
ntpq -pn
will show you the list of servers it's using (and various stats).
Most pools are set up to maintain time at the Stratum-12 to Stratum 16 level. You will get best time when the system is set to use use the Master Clock in Boulder, Colorado, which will give either Stratum-1 or 2.
NTP Server – Stratum Levels Explained
Excerpt:
Network Time Protocol is a hierarchical protocol and is divided into stratum which define the distance from the reference clock. A reference clock source that relays UTC (Coordinated Universal Time) time and has little or no delay is known as a stratum-0 device. Stratum-0 servers cannot be used on the network, instead, they are directly connected to computers which then operate as primary time servers.
A primary server that receives a time signal from a stratum 0 device either through the GPS network or national time and frequency transmission is known as a stratum-1 device. On a network a stratum 1 time server supplies the time to other devices on the network which are known as stratum-2 devices. These also can be used as a time source and equipment that connects to a stratum-2 device to receive it become stratum-3 and so on.
NTP can handle up to 16 different stratum levels, although the lower down the hierarchy you go the less accurate the devices become.
Here is a Q&A that describes how to set it up:
How do I set Ubuntu to use the primary time server time.nist.gov?
The settings are in /etc/ntp.conf and there is only a few changes that need to be made.
First is to comment out the lines that specify the pools.
Then add this line instead:
- 3,219
