How to get the both of the systems to show correct time? As of now what I get is every time after using Ubuntu, Windows' time gets changed by +4 hrs. None of the solutions posted here are working.
-
I guess you know that Windows 10 now supports Ubuntu 14 natively without any need for dual-booting, virtual machines etc. – RedGrittyBrick Oct 12 '16 at 11:40
-
@RedGrittyBrick that's not really the same thing, at all. – TheWanderer Oct 12 '16 at 13:21
-
I have tried updating the windows registry as suggested it worked at first time but after installing the windows updates; this solution stopped working. I have tried all solutions listed below but nothing seems to be working. – Kiran Kadam Oct 14 '16 at 22:21
2 Answers
Your computer contains a small clock, that has an own small battery, so it won't lose track of time, even when your pc is shutdown. Linux/Ubuntu expects this clock to give the time in the UTC timezone, which, depending on where you live, differs from your local time (also, UTC does not have daylight saving time). Windows on the other hand, expects this clock to give the local time. The solution would be to either set Windows to expect utc, or set linux so it expects localtime. Since the Windows solution involves messing with the registry, lets look at how to do it in Ubuntu: Open the file /etc/default/rcS with root privileges and an editor of your choice, e.g.:
sudo nano /etc/default/rcS
Change the following line to look like this:
# Set UTC=yes if your system clock is set to UTC (GMT), and UTC=no if not.
UTC=no
Now you may have to set the clock to the correct time again.
NOTE: This method should only be used with Versions up to 15.04, since the introduction of systemd changed ways.

- 464
-
There is no such line rcS file. can you please post the exact line i need to add if UTC doesn't exist in rcS ? – Kiran Kadam Oct 14 '16 at 22:22
-
Just write UTC=no, as stated in my post. Are you sure there is no such line? – Gasp0de Oct 19 '16 at 07:17
-
-
Modifying registry worked for me, I just had to create a file named WindowsTimeFixUTC.reg with the following contents [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TimeZoneInformation] "RealTimeIsUniversal"=dword:00000001 – Kiran Kadam Jan 01 '18 at 01:06
Multiple Boot Systems Time Conflicts
Operating systems store and retrieve the time in the hardware clock located on your motherboard so that it can keep track of the time even when the system does not have power. Most operating systems (Linux/Unix/Mac) store the time on the hardware clock as UTC by default, though some systems (notably Microsoft Windows) store the time on the hardware clock as the 'local' time. This causes problems in a dual boot system if both systems view the hardware clock differently.
The advantage of having the hardware clock as UTC is that you don't need to change the hardware clock when moving between timezones or when Daylight Savings Time (DST) begins or ends as UTC does not have DST or timezone offsets.
Changing Linux to use local time is easier and more reliable than changing Windows to use UTC, so dual-boot Linux/Windows systems tend to use local time.
Since Intrepid (8.10), UTC=yes is default.
Make Windows use UTC
Note: This method was not initially supported on Windows Vista and Server 2008, but came back with Vista SP2, Windows 7, Server 2008 R2 and Windows 8/8.1.
To make MS Windows calculate the time from the hardware clock as UTC.
Create a file named WindowsTimeFixUTC.reg
with the following contents and then double click on it to merge the contents with the registry:
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TimeZoneInformation]
"RealTimeIsUniversal"=dword:00000001
Note: Windows Time service will still write local time to the RTC regardless of the registry setting above on shutdown, so it is handy to disable Windows Time service with this command (if time sync is still required while in Windows use any third-party time sync solution):
sc config w32time start= disabled
Reversing the change You can create a file with the following contents and then double-click it to merge in the original changes, as above:
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TimeZoneInformation]
"RealTimeIsUniversal"=-
If Windows Time service was disabled, enable it again with the command:
sc config w32time start= demand
Make Linux use 'Local' time
To tell your Ubuntu system that the hardware clock is set to 'local' time:
edit /etc/default/rcS
add or change the following section
# Set UTC=yes if your hardware clock is set to UTC (GMT)
UTC=no
For more details you can check the following link:
Multiple Boot Systems Time Conflicts
Hope, It will be work :)

- 316
- 3
- 7
-
Please quote the most relevant part of an link important for your answer, in case the target site is unreachable or goes permanently offline. https://askubuntu.com/help/how-to-answer – Melebius Oct 12 '16 at 07:01
-
Thanks for the answer, modifying registry worked for me, I just had to create a file named WindowsTimeFixUTC.reg with the following contents [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TimeZoneInformation] "RealTimeIsUniversal"=dword:00000001 – Kiran Kadam Jan 01 '18 at 01:06