Insight: Multiple Way To Fix Linux and Windows Showing Different Times When Dual Booting
If you using dual booting in your system with Windows and Linux, you might have issues with getting the correct time. It is a common problem with dual booting. It happens because of the different timekeeping mechanisms of Linux and Windows.
Today in this post, we will look at the various methods to fix Linux and Windows showing different times when dual booting.
Multiple Way To Fix Linux and Windows Showing Different Times [Dual Booting]
Windows assumes the local time is stored in the motherboard while Linux assumes the Greenwich Mean Time or UTC time is stored in the motherboard and apply a timezone offset to display the local time while you boot into the Linux.
Solution 1:
We can set the Linux to use local time by running the following command. It works on Ubuntu, Fedora, Red Hat, Debian, and Mint or any Linux using systemd. This solution is most preferrable than the second solution to fix Linux and Windows showing different times while dual booting.
Open Terminal and run the following command:
timedatectl set-local-rtc 1 --adjust-system-clock
Run the following command If you ever need to reverse the command, change the 1 to a 0:
timedatectl set-local-rtc 0 --adjust-system-clock
Solution 2:
While in the first solution, we tweaked the Linux system to fix the timing issues in Linux and in this second method, we will customize the Windows timekeeping mechanism to fix the issues.
Disable “Set time automatically” under “Time & Language” in the Settings application.
Open your run command and execute Registry Editor by typing regedit
After running Registry Editor, paste the following key into the register editor’s bar to have access to that key or you can find the following registry key in the left pane of the registry editor.
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\TimeZoneInformation
Now, Right-click on the “TimeZoneInformation” key in the left pane and select “New -> DWORD (32-bit) Value” from the context menu and name your new value “RealTimeIsUniversal.”
Double-click on the value (RealTimeIsUniversal) you just created, and set its value to “1,” and click “OK.”