Tuesday 12 September 2017

NTP synchronization


Upon un-expected power shutdown, my system date/time got changed upon reboot. Here is what I did to correct the situation:

My ntpsync.sh script is as follows:

# Instead of ntpdate (which is deprecated - http://linux.die.net/man/8/ntpd), use
# for older systems, you can use ntpdate like:
# $ sudo service ntp stop
# $ sudo ntpdate -s www.nist.gov
# $ sudo service ntp start

$ sudo service ntp stop
$ sudo ntpd -gq
$ sudo service ntp start

# The -gq tells the ntp daemon to correct the time regardless of the offset (g) and exit immediately (q).







3 comments:

  1. Needed to compose you a very little word to thank you yet again regarding the nice suggestions you’ve contributed here .. oracle training in chennai.

    ReplyDelete
  2. Oh, that's Great Post Thanks for sharing with us. This Big data hadoop training in Bangalore Platform helped me to learn advanced concepts of all the trending technologies out there in the current IT market. really worth trying them.

    ReplyDelete
  3. Your very own commitment to getting the message throughout came to be rather powerful and have consistently enabled employees just like me to arrive at their desired goals.
    Aws training chennai | AWS course in chennai
    Rpa training in chennai | RPA training course chennai

    ReplyDelete