Search This Blog

Wednesday, November 29, 2017

dual boot and clock changes between linux and windows

Found myself, once more, entangled in this different view of time between Linux and Windows. Linux uses UTC (Coordinated Universal Time, formerly Greenwich Mean Time), Windows uses Local Time, both have a long history with this stance, and arguably good reasons. However you view this, it seems that arguments are futile. Instead, Let's talk about what can you do to stop your clock changing because of a reboot.

ghacks.net has a complete solution - either to configure your Linux to use Local Time or to configure Windows to use Universal Time.  It would appear that the Linux solution is slightly less complicated whereas in the Windows solution you get the additional chore of having to watch time synchronisation for the O/S yourself (as you have to turn the w32time service off, lets it would reverse your changes....)

And yet, I decided to go for this solution. Not because it is smarter. But because seeing that in the near future I'd be using more of Windows as host with plenty of Linux guests, and this solution has the minimal work required:
1) Open Regedit as administrator
2) go to the registry key  HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TimeZoneInformation :








3) Create a registry value with the name RealTimeIsUniversal, as dword, with the value of 1.
(right mouse button, new, and dword value, as shown in attached screen snap)

4) open cmd as administrator and run the following command:
sc config w32time start= disabled
That is all there is to it. Now, if you clock isn't set, set it. 

related:
if you prefer to change Linux's configuration, on any modern systemD Linux, execute:
sudo timedatectl set-local-rtc 1