Install ntp
The ntp package has utilities and daemons that will synchronize your computer’s time to Coordinated Universal Time (UTC) via the NTP protocol and NTP servers. The ntp package includes ntpdate (a program for retrieving the date and time from remote machines via a network) and ntpd (a daemon which continuously adjusts system time). Install the ntp package:
# yum install ntp
How do I configure an NTP Client?
Simply edit /etc/ntp.conf file, enter:
# vi /etc/ntp.conf
Make sure the following line exists:
server ntp.server.com
Where,
ntp.server.com : the hostname or IP address of the site NTP server. For my network we use the default route.
You can also run ntpd using cron:
# echo '30 * * * * root /usr/sbin/ntpd -q -u ntp:ntp' > /etc/cron.d/ntpd
The above instructs crond to run ntpd and after setting the clock just exit, and the -u option instructs it to run as the ntp user.
rm /etc/localtime ln -s /usr/share/zoneinfo/UTC /etc/localtime






