Dealing With Time computers synchronisation and timestamps

  |   By

Time is important for the smooth running of our day to day lives. Everything we do is either governed by or restrained because of time. Yet time is even more essential for computer systems as it is the only point of reference a computer has to distinguish between events and processes.

Everything a computer does is logged by the processor with what process was done and exactly when it was carried out. As computers can process hundreds if not thousands of transactions a second so the time stamp is vital for establishing the order of events.

Computers do not read and use the time in the same format that we do. A computer timestamp takes the form of a single digit that counts the number of seconds from a set point in time. In most systems this is known as the ‘prime epoch’ and is set from 00:00:00 UTC on January 1, 1970. So a timestamp for the date 23 June 2009 the timestamp would read: 1246277483 as this is the number of seconds from the prime epoch.

Computer timestamps are sent across networks and the internet, for instance every time an email is sent it is accompanied by a timestamp. When the email is replied to this too comes with a timestamp. Yet, when neither computer is synchronized the replied email could arrive back with an earlier code and this can cause untold confusion for a computer as according to its logs the email will have arrived back before the original was sent.

For this reason computer networks are synchronized to the global timescale UTC (Coordinated Universal Time). UTC is kept true by a constellation of atomic clocks which means that and computer network synchronised to a UTC source will be highly accurate.

Time synchronization on computers is dealt with by the protocol NTP (Network Time Protocol). Special dedicated NTP servers are available the receive a secure time code from either the GPS network or from specialist radio transmissions broadcast by national physical laboratories and then synchronize entire networks to the single time source.

Synchronizing the Time on your Computer

  |   By

Keeping accurate time is essential for many applications and dedicated NTP time servers make the job easy for network administrators. These devices receive an external time signal, often from GPS or sometimes from broadcast signals put out by organisations such as NIST, NPL and PTB (national physics labs from US, UK and Germany).

Synchronization with a NTP time server is made all the more easier thanks to NTP (network time protocol) this software protocol distributes the time source by constantly checking the time on all devices and adjusting any drift to match the time signal that is received.

Time synchronization is not just the concern of large networks. Even single machines and routers ought to be synchronised because at the very least it will help keep a system secure and make error detection a whole lot easier.

Fortunately, most versions of Windows contain a form of NTP. Often it is a simplified version but it is enough to allow a PC to be synchronized with the global time scale UTC (Coordinated Universal Time). On most Windows machines this is relatively easy to do and can be achieved by double clicking on the clock icon in the task bar then selecting a time provider in the internet time tab.

These time sources are internet based meaning that they are external to the firewall so a UDP port has to be left open to allow the time signal to enter. This can cause some security issues so for those wanting perfect synchronization without any security issues then the best solution is to invest in a dedicated time server. These need not be expensive and as they receive an atomic clock time signal externally then here is no breach in the firewall leaving your network secure.

A Guide to Using a GPS Clock

  |   By

The Global Positioning System much loved by drivers, pilots and sea-farers as a method of finding location offers much more than just satellite navigation information. The GPS system work by using atomic clocks that broadcast signals that are then triangulated by the computer in a satellite navigation system.

Because these atomic clocks are highly accurate and don’t drift by as much as a second even in a million years, they can be utilised as a method of synchronizing computer systems. GPS time, the time relayed by the GPS atomic clocks, is not strictly speaking the same as UTC (Coordinated Universal Time), the world’s global timescale, but as they are both based on International Atomic Time it can easily be converted. (GPS time is actual 17 seconds slower than UTC as there have been 17 leap seconds added to the global timescale since the GPS satellites where sent in to orbit).

A GPS clock is a device that receives the GPS signal and then translates it into the time. Most GPS clocks are dedicated time servers too as there is little point in receiving the exact time if you are to do nothing with it. GPS time servers use the protocol NTP (Network Time Protocol) which is one of the internet’s oldest protocols and designed to distribute timing information across a network.

A GPS clock, or GPS time server works by receiving a signal directly from the satellite. This unfortunately means the GPS antenna has to have a clear view of the sky to receive a signal. The time is then distributed from the time server to all devices on the network. The time on each device is regularly checked by NTP and if differs to the time from the GPS clock then it is adjusted.

Setting up a GPS clock for time synchronization is relatively easy. The time server (GPS clock) are often designed to fill a 1U space on a server rack. This is connected to the GPS antenna (usually on the roof) via a length of coax cable. The server is connected to the network and once it has locked on to the GPS system it can be set to begin synchronizing the network.

The Possibility of Time Travel

  |   By

Exploring the possibilities of time travel including: Time paradoxes, worm holes, 4 dimesnsional space, atomic clocks and NTP servers

Time travel has always been a much loved concept for science fiction writers. From HG Wells’ Time Machine to Back to the Future, travelling forwards or backwards in time has captivated audiences for centuries. However, thanks to the work of modern thinkers like Einstein, it appears that time travel is much a possibility of science fact as it is fiction.

Time travel is not only possible but we do it all the time. Every second that passes is a second further into the future so we are all travelling forward in time. However we think if time travel we imagine a machine that transports individuals hundreds or thousands of years in to the future or past so is that possible.

Well, thanks to Einstein’s theories of general and special relativity, time ravel is certainly possible. We know thanks to the development of atomic clocks that Einstein’s theories about speed and gravity affecting the passage of time is correct. Einstein suggested that gravity would warp space-time (the term he gave to four dimensional space that includes directions plus time) and this has been tested. In fact modern atomic clocks can pick out the minute differences in the passage of time every subsequent inch above the earth’s surface as time speeds up as the effect of the earth’ s gravity weakens.

Einstein predicted speed too would affect time in what he described as time dilation. For any observer travelling close to the speed of light a journey that to an outsider may have taken thousands of years would have passed within seconds. Time dilation means that travelling hundreds of years into the future in a matter of seconds is certainly possible. However, would it be possible to get back again?

This is where many scientists are divided. Strictly speaking theoretical properties of space time do allow for this, although for any travelling back in time a worm hole would have to be created or found. A worm hole is a theoretical link between two parts of space where a traveller could enter one end and appear somewhere completely different at the other end this may be another part of the universe or indeed another point in time.

However, critics of the possibility of time travel point out that because travellers from the future have never visited us that probably means that time travel will never be possible. They also point out the any travelling backwards in time could create paradoxes (what would happen to you if you were mean enough to go back in time and kill your grandparents).

However, time paradoxes exist now. Many computer networks are not synchronised which can lead to errors, loss of data or paradoxes like emails being sent before they were received. To avoid any time crisis it is important for all computer networks to be perfectly synchronised. The best and most accurate method of doing this is to use a NTP time server that receives the time from an atomic clock.

Do I Really Need an NTP Time Server?

  |   By

The NTP time server is a much misunderstood piece of equipment. They are quite simple devices in the sense that they are used for the purposes of time synchronisation, receiving an external source of the time which is then distributed throughout a computer network using NTP (Network Time Protocol).

However, with a myriad of ‘free’ time servers available on the internet many network administrators take the decision that NTP time servers are not necessary pieces of equipment and that their network can do without it. However, there are a huge number of pitfalls in relying on the internet as a time reference; Microsoft and the USA physics laboratory NIST (National Institute of Standards and Time) highly recommend external NTP time servers rather than internet providers.

Here is what Microsoft says:
“We highly recommend that you configure the authoritative Time Server to gather the time from a hardware source. When you configure the authoritative Time Server to sync with an Internet time source, there is no authentication.”

Authentication is a security measure implemented by NTP to ensure that the time signal that is sent comes from where it claims to come from. In other words authentication is the first line of defence in protecting against malicious users. There are other security issues too with using the internet as a time source as any communication with an internet time source is going to require the TCP/IP port to be left open in the firewall this could also be manipulated by malicious users.

NIST too recognise the importance of NTP time server systems for prevention and detection of security threats in their Guide to Computer Security Log Management they suggest:
“Organizations should use time synchronization technologies such as Network Time Protocol (NTP) servers whenever possible to keep log sources’ clocks consistent with each other.”

Choosing a Time Source what to do and what not to do

  |   By

Time synchronization is crucial for many of the applications that we do across the internet these days; internet banking, online reservation and even online auctions all require network time synchronization.

Failing to ensure their servers are adequately synchronized would mean many of these applications would be impossible to achieve; seat reservations could be sold more than once, lower bids could win internet auctions and it would be possible to withdraw you life savings from the bank twice if they didn’t have adequate synchronization (good for you not for the bank).

Even computer networks that on the face of it do not rely on time sensitive transactions also need to be adequately synchronized as it could be near impossible to track down errors or protect the system from malicious attacks if the timestamps on differ on various machines on the network.

Many organisations opt to use internet time servers as a source of UTC (Coordinated Universal Time) – the atomic clock controlled global timescale. Although there are many security issues in doing so such as leaving a hole in the firewall to communicate with the time server and not having any authentication for the time synchronization protocol NTP (Network Time Protocol).

However, in saying that many network administrators still opt to use online time servers as a UTC source regardless of the security implications although there are other issues that administrators should be aware of. On the internet there are two types of time server – stratum 1 and stratum 2. Stratum 1 servers receive a time signal direct from an atomic clock while stratum 2 servers receive a time signal from a stratum 1 server. Most internet stratum 1 servers are closed – unavailable to most administrators and there can be some shortfall in accuracy in using a stratum 2 server.

For the most accurate, secure and precise timing information external NTP time servers are the best option as these are stratum 1 devices that can synchronize hundreds of machines on a network to the exact same UTC time.

The Measuring of Time

  |   By

Measuring the passing of time has been a preoccupation of humans since the dawn of civilization. Broadly speaking, measuring time involves using some form of repetitive cycle to work out how much time has passed. Traditionally this repetitive cycle has been based on the movement of the heavens such as a day being a revolution of the Earth, a month being an entire orbit of the Earth by the moon and a year being earth’s orbit of the sun.

As our technology progressed we have been able to measure time in smaller and smaller increments from sundials that allowed us to count the hours, mechanical clocks that let us monitor the minutes, electronic clocks that let is for the first time accurately record seconds to the current age of atomic clocks where time can be measured to the nanosecond.

With the advancement in chronology that has led to technologies such as NTP clocks, time servers, atomic clocks, GPS satellites and modern global communications, comes with another conundrum: when does a day start and when does it finish.

Most people assume a day is 24 hours long and that it runs from midnight to midnight. However, atomic clocks have revealed to us that a day is not 24 hours and in fact the length of a day varies (and is actually increasing gradually over time).

After atomic clocks were developed there was a call from many sectors to come up with a global timescale. One that uses the ultra precise nature of atomic clocks to measure its passing but also one that takes into account the Earth’s rotation. Failing to account for the variable nature of a day’s length would mean any static timescale would eventually drift with day slowly drifting into night.

To compensate for this the world’s global timescale, called UTC (coordinated universal time) has additional seconds added (leap seconds) to ensure that there is no drift. UTC time is kept true by a constellation of atomic c clocks and it is utilised by modern technologies such as the NTP time server which ensures computer networks all run  the exact same precise time.

Germans Enter Race to Build the Worlds Most Accurate Clock

  |   By

Following the success of Danish researchers working in conjunction with NIST (National Institute for Standards and Time), who unveiled the world’s most accurate atomic clock earlier this year; German scientist have entered the race to build the world’s most precise timepiece.

Researchers at the Physikalisch-Technische Bundesanstalt (PTB) in Germany are using use new methods of spectroscopy to investigate atomic and molecular systems and hope to develop a clock based around a single aluminium atom.

Most atomic clocks used for satellite navigation (GPS), as references for computer network NTP servers and air traffic control have traditionally been based on the atom caesium. However, the next generation of atomic clocks, such as the one unveiled by NIST which is claimed to be accurate to within a second every 300 million years, uses the atoms from other materials such as strontium which scientists claim can be potentially more accurate than caesium.

Researchers at PTB have opted to use single aluminium atoms and believe they are on the way to developing the most accurate clock ever and believe there is huge potential for such a device to help us understand some of the more complicated aspects of physics.

The current crop of atomic clocks allow technologies such as satellite navigation, air traffic control and network time synchronisation using NTP servers but it is believed the increases accuracy of the next generation of atomic clocks could be used to reveal some of the more enigmatic qualities of quantum science such as string theory.

Researchers claim the new clocks will provide such accuracy they will even be able to measure the minute differences in gravity to within each centimetre above sea-level.

Milestones in Chronology From Crystals to Atoms

  |   By

Telling the time may seem a simple affair these days with the number of devices that display the time to us and with the incredible accuracy of devices such as atomic clocks and network time servers it is quite easy to see how chronology has been taken for granted.

The nanosecond accuracy that powers technologies such as the GPS system, air traffic control and NTP server systems (Network Time Protocol) is a long way from the first time pieces that were invented and were powered by the movement of the sun across the heavens.

Sun dials were indeed the first real clocks but they obviously did have their downsides – such as not working at night or in cloudy weather, however, being able to tell the time fairly accurately was a complete innovation to civilisation and helped for more structured societies.

However, relying on celestial bodies to keep track of time as we have done for thousands of years, would not prove to be a reliable basis for measuring time as was discovered by the invention of the atomic clock.

Before atomic clocks, electronic clocks provided the highest level of accuracy. These were invented at the turn of the last century and while they were many times more reliable than mechanical clocks they still drifted and would lose a second or two every week.

Electronic clocks worked by using the oscillations (vibrations under energy) of crystals such as quartz, however, atomic clocks use the resonance of individual atoms such as caesium which is such a high number of vibrations per second it makes the incredibly accurate (modern atomic clocks do not drift by even a second every 100 million years).

Once this type of time telling accuracy was discovered it became apparent that our tradition of using the rotation of the earth as a means of telling time was not as accurate as these atomic clocks. Thanks to their accuracy it was soon discovered the Earth’s rotation was not precise and would slow and speed up (by minute amounts) each day. To compensate for this the world’s global timescale UTC (Coordinated Universal Time) has additional seconds added to it once or twice a year (Leap seconds).

Atomic clocks provide the basis of UTC which is used by thousands of NTP servers to synchronise computer networks to.