Universal vs local time

Roger Oberholtzer roger
Mon May 17 11:51:19 PDT 2004


On Fri, 22 Aug 2003 05:31:52 -0500
"David A. Bandel" <david at pananix.com> wrote:

> On 21 Aug 2003 22:18:38 -0400
> burns <linux at burnsmacdonald.com> wrote:
> 
> > On Thu, 2003-08-21 at 20:55, Joel Hammer wrote:
> > > How can I tell if my linux box is running with the clock set to
> > > universal or local time?
> > 
> > 
> > 'uname -a' gives you the system time. It's pretty obvious from that
> > what time standard it is using (local or otherwise).
> 
> Huh??
> 
> The only think uname -a shows is the time the kernel was built based on
> the system time of the system it was built on (which may not even be the
> system it was running on).  If you can ascertain anything about the
> hardware clock on the system from that, Sherlock, I'd like to know how.

Look at /etc/sysconfig/clock

On SuSE mine is:

	# Set to "-u" if your system clock is set to UTC, and to
	# "--localtime" if your clock runs that way.
	HWCLOCK="-u"

On Caldera it is:

	CLOCKMODE=GMT

On SuSE, the option is really an option to the 'hwclock' command. I don't
see how you can get the current setting, unless you compare the time from
'hwclock --show' with that of 'date'. If they are off by longer than the
time it takes to run the two commands, then the hardware clock is probably
GMT.

That is all I have.


-- 
+????????????????????????????+???????????????????????????????+
? Roger Oberholtzer          ?   E-mail: roger at opq.se        ?
? OPQ Systems AB             ?      WWW: http://www.opq.se/  ?
? Erik Dahlbergsgatan 41-43  ?    Phone: Int + 46 8   314223 ?
? 115 34 Stockholm           ?   Mobile: Int + 46 733 621657 ?
? Sweden                     ?      Fax: Int + 46 8   302602 ?
+????????????????????????????+???????????????????????????????+



More information about the Linux-users mailing list