Category: NTP configuration

NTP Server Configuration for Windows and Linux

  |   By

Network Time Protocol has been developed to keep computers synchronized. All computers are prone to drift and accurate timing is essential for many time critical applications.

A version of NTP is installed on most versions of Windows (although a stripped down version called SNTP –Simplified NTP- is in older versions) and Linux but is free to download from

When synchronising a a network it is preferable to use a dedicated NTP server that receives a timing source from an atomic clock either via specialist radio transmissions or the GPS network. However, many Internet time references are available, some more reliable than others, although it must be noted Internet based time sources can’t be authenticated by NTP, leaving your computer vulnerable to threats.

NTP is hierarchical and arranged into stratum. Stratum 0 is timing reference, while stratum 1 is a server connected to a stratum 0 timing source and a stratum 2 is a computer (or device) attached to a stratum 1 server.

The Basic configuration of NTP is done using the /etc/ntp.conf file you have to edit it and place the IP address of stratum 1 and stratum 2 servers. Here is an example of a basic ntp.conf file:

server prefer (time server address such as


server stratum 3

Driftfile /etc/ntp/drift

The most basic ntp.conf file will list 2 servers, one that it wishes to synchronise too and an IP address for itself. It is good housekeeping to have more than one server for reference in case one goes down.

A server with the tag ‘prefer’ is used for a trusted source ensuring NTP will always use that server when possible. The IP address will be used in case of problems when NTP will synchonise with itself is. The drift file is where NTP builds a record of the system clock’s drift rate and automatically adjusts for it.

NTP will adjust your system time but only slowly. NTP will await at least ten packets of information before trusting the time source. To test NTP simply change your system clock by half an hour at the end of the day and the time in the morning should be correct.

MSF Technical Information

  |   By

The MSF transmission from Anthorn (latitude 54° 55′ N, longitude 3° 15′ W) is the principal means of disseminating the UK national standards of time and frequency which are maintained by the National Physical Laboratory. The effective monopole radiated power is 15 kW and the antenna is substantially omnidirectional. The signal strength is greater than 10 mV/m at 100 km and greater than 100 μV/m at 1000 km from the transmitter. The signal is widely used in northern and western Europe. The carrier frequency is maintained at 60 kHz to within 2 parts in 1012.

Simple on-off carrier modulation is used, the rise and fall times of the carrier are determined by the combination of antenna and transmitter. The timing of these edges is governed by the seconds and minutes of Coordinated Universal Time (UTC), which is always within a second of Greenwich Mean Time (GMT). Every UTC second is marked by an ‘off’ preceded by at least 500 ms of carrier, and this second marker is transmitted with an accuracy better than ±1 ms.

The first second of the minute begins with a period of 500 ms with the carrier off, to serve as a minute marker. The other 59 (or, exceptionally, 60 or 58) seconds of the minute always begin with at least 100 ms ‘off’ and end with at least 700 ms of carrier. Seconds 01-16 carry information for the current minute about the difference (DUT1) between astronomical time and atomic time, and the remaining seconds convey the time and date code. The time and date code information is always given in terms of UK clock time and date, which is UTC in winter and UTC+1h when Summer Time is in effect, and it relates to the minute following that in which it is transmitted.

Dedicated MSF NTP Server devices are available that can connect directly to the MSF transmission.

Information Courtesy of NPL

Atomic Clock Synchronisation using MSF

  |   By

Accurate time using Atomic Clocks is available across Great Britain and parts of northern Europe using the MSF Atomic Clock time signal transmitted from Cumbria, UK; it provides the ability to synchronize the time on computers and other electrical equipment.

The UK MSF signal is operated by NPL – the National Physical Laboratory. MSF has high transmitter power (50,000 watts), a very efficient antenna and an extremely low frequency (60,000 Hz). For comparison, a typical AM radio station broadcasts at a frequency of 1,000,000 Hz. The combination of high power and low frequency gives the radio waves from MSF a lot of bounce, and this single station can therefore cover most of Britain and some of continental Europe.

The time codes are sent from MSF using one of the simplest systems possible, and at a very low data rate of one bit per second. The 60,000 Hz signal is always transmitted, but every second it is significantly reduced in power for a period of 0.2, 0.5 or 0.8 seconds: • 0.2 seconds of reduced power means a binary zero • 0.5 seconds of reduced power is a binary one. • 0.8 seconds of reduced power is a separator. The time code is sent in BCD (Binary Coded Decimal) and indicates minutes, hours, day of the year and year, along with information about daylight savings time and leap years.

The time is transmitted using 53 bits and 7 separators, and therefore takes 60 seconds to transmit. A clock or watch can contain an extremely small and relatively simple antenna and receiver to decode the information in the signal and set the clock’s time accurately. All that you have to do is set the time zone, and the atomic clock will display the correct time.

Dedicated time servers that are tuned to receive the MSF time signal are available. These devices connect o a computer network like any other server only these receive the timing signal and distribute it to other machines on the network using NTP (Network Time Protocol).

Correcting Network Time

  |   By

Distributed networks rely completely on the correct time. Computers need timestamps to order events and when a collection of machines are working together it is imperative they run the same time.

Unfortunately modern PC’s are not designed to be perfect timekeepers. Their system clocks are simple electronic oscillators and are prone to drift. This is not normally a problem when the machines are working independently but when they are communicating across a network all sorts of problems can occur.

From emails arriving before they have been sent to entire system crashes, lack of synchronisation can causes untold problems across a network and it is for this reason that network time servers are used to ensure the entire network is synchronised together.

Network time servers come in two forms – The GPS time server and the radio referenced time server. GPS NTP servers use the time signal broadcast from GPS satellites. This is extremely accurate as it is generated by an atomic clock on board the GPS satellite. Radio referenced NTP servers use a long wave transmission broadcast by several national physics laboratories.

Both these methods are a good source of Coordinated Universal Time (UTC) the world’s global timescale. UTC is used by networks across the globe and synchronising to it allows computer networks to communicate confidently and partake of time sensitive transactions without error.

Some administrators use the Internet to receive a UTC time source. Whilst a dedicated network time server is not required to do this it does have security drawbacks in that a port is needed to be left open in the firewall for the computer to communicate with the NTP server, this can leave a system vulnerable and open to attack. Furthermore, Internet time sources are notoriously unreliable with many either too inaccurate or too far away to serve any useful purpose.

Utilising UTC

  |   By

To receive and distribute and authenticated UTC time source there are currently two types of NTP server, the GPS NTP server and the radio referenced NTP server. While both these systems distribute UTC in identical ways the way they receive the timing information differs.

A GPS NTP time server is an ideal time and frequency source because it can provide highly accurate time anywhere in the world using relatively cheap components.  Each GPS satellite transmits in two frequencies L2 for the military use and L1 for use by civilians transmitted at 1575 MHz, Low-cost GPS antennas and receivers are now widely available.

The radio signal transmitted by the satellite can pass through windows but can be blocked by buildings so the ideal location for a GPS antenna is on a rooftop with a good view of the sky. The more satellites it can receive from the better the signal. However, roof-mounted antennas can be prone to lighting strikes or other voltage surges so a suppressor is highly recommend being installed inline on the GPS cable.

The cable between the GPS antenna and receiver is also critical. The maximum distance that a cable can run is normally only 20-30 metres but a high quality coax cable combined with a GPS amplifier placed in-line to boost the gain of the antenna can allow in excess of 100 metre cable runs. This can provide difficulties in installation in larger buildings if the server is too far from the antenna.

An alternative solution is to use a radio referenced NTP time server. These rely on a number of national time and frequency radio transmissions that that broadcast UTC time. In Britain the signal (called MSF) is broadcast by the National Physics Laboratory in Cumbria which serves as the United Kingdom’s national time reference, there are also similar systems in the USA (WWVB) and in France, Germany and Japan.

A radio based NTP server usually consists of a rack-mountable time server, and an antenna, consisting of a ferrite bar inside a plastic enclosure, which receives the radio time and frequency broadcast. It should always be mounted horizontally at a right angle toward the transmission for optimum signal strength. Data is sent in pulses, 60 a second. These signals provides UTC time to an accuracy of 100 microseconds, however, the radio signal has a finite range and is vulnerable to interference.

2008 Will be a second longer Leap Second to be added to UTC

  |   By

New Year’s celebrations will have to wait another second this year as the International Earth Rotation and Reference Systems Service (IERS) have decided to 2008 is to have Leap Second added.

IERS announced in Paris in July that a positive Leap Second was to be added to 2008, the first since Dec. 31, 2005. Leap Seconds were introduced to compensate for the unpredictability of the Earth’s rotation and to keep UTC (Coordinated Universal Time) with GMT (Greenwich Meantime).

The new extra second will be added on the last day of this year at 23 hours, 59 minutes and 59 seconds Coordinated Universal Time — 6:59:59 pm Eastern Standard Time. 33 Leap Seconds have been added since 1972

NTP server systems controlling time synchronisation on computer networks are all governed by UTC (Coordinated Universal Time). When an additional second is added at the end of the year UTC will automatically be altered as the additional second. #

Whether a NTP server receives a time signal fro transmissions such as MSF, WWVB or DCF or from the GPS network the signal will automatically carry the Leap Second announcement.

Notice of Leap Second from the International Earth Rotation and Reference Systems Service (IERS)


61, Av. de l’Observatoire 75014 PARIS (France)
Tel.      : 33 (0) 1 40 51 22 26
FAX       : 33 (0) 1 40 51 22 91
e-mail    :

Paris, 4 July 2008

Bulletin C 36

To authorities responsible for the measurement and distribution of time

on the 1st of January 2009

A positive leap second will be introduced at the end of December 2008.
The sequence of dates of the UTC second markers will be:

2008 December 31,     23h 59m 59s
2008 December 31,     23h 59m 60s
2009 January   1,      0h  0m  0s

The difference between UTC and the International Atomic Time TAI is:

from 2006 January 1, 0h UTC, to 2009 January 1  0h UTC  : UTC-TAI = – 33s
from 2009 January 1, 0h UTC, until further notice       : UTC-TAI = – 34s

Leap seconds can be introduced in UTC at the end of the months of December

How a GPS Time Server Works

  |   By

A GPS time server is really a communication device. Its purpose is to receive a timing signal and then distribute it amongst all devices on a network. Time server s are often called different things from network time server, GPS time server, radio time server and NTP server.

Most time servers use the protocol NTP (Network Time Protocol). NTP is one of the Internet’s oldest protocols and is used by the majority of machines that use a time server. NTP is often installed, in a basic form, in most operating systems.

A GPS time server, as the names suggests, receives a timing signal from the GPS network. GPS satellites are really nothing more than orbiting clocks. Onboard each GPS satellite is an atomic clock. The ultra-precise time from this clock is what is transmitted from the satellite (along with the satellite’s position).

A satellite navigation system works by receiving the time signal from three or more satellites and by working out the position of the satellites and how long the signals took to arrive, it can triangulate a position.

A GPS time server needs even less information and only one satellite is required in order to receive a timing reference. A GPS time server’s antenna will receive a timing signal from one of the 33 orbiting satellites via line of sight, so the best place to fix the antenna is the roof.

Most dedicated GPS NTP time servers require a good 48 hours to locate and get a steady fix on a satellite but once they have it is rare for communication to be lost.

The time relayed by GPS satellites is known as GPS time and although it differs to the official global timescale UTC (Coordinated Universal Time) as they are both based on atomic time (TAI) GPS time is easily converted by NTP.

A GPS time server is often referred to as a stratum 1 NTP device, a stratum 2 device is a machine that receives the time from the GPS time server. Stratum 2 and stratum 3 devices can also be used as a time servers and in this way a single GPS time server can operate as a timing source for an unlimited amount of computers and devices as long as the hierarchy of NTP is followed.

How an Atomic Clock Works

  |   By

Atomic clocks are used for thousands of applications all over the world. From controlling satellites to even synchronising a computer network using a NTP server, atomic clocks have changed the way we control and govern time.

In terms of accuracy an atomic clock is unrivalled. Digital quartz clocks may keep accurate time for a week, not losing more than a second but an atomic clock can keep time for millions of years without drifting as much.

Atomic clocks work on the principle of quantum leaps, a branch of quantum mechanics which states that an electron; a negatively charged particle, will orbit a nucleus of an atom (the centre) in a certain plain or level. When it absorbs or releases enough energy, in the form of electromagnetic radiation, the electron will jump to a different plane – the quantum leap.

By measuring the frequency of the electromagnetic radiation corresponding to the transition between the two levels, the passage of time can be recorded. Caesium atoms (caesium 133) are preferred for timing as they have 9,192,631,770 cycles of radiation in every second. Because the energy levels of the caesium atom (the quantum standards) are always the same and is such a high number, the caesium atomic clock is incredibly precise.

The most common form of atomic clock used in the world today is the caesium fountain. In this type of clock a cloud of atoms is projected up into a microwave chamber and allowed to fall down under gravity. Laser beams slow these atoms down and the transition between the atom’s energy levels are measured.

The next generation of atomic clocks are being developed use ion traps rather than a fountain. Ions are positively charged atoms which can be trapped by a magnetic field. Other elements such as strontium are being used in these next generation clocks and it is estimated that the potential accuracy of a strontium ion trap clock could be 1000 times that of the current atomic clocks.

Atomic clocks are utilised by all sorts of technologies; satellite communication, the Global Positioning System and even Internet trading is reliant on atomic clocks. Most computers synchronise indirectly to an atomic clock by using a NTP server. These devices receive the time from an atomic clock and distribute around their networks ensuring precise time on all devices.

Arranging a NTP Server Stratum Tree

  |   By

NTP (Network Time Protocol) is the most widely used time synchronisation protocol on the Internet. The reason for its success is that is both flexible and highly accurate (as well as being free). NTP is also arranged into a hierarchical structure allowing thousands of machines to be able to receive a timing signal from just one NTP server.

Obviously, if a thousand machines on a network all attempted to receive a timing signal from the NTP server at the same time the network would become bottlenecked and the NTP server would be rendered useless.

For this reason, the NTP stratum tree exists. At the top of the tree is the NTP time server which is a stratum 1 device (a stratum 0 device being the atomic clock that the server receives its time from). Below the NTP server, several servers or computers receive timing information from the stratum 1 device. These trusted devices become stratum 2 servers, which in turn distribute their timing information to another layer of computers or servers. These then become stratum 3 devices which in turn can distribute timing information to lower strata (stratum 4, stratum 5 etc).

In all NTP can support up to nine stratum levels although the further away from the original stratum 1 device they are the less accurate the synchronisation. For an example of how a NTP hierarchy is setup please see this stratum tree