Adjust the time In Debian

Source: Internet
Author: User
Adjust the time In Debian-Debian information for the Linux release. The following is a detailed description. Debian has been installed on your own books for a while, but the system time is always eight hours faster than the normal time. At first, we thought it was a problem with the system time zone, the same is true for reconfiguration of the system time zone. I searched the internet and found no correct solution, so it was always inconvenient to use.

Later, when the system was started, it was found that one line was select ()/dev/rtc timeout and so on. In addition, I read some information, saying that hwclock (8) can be used to adjust the time, try to call hwclock (8), but the same error occurs. Google the Internet. Haha ~~ The problem was found. It turned out to be the problem of Loading modules.

In my Debian system, the rtc module is loaded by default, but this module does not prevent the system from reading the hardware clock. We can try other modules:

Remove the rtc module:

$ Rmmod rtc

Load new modules:

$ Modprobe genrtc

Display hardware clock:

$ Hwclock -- show

If we can get the displayed result correctly, it indicates that the loaded module is correct. If the problem persists, load rtc_dev and try again.

Since it is the reason for system module loading, We can configure to load the correct module.

Modify/etc/modprobe. d/blacklist. This file is a list of modules not loaded when the system starts. Add rtc at the end:

Blacklist rtc

Modify/etc/modules. This file is the list of modules to be loaded when the system starts. Add genrtc to it.

Set the system time, which can be done using the date command.

Well, now we have completed our configuration. we can restart and check whether our modification has taken effect.
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.