If you don’t have time to do it right, when will you have time to do it over? – John Wooden

I’m back again with a little tip, simple and quick to do to keep your Ubuntu Server’s time in sync, best of all there is no need to install an NTP client as Ubuntu comes with the ntpdate command which syncs the time of your system with the NTP Server you specified.  Cool Huh!

The fist command to know is the ntpdate command which is standard in the Ubuntu distributions. This command is also run at boot time, however if your like me you don’t reboot often and the system drifts.  The command looks something like this:

ntpdate ntp.ubuntu.com

Now for the fun part to set this thing up on a seclude to run every day. I used cron to do this using the following steps:

cd /etc/cron.daily/
touch ntpdate
nano ntpdate and add the following line: ntpdate
chmod 775 /etc/cron.daily/ntpdate

That’s it.