Skip to main content

Synchronizing clock with NTP

Last Updated: May 4th, 2014

Installation

CentOS

yum install ntp ntupdate

Debian/Ubuntu

apt-get install ntp ntupdate

Configuring

Adding time servers (you can add other servers too)

nano /etc/ntp.conf

server time.nist.gov
server time-nw.nist.gov

Manually Updating

ntpdate time.nist.gov

Automatically Updating

Option 1

chkconfig ntpd on
service ntpd start

Option 2

To make it update at startup, add ntpdate time.nist.gov to /etc/rc.local