Re: [Exim] Timezone Problems

Top Page
Delete this message
Reply to this message
Author: Philip Hazel
Date:  
To: Kamalan Govender
CC: exim-users
Subject: Re: [Exim] Timezone Problems
On Mon, 14 Oct 2002, Kamalan Govender wrote:

> Sorry, losing you here. When you telnet locahost 25 on a system, is the
> last field the GMT off set?


Yes.

> When I telnet localhost 25 I get:
> 220 marcus.wits.ac.za ESMTP Exim 4.10 Mon, 14 Oct 2002 12:43:46 -0200
>
> Which I read as GMT-2. The second last field, 12:44:46 is the right
> wall-clock time.


On my host I get

220 libra.cus.cam.ac.uk ESMTP Exim 4.10 Mon, 14 Oct 2002 13:52:02 +0100

Which is correct. You should presumably get +0200 if all is well. Since
you are not, something is wrong.

Exim computes the offset by comparing the time it gets from the gmtime()
ane localtime() functions. So your result suggests that these are giving
incorrect answers. Since the local time seems to be right, it suggests
that the gmtime() function is giving the wrong answer. Presumably it
would do this if the operating system thought your machine was in a
different timezone to the one that it is actually in.

So, if you are able to, I suggest you write a little C program that
calls the localtime() and gmtime() functions and prints out what they
are telling you. This will confirm my diagnosis. Then you'll need to
tweak your OS to get it right - I'm afraid I have no idea how the
default timezone is set in Solaris

> I think if I can get Exim to show the last field to be +0200 and the
> right wall clock time, when it shoud be ok.


Yes. +0200 is right for ZA.

Philip

--
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.