How to sync time on CentOS

Install Network Time Service (ntp) & ntpdate clients:

# yum install ntp ntpdate

Start ntpd service:

# systemctl enable ntpd
# systemctl start ntpd

Check status

# service ntpd.service status

Configure ntp servers:

# ntpdate -u -s

Check the sync status:

# timedatectl status

Finally, set the Hardware Clock from the System Clock

# hwclock -w


Leave a Reply

Your email address will not be published. Required fields are marked *