Raspberry Pi Time Synch

Linux Random Raspberry Pi

The Raspberry Pi lacks a real time clock, which means that the time can drift, so much so that NTP fails to update the software clock because its skewed so much.

To resolve this you can do the following:

Add this to /etc/ntp.conf:

tinker panic 0

That will cause ntpd to sync despite the large clock offset.

sudo service ntpd stop

sudo ntpd -gq

sudo service ntpd start

Now run a “date” and check the time has synched as expected.

You can also try to create a cron job to force the synch to a remote server if the above still does not keep it in synch, Setting this every 5 minutes or 15 minutes interval should do the trick.

/etc/init.d/ntp stop

/usr/sbin/ntpdate -s time.nist.gov

/etc/init.d/ntp start

Leave a Reply

Your email address will not be published.