Timezones and multi boot.

One of the things that has always been bothering me is the fact that on x86 systems you cannot really run multiple operating systems and survice the timezone change. That's because the clock runs in local time; and localtime is ambiguous. The system cannot tell whether the DST change has been or not so it needs to record this fact in the filesystem (that's why Solaris on x86 has the "rtc -c" cronjob). If you boot all your OSes in turn after the changeover, your system will be N hours off once they're all done adjusting time. The problem is probably best summarized here

On Unix this was long solved by running the clock in the UTC or GMT timezone; that clock is unambiguous, give or take a leap second, and allows multiple versions of the OS to coexist.

Last week, it was pointed out to me in comp.unix.solaris that there is a hidden registry key in later releases of MS-Windows. I already knew how to fix up Solaris, so I combined this to:



       Set the following registry key (it does not exist!)

HKLM/SYSTEM/CurrentControlSet/Control/TimeZoneInformation/RealTimeIsUniversal
(REG_DWORD = 1)

       In the control panel with Day&Time settings, check the "automatically adjust" check box.


        Boot into Solaris and run:


              rtc -c -z UTC

        then correct the clock with date/rdate
        (if you use liveupgrade, lumount your other partition(s) and copy the
        /etc/rtc_config file to all of them)

        In Linux, you'll need to run "timeconfig" and select "RTC set to GMT".


Note that if you don't multiboot, it's probably also a good idea to run "rtc -c -z UTC" and then correct the date; for one you won't be bitten by the AMD64 timezone bug we had in Solaris 10.
Comments:

RealTimeIsUniversal is a leftover from the Alpha and MIPS days of NT 3.x. It is still present today and works in the Executive (i.e. at boot time), up until the semi-retarded clock applet is launched and perform its IntelliNonSense (TM). Markus has been struggling with this more than I have: http://www.cl.cam.ac.uk/~mgk25/mswish/ut-rtc.html

Posted by Roland Kaufmann on April 12, 2005 at 02:30 PM MEST #

I seem to have better luck now that I've enabled NTP on the only system which runs XP most of the time.

Posted by Casper Dik on April 18, 2005 at 09:54 AM MEST #

BTW, to enable NTP on your system you'd need to edit: HKLM/SYSTEM/CurrentControlSet/Services/W32Time/TimeProvider/NTPClient Set Enabled, and set the interval to something lowish (I use five minutes but I have an ntp server on the local lan)

Posted by Casper Dik on April 20, 2005 at 05:25 AM MEST #

To set UTC under JDS1/JDS2, start yast2, then use the search button at the bottom of the page looking for "time". Click on "Select Time Zone" in the search results and at the bottom there is a option for the hardware clock being either local time or UTC.

Posted by Paul Shore on April 26, 2005 at 09:28 AM MEST #

Post a Comment:
Comments are closed for this entry.
About

casper

Search

Top Tags
Archives
« April 2014
MonTueWedThuFriSatSun
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
    
       
Today