How to setup NTP on Ubuntu to set the system time automatically.

To install NT on Linux and get the system time updating automatically, firstly install the NTP client.

[email protected]:~$ sudo apt-get install ntp

Then install the ntpdate utility.

sudo apt-get install ntpdate

Then you may synchronize the time on your machine with the Internet time server.

[email protected]:~$ sudo ntpdate -s time.nist.gov
[email protected]:~$ ntpstat 
synchronised to NTP server (129.250.35.250) at stratum 3 
   time correct to within 191 ms
   polling server every 256 s

This is how easy it is to synchronize the time on your Linux machine with an Internet time server. This is very important when the machine is a server and connected to the Internet.

No comments have been made. Use this form to start the conversation :)

Leave a Reply