We generally use the "date-s" command to modify the system time. For example, set the system time to the November 13, 2009 command as follows.
#date-S 11/13/09
The command to set the system time to 1:12 P.M. 0 seconds is as follows.
#date-S 13:12:00
----Note that this is the system time, Linux is maintained by the operating system.
----When the system starts, the Linux operating system reads the time from the CMOS to the system time variable, and later modifies the time by modifying the system time. To keep the system time consistent with the CMOS time, Linux writes the system time to the CMOS at intervals. Since this synchronization takes place every once in a while (about 11 minutes), after we perform date-s, if the machine is immediately reset, the modification time may not be written to CMOS, which is the cause of the problem. If you want to ensure that the changes take effect, you can execute the following command.
----#clock-W
----This command forces the system time to be written to the CMOS.
This article URL address: http://www.bianceng.cn/OS/Linux/201410/45423.htm