Bugzilla – Bug 732769
Explain and enforce why to use UTC in CMOS/BIOS (Was bug #730374: Hardware Clock does not get synchronized)
Last modified: 2013-05-03 12:29:05 UTC
As explaind several times in bug #730374 the usage of UTC for the CMOS/BIOS/mainframe clock on *single boot* systems has several considerable advantages: * No need of clock correction due Daylight Saving Time twice a year * No need to tell the kernel about the timezone offset in initrd to get the kernels system clock to run in UTC * Well mounted file systems due correct time marks even across DST * Well working timezone configuration due glibc API even for an international multi user system (by using correct /etc/localtime for local time in user space and and TZ environment variable for user from other timezones as well). IMHO we should mention this in the documentation and/or release notes for SLES as well as for openSUSE. Also we should mention this within YaST to avoid localtime in CMOS on single boot systems. For dual boot systems we may also refere on the support pages I've found at http://msdn.microsoft.com/ for embedded Windows7[tm] to argument for UTC in CMOS clock.
YaST help text currently says: "Specify whether your machine is set to local time or UTC in <b>Hardware Clock Set To</b>. Most PCs that also have other operating systems installed (such as Microsoft Windows) use local time. Machines that have only Linux installed are usually set to Universal Time Coordinated (UTC). If the hardware clock is set to UTC, your system can switch from standard time to daylight saving time and back automatically." This could be altered, but it cannot be too technical. But primary, let's not forget that the help text is hidden by default so people who do not seek the help won't see it. Check documentation team about what is written in user/admin guide book.
(In reply to comment #3) OK ... the question is if you know aka the yast module knows at this time if there exist a foreign partition. If we are on a single boot system we should more insist on choosing UTC for CMOS.
The docs have this topic in several places. E.g. http://doc.opensuse.org/products/opensuse/openSUSE/opensuse-reference/cha.y2.lang.html says: Depending on which operating systems run on your workstation, adjust the hardware clock settings accordingly: If you run another operating system on your machine, such as Microsoft Windows*, it is likely your system does not use UTC, but local time. In this case, uncheck Hardware Clock Set To UTC. If you only run Linux on your machine, set the hardware clock to UTC and have the switch form standard time to daylight saving time performed automatically.
Also I think that if there is no Windows partition and the user chooses local time, we should display a warning. Even better would be to hide the checkbox behind some "Expert options" button ;).
(In reply to comment #8) > Also I think that if there is no Windows partition and the user chooses local > time, we should display a warning. I agree with this solution. But I think it is too late for SLE11SP2, since 1) it alters installation 2) would bring new texts Thorsten?
1. Werner, do you propose any change to the help text which is written in comment 3? 2. If user has linux only system and chooses localtime, we could show something like "You have selected local time although it appears that Windows system is not installed. In such case it is strongly recommended to use UTC. Are you sure to continue with your selection? [Continue/Cancel"
Sounds well ... maybe some further remarks may added like: Please note that the internal system clock as used by the Linux kernel has to be always in UTC as this is the reference for the correct localtime of the user space. For CMOS clock other than in UTC this requires a correction by the timezone offset for the system clock of the Linux kernel and also the CMOS clock has to be corrected twice a year for the correct Day Light Saving switch before the Linux kernel has been booted.
This is too technical, can you make it more for regular user? Or maybe refer to the detailed description in documentation? Likw Please note that the internal system clock as used by the Linux kernel has to be always in UTC as this is the reference for the correct localtime of the user space. For more details, check user manual.
| Please note that the internal system clock as used by the Linux kernel | has to be always in UTC as this is the reference for the correct localtime | of the user space. If you are choosing localtime for CMOS clock you may | check the user manual for the side effects. Nevertheless the user has to be informed that the Day Light Saving switch for the CMOS clock has to be done by him self. Even if technical this is required by the system. Maybe Karl has a few words to make clear that locatime in CMOS clock is a fragile and requires periodic maintenance within the CMOS.
Karl? The text in comment 23 should be added to current help text (comment 3) and text in comment 20 would be warning popup.
(In reply to comment #23) > > | Please note that the internal system clock as used by the Linux kernel > | has to be always in UTC as this is the reference for the correct localtime > | of the user space. If you are choosing localtime for CMOS clock you may > | check the user manual for the side effects. > > Nevertheless the user has to be informed that the Day Light Saving switch > for the CMOS clock has to be done by him self. Even if technical this is > required by the system. > > Maybe Karl has a few words to make clear that locatime in CMOS clock is > a fragile and requires periodic maintenance within the CMOS. Could you add the information do the docs that UTC is required because of the the limitation in the kernel where hwclock will not be synced if the difference between kernel and hardware is more then 15 minutes, please?
(In reply to comment #20) > 1. Werner, do you propose any change to the help text which is written in > comment 3? > > 2. If user has linux only system and chooses localtime, we could show something > like > > "You have selected local time although it appears that Windows system is not > installed. In such case it is strongly recommended to use UTC. > > Are you sure to continue with your selection? > [Continue/Cancel" I think this is mostly ok. I would not mention Windows, though, and I'd describe the problem less technical. Maybe, we should even rephrase the final question (Do you want to select UTC instead?): "You selected local time, but only Linux seems to be installed on your system. In such case, it is strongly recommended to use UTC, and to click Cancel. If you want to keep local time, you must adjust the CMOS clock twice the year because of Day Light Saving switches. If you miss to adjust the clock, backups may fails, your mail system may drop mail messages, etc. If you use UTC, the Linux will adjust the time automatically. Do you want to continue with your selection (local time)? [Continue/Cancel]" Something about comment 23 will follow...
(In reply to comment #23) > > | Please note that the internal system clock as used by the Linux kernel > | has to be always in UTC as this is the reference for the correct localtime > | of the user space. If you are choosing localtime for CMOS clock you may > | check the user manual for the side effects. Adding such a warning is useful. Small changes: | Note: The internal system clock as used by the Linux kernel must | always be in UTC, because this is the reference for the correct localtime | in user space. If you are choosing localtime for CMOS clock, | check the user manual for background information about side effects. > Nevertheless the user has to be informed that the Day Light Saving switch > for the CMOS clock has to be done by him self. Even if technical this is > required by the system. > > Maybe Karl has a few words to make clear that locatime in CMOS clock is > a fragile and requires periodic maintenance within the CMOS. This we probably must add to the manuals. Please, reassign the bug to the docs team, once the text changes are implemented (or clone this bug, etc. pp.).
I like Karl's corrections. If no one objects, I'll submit yast2-country with new texts to Factory.
go
Done in yast2-country-2.22.4. Reassigning for documentation update.
This is an autogenerated message for OBS integration: This bug (732769) was mentioned in https://build.opensuse.org/request/show/100046 Factory / yast2-country
Frank, I think you are managing the 12.2 opensuse documentation workload. Please, reassign as appropriate.
What exactly are the "side effects" when using localtime? So far I have * having If you are choosing localtime for CMOS clock you may * filesystem inconsistencies caused by wrong time stamps
+ The CMOS clock has to be corrected twice a year die Day Light Saving switches there is no way to determine this automatically as it is not possible to detect if an other OS or the user already has done this.
Added the following snippet to the SLE 11 SP3 documentation: IMPORTANT: Set the Hardware Clock to UTC The switch from standard time to daylight saving time (and vice versa) can only be performed automatically when the hardware clock (CMOS clock) is set to UTC. This also applies if you use automatic time synchronization with NTP, because automatic syncing will only be performed if the time difference between the hardware and system clock is less than 15 minutes. Since a wrong system time can cause severe problems (missed backups, dropped mail messages, mount failures on remote file systems, etc.) it is strongly recommended to _always_ set the hardware clock to UTC. Please close this bug if you think this is sufficient.
Closing.