This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
Home Products Support Community News


RE: [Xen-users] Clock time off in windows

To: "Dustin.Henning@xxxxxxxxxxx" <Dustin.Henning@xxxxxxxxxxx>
Subject: RE: [Xen-users] Clock time off in windows
From: "Robbie A. Garrett" <RGarrett@xxxxxxxxxxxxxx>
Date: Tue, 6 Oct 2009 11:00:47 -0500
Accept-language: en-US
Acceptlanguage: en-US
Cc: 'XEN Mailing List' <xen-users@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Tue, 06 Oct 2009 08:03:12 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <005a01ca468d$344a0640$9cde12c0$@Henning@prd-inc.com>
List-help: <mailto:xen-users-request@lists.xensource.com?subject=help>
List-id: Xen user discussion <xen-users.lists.xensource.com>
List-post: <mailto:xen-users@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
References: <AF44549693C10343B16422A4B7B365AB1B1797C1@xxxxxxxxxxxxxxxxxxxxxxx>, <005001ca4686$0521bea0$0f653be0$@Henning@prd-inc.com> <AF44549693C10343B16422A4B7B365AB1B1797C2@xxxxxxxxxxxxxxxxxxxxxxx>, <005a01ca468d$344a0640$9cde12c0$@Henning@prd-inc.com>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AQHKRowFB+7MlH1eBkKeI5y4kegpNpD4fgbAgAAWogj///C4AIAAKd16
Thread-topic: [Xen-users] Clock time off in windows
im sorry i should been more clear.

case in point.

windows says is 7:03am

linux says is as follows.
 /sbin/hwclock --utc
Tue 06 Oct 2009 11:03:38 AM EDT  -0.168990 seconds
/sbin/hwclock --localtime
Tue 06 Oct 2009 03:03:47 PM EDT  -0.659618 seconds

nothing makes sense.

From: Dustin Henning [Dustin.Henning@xxxxxxxxxxx]
Sent: Tuesday, October 06, 2009 9:59 AM
To: Robbie A. Garrett
Cc: 'XEN Mailing List'
Subject: RE: [Xen-users] Clock time off in windows

        Didn't mean to go off list with my previous response...  As EST is
GMT-5 and EDT is GMT-4, I don't see why you would be off by more than one
hour unless you were off by 4 or 5 because Windows is set to EDT or EST (if
the hardware clock is running at UTC, but *nix is showing you EDT, see
output below).

[virtadmin@virt1 ~]$ /sbin/hwclock
Tue 06 Oct 2009 09:34:20 AM EDT  -0.562747 seconds
[virtadmin@virt1 ~]$ /sbin/hwclock --utc
Tue 06 Oct 2009 09:34:23 AM EDT  -0.369329 seconds
[virtadmin@virt1 ~]$ /sbin/hwclock --localtime
Tue 06 Oct 2009 01:34:26 PM EDT  -0.014150 seconds

As can be seen here, hwclock shows EDT and the right time, but only because
it either A) defaults to assuming --UTC or B) knows the system is in UTC
based on the appropriate setting.  The BIOS actually shows a time of
05:34:xx (24hr).  When I told hwclock that the system clock was on local
time (GMT-4), it showed me a time that was off by 4 hours (not 3).

Windows should automatically do NTP, so I am not sure that ntp will work
with your current domU config (I am not 100% certain it will work for any
HVM config, for that matter).  However, I know it is possible to tell *nix
to make the system clock use local time and it is possible to make Windows
treat the system clock as UTC; either of these should help if the problem is
that they aren't using the same option.  Unfortunately, I can't tell you off
the top of my head how to make either change, so you will have to search.
Alternatively, try setting up Windows Time to use one of the ntp servers
from pool.ntp.org, I am guessing you are in NA, so see
http://www.pool.ntp.org/zone/north-america.  If this solves your problem,
then maybe it wasn't related to UTC vs ExT after all.  Lastly, assuming NTP
isn't working and you can't find the other options, there is an option in
the domU config for whether to provide the domU system clock time in local
or UTC, but I don't know for sure how it works because it doesn't work on
the version I am running.

-----Original Message-----
From: Robbie A. Garrett [mailto:RGarrett@xxxxxxxxxxxxxx]
Sent: Tuesday, October 06, 2009 10:26
To: Dustin.Henning@xxxxxxxxxxx
Subject: RE: [Xen-users] Clock time off in windows

hwclock on xen domU shows EDT.  Windows is using EST time.

From: Dustin Henning [Dustin.Henning@xxxxxxxxxxx]
Sent: Tuesday, October 06, 2009 9:07 AM
To: Robbie A. Garrett
Subject: RE: [Xen-users] Clock time off in windows

        That depends why it is off.  If it is off by exactly 3 hours to the
second because you live in GMT +/-3 and your system clock is on UTC per *nix
default, then you can either tell *nix to use GMT +/-3 instead of UTC so
that Windows will see the appropriate time, or you can find the registry
setting for Windows to use UTC so Windows will show the appropriate time.
However, if it is off by ~3 hours because it has gotten off over time, then
you will either need to fight with xen to keep the time right or, if
possible, use Windows Time to sync with the appropriate NTP pool (I say if
possible because an HVM may not support the domU setting its own time, but I
have mine set up this way whether that is why they are right or not).  Good

From: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
[mailto:xen-users-bounces@xxxxxxxxxxxxxxxxxxx] On Behalf Of Robbie A.
Sent: Tuesday, October 06, 2009 09:51
To: xen-users@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-users] Clock time off in windows

Hey all,

my clock in my windows 2003 server VM running in xen is off by three hours.

any idea how i can fix this?
Xen-users mailing list

<Prev in Thread] Current Thread [Next in Thread>