There is a very serious bug in the previous version of 1.ntp4.2.4, when there are-g-x in the startup parameters of NTP, and when the server address is unreachable in the server in Ntp.config, it will appear either start,stop, Restart service will be error.
Error content: Starting ntpd:ERROR:only one panicgate option allowed
The description of this bug can be found in: https://bugzilla.redhat.com/show_bug.cgi?id=228424
WORKAROUND: 1. Upgrade the version. 2. Modify the startup parameters in the/ETC/SYSCONFIG/NTPD, and remove one of the "-g-x". (This method I did not try, but should be feasible)
2. After experimentation, I found that the NTPD service can be used as a school-time server or as a school-time client, and there is no need to use Ntpdate to synchronize with scheduled Tasks (cron), which can cause the system clock to jump and cause unpredictable consequences for running programs.
But the mainstream practice is to ntpdate through Cron, here is there I do not know why?
3.linux Modification Time Date:
Date–s: Modify Time by string
Can only modify the date, do not modify the time, enter: Date-s 2007-08-03
Only modified time, input: Date-s 14:15:00
Also modify the date time, note to add double quotation marks, the date and time there is a space between, enter:
#date-S "2007-08-03 14:15:00"
4.linux is a two clock, one is the system clock, the other hardware time clock. The system clock is initialized by reading the hardware time clock from the BIOS each time the system starts. Using both NTP and date to modify the time is to modify the system clock. In other words, when the system restarts, the clock will be in error. This can be corrected by the following parameters.
View BIOS Time # Hwclock--show
Set hardware time to System time # Hwclock--hctosys
Set the system time to hardware time # Hwclock--SYSTOHC
5.NTPD Start-up view, you can use Ntpstat and ntpq-p to see whether to start synchronization.
Just start the NTPD service, mainly through the ntpq-p look, if there is a line of the beginning is marked *, that the service has found a synchronization source, after at least 5-10 minutes to see the effect. And just when you start to see Ntpstat may still be out of sync.
NTP installation experience for Linux