Keep your machine synchronized using NTP


Install the package : yum install ntp

Make a backup of the default config cp /etc/ntp.conf /etc/ntp.conf.default

Minimal and pretty safe /etc/ntp.conf : server server server server server server driftfile /var/lib/ntp/drift restrict default nopeer nomodify restrict

Make sure NTP daemon will start at boot : chkconfig ntpd on

Start the NTP service : service ntpd on

Verify if your server can reach the peers : `# ntpq -pn remote refid st t when poll reach delay offset jitter 3 u 33 64 3 31.031 -46784. 0.540 2 u 33 64 3 160.121 -46786. 0.490 2 u 31 64 3 46.861 -46782. 3.868 LOCAL(0) 10 l 30 64 3 0.000 0.000 0.001`

The port udp/123 should be opened in the router routing to the internet. Logs can be found under /var/log/messages

Thanks for reading this post!

Did you find an issue in this article?

- click on the following Github link
- log into Github with your account
- click on the line number containing the error
- click on the "..." button
- choose "Reference in new issue"
- add a title and your comment
- click "Submit new issue"

Your feedback is much appreciated! πŸ€œπŸΌπŸ€›πŸΌ

You can also drop me a line below!