[CLUE-Tech] Setting System Time

David Anselmi anselmi at americanisp.net
Fri Jul 5 13:33:56 MDT 2002


marcus at tuells.org wrote:
> 
> My first guess would be that date and ls are using different versions of
> libc with differing ideas of where to get the local timezone from.  You
> can force the timezone with the TZ environment variable and try each
> command to see what happens:
> 
> 	TZ=MST7MDT date
> 	TZ=MST7MDT ls [file]
> 
> If the commands don't agree with this invocation, then it needs deeper
> thought.  If they *do* agree, then the command that changed its mind
> isn't picking up the timezone info correctly.

Bingo!  The commands do agree this way, ls is using libc 5 and date is 
using libc 6.  Thanks for the answer!

Now, is there a way to get both versions of libc into the same timezone? 
  I saw something about the zoneinfo files moving from /usr/lib to 
/usr/share, but I don't know how that matters.

This particular machine is using an /etc/localtime file that is a copy 
of the one from /usr/share/zoneinfo (so it isn't a symlink, but it does 
say MST and MDT at the end, so it seems to be correct).  Did the 
zoneinfo format change from libc 5 to 6?

I guess the easy fix would be to set the TZ in the login shell, but if 
someone can explain how to fix libc 5 I'd appreciate it.

Dave




More information about the clue-tech mailing list