[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: how to change date of system



On Thu, Nov 13, 2008 at 05:30:58PM +0000, Aneurin Price wrote:
> On Wed, Nov 12, 2008 at 6:44 PM, John Hasler <jhasler@debian.org> wrote:
> > Nye writes:
> >> How do you prevent both Linux and Windows from attempting to correct the
> >> time for DST, and ending up an hour out?
> >
> > Linux doesn't do that.
> 
> That's a bold statement. Could you clarify, as it sounds like you are saying
> that local time displayed in Linux is an hour out for half the year parts of
> the world that observe DST (at least for those who set their HW clock to
> local time), and I'm sure that's *not* what you mean. Possobly you just mean

Linux doesn't mess with the hardware clock at all, by default.  Instead,
it simply observes the local time rules, including daylight savings,
when displaying times or taking input.  Timestamps on the filesystem
are in UTC.

In contrast, Windows (by default) sets the hardware clock to local
time, so has to make daylight savings adjustments to the hardware clock.
Linux can accomodate this in a dual boot situation by being configured to
know that the hardware clock is set to local time (again, by Windows),
figuring out what the UTC time is, and then working as usual.

> that people sing local time should expect to change their clock manually for
> DST? That's not my experience anyway, unless I've explicitly told it not to
> make the adjustment, but it may have been done by some part of KDE or
> whatever I was using at the time.
> 
> >> Do you just tell one of them not to change the clock, and live with it
> >> being wrong until you boot into the other one?
> >
> > No.  Since Windows is incapable of dealing with UTC you put the BIOS clock
> > on local time and tell Linux that you have done so.  Linux then assumes
> > that the BIOS clock gives correct local time and that someone else is
> > taking care of DST.  This works as long as you boot Windows frequently
> > enough.
> 
> Although you say 'no', the elaboration sounds a lot like 'yes'. I can see no
> way that Linux could possibly know whether Windows has yet changed the clock
> or not (to know whether it needs to apply an offset to get the correct local

Linux just assumes that the hardware clock is set to local time, and
that the local time is corrrectly set (hence, the "as long as you boot
Windows frequently enough" part).

> time), and hence must assume that it has. This means that the time will be
> wrong until you boot into Windows, which is what I said. If I have
> misunderstood you, then I would appreciate being corrected.
> 
> -Nye

Ask away if it's still not clear.
 
> PS. Technically Windows is capable of understanding that the HW clock is set
> to UTC as god intended (Google RealTimeIsUniversal), and this appears to work
> just fine ... until some things start to act a bit *wierd*.

Yes, there has long been a setting in Windows to use UTC on the hardware
clock, but there are (or at least used to be) numerous application and/or 
system bugs that obviated its use.

Ken

-- 
Ken Irving, fnkci@uaf.edu


Reply to: