Bug 732769 - Explain and enforce why to use UTC in CMOS/BIOS (Was bug #730374: Hardware Clock does not get synchronized)
Summary: Explain and enforce why to use UTC in CMOS/BIOS (Was bug #730374: Hardware Cl...
Status: VERIFIED FIXED
Alias: None
Product: openSUSE 12.2
Classification: openSUSE
Component: Documentation (show other bugs)
Version: Factory
Hardware: All SLES 11
: P3 - Medium : Major (vote)
Target Milestone: Factory
Assignee: Frank Sundermeyer
QA Contact: Karl Eichwalder
URL:
Whiteboard:
Keywords: DSLA_REQUIRED
Depends on:
Blocks:
 
Reported: 2011-11-25 11:46 UTC by Dr. Werner Fink
Modified: 2013-05-03 12:29 UTC (History)
18 users (show)

See Also:
Found By: Development
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dr. Werner Fink 2011-11-25 11:46:12 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.
Comment 3 Jiří Suchomel 2011-11-25 15:53:42 UTC
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.
Comment 4 Dr. Werner Fink 2011-11-25 16:02:38 UTC
(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.
Comment 5 Juergen Weigert 2011-11-25 16:31:30 UTC
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.
Comment 8 Michal Marek 2011-11-25 16:43:56 UTC
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 ;).
Comment 10 Jiří Suchomel 2011-11-28 08:06:30 UTC
(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?
Comment 20 Jiří Suchomel 2012-01-12 08:42:50 UTC
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"
Comment 21 Dr. Werner Fink 2012-01-12 09:11:53 UTC
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.
Comment 22 Jiří Suchomel 2012-01-12 10:20:56 UTC
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.
Comment 23 Dr. Werner Fink 2012-01-12 12:44:45 UTC

| 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.
Comment 24 Jiří Suchomel 2012-01-12 12:52:29 UTC
Karl?
The text in comment 23 should be added to current help text (comment 3) and text in comment 20 would be warning popup.
Comment 25 Martin Weiss 2012-01-12 13:20:05 UTC
(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?
Comment 26 Karl Eichwalder 2012-01-12 13:21:43 UTC
(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...
Comment 27 Karl Eichwalder 2012-01-12 13:26:19 UTC
(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.).
Comment 28 Jiří Suchomel 2012-01-12 14:17:10 UTC
I like Karl's corrections. If no one objects, I'll submit yast2-country with new texts to Factory.
Comment 29 Dr. Werner Fink 2012-01-12 14:19:19 UTC
go
Comment 30 Jiří Suchomel 2012-01-12 14:29:32 UTC
Done in yast2-country-2.22.4. Reassigning for documentation update.
Comment 31 Bernhard Wiedemann 2012-01-12 15:00:09 UTC
This is an autogenerated message for OBS integration:
This bug (732769) was mentioned in
https://build.opensuse.org/request/show/100046 Factory / yast2-country
Comment 32 Karl Eichwalder 2012-02-22 12:37:30 UTC
Frank, I think you are managing the 12.2 opensuse documentation workload.  Please, reassign as appropriate.
Comment 33 Frank Sundermeyer 2012-03-23 11:47:17 UTC
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
Comment 34 Dr. Werner Fink 2012-03-23 11:59:13 UTC
+ 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.
Comment 35 Frank Sundermeyer 2013-03-18 13:25:06 UTC
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.
Comment 36 Frank Sundermeyer 2013-05-03 12:29:05 UTC
Closing.