Skip to content

Instantly share code, notes, and snippets.

@lilongen
Last active May 10, 2016 01:36
Show Gist options
  • Save lilongen/4bb7cfb89f46cde76bdd0dbcb07db173 to your computer and use it in GitHub Desktop.
Save lilongen/4bb7cfb89f46cde76bdd0dbcb07db173 to your computer and use it in GitHub Desktop.
enable ntp on centos
* install ntp
yum install ntp
* edit /etc/ntp.conf
server 0.pool.ntp.org
server 1.pool.ntp.org
server 2.pool.ntp.org
* enable ntp service
centos 7
systemctl enable ntpd
systemctl start ntpd
centos 6
chkconfig ntpd on
service ntpd start
* Synchronize the node.
ntpdate -u <your_ntp_server>
* Synchronize the system clock (to prevent synchronization problems).
hwclock --systohc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment