To synchronize time on a linux machine via a cron job using ntpdate.
0 2 * * * /usr/sbin/ntpdate -u pool.ntp.org
ntpdate is the program that goes to to the time server pool.ntp.org and updates the system time. The -u just tells it to use an unprivileged port.
Did this help you out? It took me a few days to piece together all this information together, I hope this saves you some time (who knows, maybe the future me will be thankful I wrote this down). Let me know your thoughts. email@example.com