Solve the Time Inconsistency between windows and Ubuntu-reprint

Source: Internet
Author: User

When you switch the operating system, you will find a problem. Windows and Ubuntu may have different time periods. After setting the time correctly in windows, the system time after returning to Ubuntu is different. After setting the time correctly in Ubuntu and entering windows, the time is inconsistent.

The reason for this is that windows and Ubuntu have different methods of viewing hardware time (BOIs display time on the motherboard) by default. If you know the cause of the problem, let's solve it.

This is a question about time. Let's take a look at the concept of time.
Universal Time Coordinated
GMT is Greenwich Mean Time, Greenwich Mean Time

By default, Windows and Linux have different ways of viewing the system hardware time:
* In Windows, the system hardware time is treated as the local time, that is, the time displayed in the operating system is the same as the time displayed in the BIOS.

* Linux/Unix/MAC uses the hardware time as UTC. The time displayed in the operating system is converted by the hardware time. For example, Beijing time is GMT + 8, the time displayed in the system is hardware time + 8.

In this way, a problem occurs when multiple systems coexist in the PC. Assume that the time zone set in Ubuntu and Windows is UTC + 8 Beijing time, and you change the current system time to Am In ubuntu. The actual C time in the hardware is AM. After you restart and enter windows, you will find that the time displayed in Windows is am, eight hours slower than in Ubuntu. Similarly, after you change the system time in Windows or use the network to synchronize the system time, and then go to Ubuntu to see it, the system will be 8 hours faster. The situation may be more complex in the region where renewal is implemented.

The following two methods can be used to make the system time consistent.

Let windows treat hardware time as UTC

Start-> Run-> cmd to open the command lineProgram(For Vista, you must open the command line program as an administrator to have the permission to access the Registry.) enter the following command in the command line and press Enter.

Reg add HKLM \ System \ CurrentControlSet \ Control \ timezoneinformation/V realtimeisuniversal/T REG_DWORD/D 1

========================================================== ======================================

Enable local time instead of UTC time in Ubuntu

Edit

/Etc/default/RCS

Change "UTC = yes" to "UTC = No". Save and restart the system.

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.