> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] Behalf Of Lisa Casey
> Sent: Saturday, March 01, 2008 12:19 PM
> To: freebsd-questions@freebsd.org
> Subject: Daylight Savings time
> 
> 
> Hi,
> 
> I suspect my FreeBSD 5.2 system isn't going to handle the change 
> to Daylight Savings Time correctly next weekend:
> 
> zdump -v /etc/localtime | grep 2008
> /etc/localtime  Sun Apr  6 06:59:59 2008 UTC = Sun Apr  6 
> 01:59:59 2008 EST isdst=0 gmtoff=-18000
> /etc/localtime  Sun Apr  6 07:00:00 2008 UTC = Sun Apr  6 
> 03:00:00 2008 EDT isdst=1 gmtoff=-14400
> /etc/localtime  Sun Oct 26 05:59:59 2008 UTC = Sun Oct 26 
> 01:59:59 2008 EDT isdst=1 gmtoff=-14400
> /etc/localtime  Sun Oct 26 06:00:00 2008 UTC = Sun Oct 26 
> 01:00:00 2008 EST isdst=0 gmtoff=-18000
> 
> Could someone help me remember the steps I need to take to correct this?
> 

Here's a little very hacky script I put together last year.
I forget where you get the current timezone files, you can
google for that.  The process is explained in the script.
you will need to adjust for your location, it should be
obvious where.

Some BSD versions uses a link.  Some other unices just copy the zonefile
in.  I manage a number of different unices.


#!/bin/sh
zdump -v /etc/localtime | grep 2007
echo  If sun Mar 11 and Nov 1 then OK
echo Otherwise stop script now and rerun from clean temp dir
echo "also ls -l /etc |more and check that localtime is not a link"
sleep 5
fetch ftp://server.example.com/pub/tzdata2007c.tar.gz
tar -xzf tzdata2007c.tar.gz
zic -d zoneinfo northamerica
cp -R zoneinfo/* /usr/share/zoneinfo
zdump -v /usr/share/zoneinfo/PST8PDT | grep 2007
zdump -v /usr/share/zoneinfo/America/Los_Angeles | grep 2007
echo "if localtime is a link then Cntl-C, stop and rm /etc/localtime then"
echo "ln -s /usr/share/zoneinfo/PST8PDT /etc/localtime"
sleep 5
cp /usr/share/zoneinfo/PST8PDT /etc/localtime
zdump -v /etc/localtime | grep 2007
echo If Sun Mar 11 and Nov 1 then OK
echo "now rm -r this temp dir"


Ted
_______________________________________________
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Reply via email to