Windows 7 loses correct time zone upon reboot

7,059

Solution 1

I decided to continue wasting time on troubleshooting problems in tools that are supposed to save me time... and I rebooted the system several times in order to have a more controlled observation of what's going on:

It turns out that mere booting to Ubuntu changes the BIOS time!

Apparently, Ubuntu uses UTC time, while Windows 7 uses local time (as has been for decades), and after retrieving correct time via NTP, Ubuntu updates the BIOS accordingly.

So, part of the mystery is solved, but I still don't understand why Windows 7 won't automatically 'Synchronize with an Internet time server' immediately upon reboot, just as Ubuntu does.

Solution 2

Because of the way the two operating systems set the hardware clock. by Default ubuntu uses UTC, and windows localtime.

So when you shut down, your hard ware clock is set to say "13:00". When you boot, windows sees "13:00" as localtime, so 1 PM, but Ubuntu sees that as UTC and so converts the time back from UTC to local time.

You can fix this by either asking windows to set the hardware clock with UTC, or Ubuntu to use localtime.

to make the change in Ubuntu, edit edit /etc/default/rcS and change

UTC=yes to no, like this:

# assume that the BIOS clock is set to UTC time (recommended)
UTC=no

See:

https://help.ubuntu.com/community/UbuntuTime#Multiple_Boot_Systems_Time_Conflicts

Share:
7,059

Related videos on Youtube

Android Eve
Author by

Android Eve

Updated on September 17, 2022

Comments

  • Android Eve
    Android Eve almost 2 years

    I have a standard PC running Windows 7 Ultimate (64-bit). For some reason, it refuses to keep the correct time zone (the BIOS battery is OK) when restarted.

    Note (1): The Time zone is correct. The "Internet Time" tab also shows "this computer is set to automatically synchronize with 'time.windows.com'. When I click the 'Change settings...' button, the 'Synchronize with an Internet time server' checkbox is checked.

    Still, upon reboot, the time is skewed by 6 hours... and doesn't correct itself even after waiting hours for this "automatically synchronize" to occur.

    Note (2): The BIOS time is set to local (i.e. not UTC). When I restart Windows 7 without booting to the other OS installed in dual-boot config (Ubuntu Linux), it seems to correctly remember the time. This may explain immediate time upon reboot, but it doesn't explain why Windows 7 won't automatically 'Synchronize with an Internet time server' even after an hour.

    Why is this happening and how do I correct this?

    • Neetu
      Neetu over 13 years
      Is the date and time in the BIOS set correctly?
    • Android Eve
      Android Eve over 13 years
      @James The answer is Yes. Also, the funny thing is I tell Windows 7 to always sync with the Internet and it updates the time correctly when I tell it to do so, but upon reboot it forgets this again! Strange.
  • Android Eve
    Android Eve over 13 years
    Checking the actual time zone settings is one of the first things that I did. It is correct.