LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (http://www.linuxquestions.org/questions/linux-networking-3/)
-   -   System time vs Hardware time and Daylight Savings Time (http://www.linuxquestions.org/questions/linux-networking-3/system-time-vs-hardware-time-and-daylight-savings-time-537245/)

Toadman 03-13-2007 07:52 PM

System time vs Hardware time and Daylight Savings Time
 
I really had no clue as to where to post this so I thought I'd try here. I'm running Mandrake 10.1 on a home desktop. I downloaded and installed this rpm timezone-2.4-7mdv2007.0.i586.rpm. On March 11th it all appeared to go as planned, my hourly log snip showed that at 2am the time changed to 3am and I looked no further in the log. Tonight as I was looking at the hourly log snip for errors I noticed this in my 7pm log snip which runs from 6:00pm to 6:59pm:

Mar 13 17:00:00 localhost postfix/pickup[28507]: 5B308434066: uid=0 from=<root>
Mar 13 17:00:00 localhost postfix/cleanup[31661]: 5B308434066: message-id=<20070313230000.5B308434066@cpollock.localdomain>
Mar 13 17:00:00 localhost postfix/qmgr[6892]: 5B308434066: from=<cpollock@earthlink.net>, size=17280, nrcpt=1 (queue active)
Mar 13 18:00:01 localhost postfix/smtp[31663]: 5B308434066: to=<cpollock@earthlink.net>, relay=smtpauth.earthlink.net[207.69.189.209], delay=1,

Mar 13 18:16:13 localhost fetchmail[21303]: 1 message for cpollock at pop.earthlink.net (2267 octets).
Mar 13 17:16:13 localhost spamd[31024]: spamd: connection from localhost.localdomain [127.0.0.1] at port 34887
Mar 13 17:16:13 localhost spamd[31024]: spamd: setuid to chris succeeded

Mar 13 18:18:23 localhost postfix/smtp[503]: 24F5D434066: to=<spam@uce.gov>, relay=smtpauth.earthlink.net[207.69.189.208], delay=0, status=sent (250 OK id=1HRGG7-00016o-Pi)
Mar 13 17:18:23 localhost postfix/qmgr[6892]: 24F5D434066: removed

It seems like by looking at the above that part of postfix is on central standard time and part on central daylight time, also spamassassin seems to be running an hour behind. I went and had a look at webmin -> Hardware -> System Time and I see two different times shown. At the moment it shows that system time is 18:40 and hardware time is 19:40. Time Zone is set to America/Chicago which is correct and I'm using this as my ntp server ntp-0.cso.uiuc.edu (United states IL). Date from the CLI is correct, Tue Mar 13 19:42:02 CDT 2007. In webmin even clicking "Set System Time to Hardware Time" doesn't correct this. My cronjobs are also all off by an hour, for instance, one that used to run at 8am now runs at 9am. Any help would be appreciated, I don't think its a problem, its just annoying and it may correct itself when the old DST rolls around next month.

Thanks
Chris

MensaWater 03-15-2007 08:14 AM

Duplicate thread as you noted in your other post.

doublejoon 03-15-2007 01:34 PM

Quote:

Originally Posted by Toadman
I really had no clue as to where to post this so I thought I'd try here. I'm running Mandrake 10.1 on a home desktop. I downloaded and installed this rpm timezone-2.4-7mdv2007.0.i586.rpm. On March 11th it all appeared to go as planned, my hourly log snip showed that at 2am the time changed to 3am and I looked no further in the log. Tonight as I was looking at the hourly log snip for errors I noticed this in my 7pm log snip which runs from 6:00pm to 6:59pm:

Mar 13 17:00:00 localhost postfix/pickup[28507]: 5B308434066: uid=0 from=<root>
Mar 13 17:00:00 localhost postfix/cleanup[31661]: 5B308434066: message-id=<20070313230000.5B308434066@cpollock.localdomain>
Mar 13 17:00:00 localhost postfix/qmgr[6892]: 5B308434066: from=<cpollock@earthlink.net>, size=17280, nrcpt=1 (queue active)
Mar 13 18:00:01 localhost postfix/smtp[31663]: 5B308434066: to=<cpollock@earthlink.net>, relay=smtpauth.earthlink.net[207.69.189.209], delay=1,

Mar 13 18:16:13 localhost fetchmail[21303]: 1 message for cpollock at pop.earthlink.net (2267 octets).
Mar 13 17:16:13 localhost spamd[31024]: spamd: connection from localhost.localdomain [127.0.0.1] at port 34887
Mar 13 17:16:13 localhost spamd[31024]: spamd: setuid to chris succeeded

Mar 13 18:18:23 localhost postfix/smtp[503]: 24F5D434066: to=<spam@uce.gov>, relay=smtpauth.earthlink.net[207.69.189.208], delay=0, status=sent (250 OK id=1HRGG7-00016o-Pi)
Mar 13 17:18:23 localhost postfix/qmgr[6892]: 24F5D434066: removed

It seems like by looking at the above that part of postfix is on central standard time and part on central daylight time, also spamassassin seems to be running an hour behind. I went and had a look at webmin -> Hardware -> System Time and I see two different times shown. At the moment it shows that system time is 18:40 and hardware time is 19:40. Time Zone is set to America/Chicago which is correct and I'm using this as my ntp server ntp-0.cso.uiuc.edu (United states IL). Date from the CLI is correct, Tue Mar 13 19:42:02 CDT 2007. In webmin even clicking "Set System Time to Hardware Time" doesn't correct this. My cronjobs are also all off by an hour, for instance, one that used to run at 8am now runs at 9am. Any help would be appreciated, I don't think its a problem, its just annoying and it may correct itself when the old DST rolls around next month.

Thanks
Chris


cp /usr/share/zoneinfo/America/Chicago /etc/localtime
Restart crond, postfix,spamassasin
Also in /etc/sysconfig/clockfile make sure
ZONE="America/Chicago"

archtoad6 03-15-2007 06:15 PM

Please don't quote entire posts for no good reason. It clutters the thread & obscures your thoughts.

Toadman 03-15-2007 07:05 PM

In stopping and restarting postfix I noticed something that I wasn't aware of:

postfix/postfix-script: warning: /var/spool/postfix/etc/localtime and /etc/localtime differ

didn't realize there was a localtime file in var/spool/postfix/etc. I've copied over the /etc/localtime file and postfix quit complaining. I've stopped and restarted postfix, crond and spamassassin. I'll see what happens here in a few minutes when the next hourly log cut is sent and let you know a bit later.

Thanks
Chris

Toadman 03-15-2007 07:27 PM

Addition to my last post, syslog shows that at least postfix was fixed:

Mar 15 19:01:00 localhost postfix/pickup[13328]: EFD68434076: uid=501 from=<cpollock@earthlink.net>
Mar 15 19:01:00 localhost postfix/cleanup[14008]: EFD68434076: message-id=<20070316000100.EFD68434076@cpollock.localdomain>

However, seems like spamassassin still has issues:

Mar 15 19:08:38 localhost clamd[21255]: Accepted connection on port 1752, fd 11
Mar 15 18:08:41 localhost spamd[12961]: spamd: identified spam (25.7/5.0) for chris:501 in 6.5 seconds, 2284 bytes.

I also noticed this:

Mar 15 19:08:33 localhost fetchmail[13766]: 1 message for cpollock at pop.earthlink.net (2014 octets).
Mar 15 18:08:33 localhost kernel: Inbound IN=eth0 OUT= MAC=00:0f:ea:33:8f:ef:00:13:49:6e:55:07:08:00 SRC=203.178.141.138 DST=192.168.2.2 LEN=146 TOS=0x00 PREC=0x00 TTL=48 ID=0 DF PROTO=UDP SPT=53 DPT=32768 LEN=126

So I still have some time issues from somewhere it appears.

Toadman 03-16-2007 07:14 PM

Although I didn't think it would be necessary a cold boot of the box fixed the problem. Hardware and system time are also now synced. Thanks for all for the suggestions.

Chris


All times are GMT -5. The time now is 05:18 PM.