Time configuration in Windows/Linux dual-boot.

Many Linux users still have Windows installed on their machines for some reason (playing games, using specialized Windows-only applications and so on). The coexistence of Windows and Linux on the same physical machine is called dual-boot.

One of the main issues when dual-booting is time configuration. It is because Windows is often known not to support RTC being in local-time. For this reason the common configuration is like this:

  • RTC clock is set to local-time in BIOS Setup
  • Windows is left untouched and still treats RTC as being in local-time
  • Linux is reconfigured to treat RTC as being in local-time

However, for some time now, Windows can be configured to treat RTC clock as being in UTC time. It can be done by setting the following registry key

HKLM\SYSTEM\CurrentControlSet\Control\TimeZoneInformation\RealTimeIsUniversal

to a DWORD value 1 and restarting the Windows. After restart the time shown in Windows may be invalid and shifted by a few hours from the real time, so it needs to be corrected either in BIOS Setup or under Linux using date or ntpdate commands.

This is known to work generally fine in Windows Vista SP2 and Windows 7 but there are still some known issues:

  1. Windows is unable to modify RTC clock when RealTimeIsUniversal=1 which means that any time change done in Windows will not persist after the reboot. It is not a big problem because the persistent time change can be done directly in BIOS Setup or in Linux.
  2. The time may be shown wrongly after resuming a suspended or hibernated Windows.
  3. The old DOS application may show the time wrongly.

References:
1. IBM PC Real Time Clock should run in UT

Advertisement

About Robert Piasecki

Husband and father, Java software developer, Linux and open-source fan.
This entry was posted in Linux and tagged , , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.