Synchronising your computer's clock
It's sound practice to make sure that the clock built in to your computer is properly set. An accurate time is reassuring and useful, and system administrators find it much easier to track down problems if the clock can be relied upon. Unfortunately, the clocks in most computers aren't very accurate and will 'drift' after being set. The good news is that the drift can be eliminated by arranging for automatic synchronisation with one of the special Time Servers on the Internet using the Network Time Protocol (NTP). Here's how.
Log on as administrator. Check the time is roughly correct, then click Start / Run..., and type
in the box. Click the OK button, and you should get a command prompt. Now type:
net time /setsntp:ntp0.ja.net net stop w32time net start w32time exit
Now check the service starts automatically:
Back in Windows, right-click "My Computer" and select Manage. Expand the Services and Applications branch and click to choose Services. Scroll down the list in the right-hand pane, and right-click "Windows Time". Select Properties, and ensure "Startup type" is set to automatic.
There are a number of ways to use NTP. The simplest (albeit not the most accurate) is to use the ntpdate command, specifying the name of the server you wish to synchronise with, thus:
ntpdate -s ntp0.ucl.ac.uk
To avoid drift, schedule this as a cron job, perhaps to run once an hour:
15 * * * * /usr/sbin/ntpdate -s ntp0.ucl.ac.uk
This is good enough for most purposes.
The above examples reference two real NTP servers:
is operated by UKERNA, the authority that manages the UK HEI network infrastructure, and
is run by UCL. If you are within UCL, you should use the local server.