Tuesday, September 22, 2009

Windows XP/Win7 time issues under virtualization

Here is a hidden jewel that I just discovered if you are running mixed virtualized guests (Linux & Windows)

The norm is to set the host server to UTC and let the guest OS handle the timezone offsets. The problem is that Windows XP normally takes the RTC (real time clock) time as the system time and does not compensate for the offset from UTC. So what to do?

Do I need to say this? Backup your registry FIRST!!

Go to this registry key:
HKLM\SYSTEM\CurrentControlSet\Control\TimeZoneInformation\

and add a new string value, type REG_SZ.

Name the string value "RealTimeIsUniversal" and set value to "1" for Universal Time.

Reboot and your virtualized guest OS should now show the correct local time.

This worked for me on a virtualized Windows XP and Win 7, YMMV on other windows versions!

I would also suggest setting up the internet time sync to use:

north-america.pool.ntp.org

for those of you in North America.