Re: [Exim] Timezone Problems

Top Page
Delete this message
Reply to this message
Author: Chris Thompson
Date:  
To: exim-users
Subject: Re: [Exim] Timezone Problems
Sorry to come in late on this thread, but can I just try and
clarify a few things about proper settings of the TZ environment
variable in Solaris?

First, the correct syntax for values is described in mind-numbing
detail in the environ(5) man page, which is RTFM material for this
sort of discussion.

Secondly, use a zoneinfo file if you can. For Solaris 8, Kamalan
needs to do [as root]

zic /usr/share/lib/zoneinfo/src/africa

and thereafter use

TZ=Africa/Johannesburg

Sun rather meanly only ship a small number of the zoneinfo files made
from the Olson sources, but the sources are shipped so you can do it
yourself. In Solaris 9 they are all shipped pre-generated.

Thirdly, for a timezone without seasonal jumps, using the POSIX form
instead is not too poor an alternative. The correct syntax in this
case is

TZ=SAST-2

The first part is the zone name, the second the offset from GMT. The
sense of the latter is not a matter of Sun having "got their naming
conventions backwards", but of following POSIX standards. You might
very well guess that those had something to do with the USA having
to be in the positive direction ... I couldn't possibly comment.

Fourthly, if TZ is the null string, or unset, the libc routines will
read the value from /etc/default/init (/etc/TIMEZONE is a symlink to
that for historical reasons only: it is not used in this context).
But normally processes should inherit a TZ setting, ultimately from
init, which got it from the same place. The use of a "localtime"
alias in /usr/share/lib/zoneinfo is a SunOS4'ism, not used in
Solaris 2 or later.

Apologies for this post having nothing [much] to do with Exim ...

Chris Thompson
Email: cet1@???