• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 384
  • Last Modified:

NTPD time is not synchronised after it is changed

I installed ntpd service on a server running CentOS. I set the different servers from which the daemon is polling every 65seconds. When I restart the service, the clock is automatically synchronized with NTP. However, if I use the linux command

date +%T -s "10:00:00"

for example, the clock is adjusted to this time, and even though the ntpd service is still running, this time does not synchronise back to the NTP time.

Can anyone help me please? I cannot find the reason why this update is not occurring

2 Solutions
Michael WorshamInfrastructure / Solutions ArchitectCommented:
Most likely the drift time is too high, thus why ntpd isn't resyncing. The ntp daemon won't adjust the local time if the offset is too great.  That's why a lot of ntpd startup scripts use ntpdate to sync the clock before startings ntpd.

Please paste the output of 'ntpq -p' here for further review.

nociSoftware EngineerCommented:
IF the time is too far out of sync NTP will not sync it anymore.
This is no bug, it is by design, if you have a good time provisioning then your clock might drift a little but not minutes away from the correct time.
So if a difference to TOO big you need (as a sysadmin ) to confirm the jerk to the right time (including all stuff that could happen to processes that might break under a timeshift to the future or back ward).

You can use ntpdate (ntpdate ntp-server ). to get that straight, you need to do:
  service  ntpd stop ; ntpdate .... ; service ntpd start

on the ... fill in the timeserver of choice (f.e. the one you have in your ntpd.conf

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now