From: kraus@rtsg.mot.com (David Kraus) Subject: Re: Date command only uses GMT Date: Mon, 5 Apr 1993 17:03:27 GMT
In article <1993Apr1.085046.13850@ee.ubc.ca>, jmorriso@rflab.ee.ubc.ca (John Paul Morrison) writes:
> In article <1pdm69INNsnp@crcnis1.unl.edu> jbettis@cse.unl.edu (Jeremy Bettis) writes:
>>I have been unable to get the date command to display the correct timezone.
> arrrg!! dont use TZ.
> you should go into /usr/lib/zoneinfo and make a link from your timezone
> to localtime (and posixwhatever....). there's a readme in the directory,
> but you probably want to do: ln -sf US/Central localtime
> Mountain(?)
Make sure you check the permissions on this - when I initially installed
SLS, the permissions were -rw------- root, so things would work as root but
not as a normal user... Spent about 20 minutes figuring that out, and felt
very foolish when I found it. (Of course, I was blaming tcsh's time
handling as opposed to bash's, so that's part of what took so long...;^)
> then make sure clock -s sets the clock properly at boot time.
> use clock -s if your clock is set to localtime, or clock -s -u if your
> clock is on GMT. if you use GMT, daylight savings time will get handled
> better.
Right. Now, what if I want to set the hardware clock to local time (CDT)?
I run DOS for a couple of applications that are time/date critical (Fido
point, primarily), so running GMT isn't really an option. According to the
zoneinfo.doc, even if you're running local time, daylight savings should be
handled when you change your clock. I wondered about that when I read it,
and, sure enough, when I changed my clock and did a `date`, it showed up as
the correct time, but still CST.
I'm having to set TZ=CDT5 in order for `date` to give a correct time zone.
My question is, have I done something terribly wrong, or is it 'working per
design'?