Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Update timezone files for earlier Daylight Savings Time UNIX
I noticed on my MacBook (OS X 10.4.8) that the underlying UNIX based system (POSIX) was not going to update correctly for the Daylight Savings Time (DST) change in my time zone (America/Vancouver). To determine if your time zone has an issue, run this command in Terminal:
foo$ zdump -v /etc/localtime | grep 2007
If you see this in the output, then your DST will not start (or end) on the correct day:

/etc/localtime  Sun Apr  1 09:59:59 2007 UTC = Sun Apr  1 01:59:59 2007 PST isdst=0
/etc/localtime  Sun Apr  1 10:00:00 2007 UTC = Sun Apr  1 03:00:00 2007 PDT isdst=1
/etc/localtime  Sun Oct 28 08:59:59 2007 UTC = Sun Oct 28 01:59:59 2007 PDT isdst=1
/etc/localtime  Sun Oct 28 09:00:00 2007 UTC = Sun Oct 28 01:00:00 2007 PST isdst=0

Notice that those dates do not correspond to the second Sunday in March nor the first Sunday in November. Read on for a solution to this problem...

[robg adds: For those who aren't aware, DST will start earlier this year in the United States and most of Canada. From the Daylight Savings Time entry at Wikipedia (note the start and end dates for 2007):
DST commonly begins in the northern hemisphere on the last Sunday in March or the first Sunday in April and ends on the last Sunday in October. However, due to the Energy Policy Act of 2005, beginning in 2007, the United States will begin observing DST from the second Sunday in March until the first Sunday in November.
I looked at most of the US timezone files (Pacific, Central, etc.), and they all seem to be correct -- so many of you may not have to implement the solution explained in the remainder of this hint.]

The localtime file is actually just an alias to another file, as seen here (line break added for narrower display):
foo$ ls -lah /etc/localtime 
lrwxr-xr-x   1 root  wheel  37B Jan  8 06:19 /etc/localtime -> 
 /usr/share/zoneinfo/America/Vancouver
To fix the problem, you need to update the source file:
  1. Go to this nih.gov server and grab the file tzdata2007a.tar.gz. This filename may change over time, as new updates are added to the database. Just copy and paste the FTP URL into Safari to start.
  2. Extract the contents of the archive to a local folder (Stuffit Expander does a fine job if you don't know how); my folder is called tzdata2007a.
  3. In Terminal, cd into that folder and run the following commands. Note that the modifications I'm after are in the file named northamerica. However, some modifications where made to the europe and africa files as well, and the last command, zic backwards, will complain if you don't include them. Here are the commands to run:
    foo$ cd /path/to/tzdata2007a
    foo$ sudo zic europe
    foo$ sudo zic africa 
    foo$ sudo zic northamerica 
    foo$ sudo zic backwards
That's it; you're done. Check your results with the original command again:
foo$ zdump -v /etc/localtime | grep 2007
You should now see Mar 11 and Nov 4, instead of the original Apr 1 and Oct 28. Much better!
    •    
  • Currently 2.80 / 5
  You rated: 3 / 5 (5 votes cast)
 
[41,904 views]  

Update timezone files for earlier Daylight Savings Time | 25 comments | Create New Account
Click here to return to the 'Update timezone files for earlier Daylight Savings Time' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Update timezone files for earlier Daylight Savings Time
Authored by: dmeyer0 on Jan 31, '07 08:12:04AM

I didn't need to do this for my Powerbook, but it worked like a charm for two of my older Linux boxes. Thank you.



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: smkolins on Feb 09, '07 02:26:02PM
Hmm waters getting muddied. Over at macenterprises lists many things that need to be updated - and Java for 10.4(.6) seems to be one of them - specifically "Java SE 5 – Update 6 or later". This is also a semi-formal response indirectly from Apple as they are hip deep with the macenterprise folks....

---
Possess a pure, kindly, and radiant heart!

[ Reply to This | # ]

Update timezone files for earlier Daylight Savings Time
Authored by: smkolins on Feb 09, '07 05:10:23PM
I correct myself - on 10.4.8 with J2SE50Release4 instralled the terminal reports ( java - version) 1.5.0_06 (and subversions for different sections.) So Java 1.5 is ok. But 1.4.2 and 1.3.1 are still details - depending on when either of them are needed. I see a knowledge article and another says at the bottom: "1.3.1_16" and "1.4.2_09" so I wonder about those?

---
Possess a pure, kindly, and radiant heart!

[ Reply to This | # ]

In case it's not clear
Authored by: mgpalma on Jan 31, '07 08:40:54AM

Just type

zdump -v /etc/localtime | grep 2007

Don't include foo$

Works like a charm.



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: bjakuc on Jan 31, '07 09:28:08AM
I find this odd. You say your system is 10.4.8 but check out this doc:

http://docs.info.apple.com/article.html?artnum=303411

These are the release notes for the Mac OS X v10.4.6 update. If you check out the last section at the bottom of the page called "Other" you'll see the first item is the DST patch to comply with the Energy Policy Act of 2005.

I ran your command and this was my output:

foo$ zdump -v /etc/localtime | grep 2007
/etc/localtime Sun Mar 11 06:59:59 2007 UTC = Sun Mar 11 01:59:59 2007 EST isdst=0
/etc/localtime Sun Mar 11 07:00:00 2007 UTC = Sun Mar 11 03:00:00 2007 EDT isdst=1
/etc/localtime Sun Nov 4 05:59:59 2007 UTC = Sun Nov 4 01:59:59 2007 EDT isdst=1
/etc/localtime Sun Nov 4 06:00:00 2007 UTC = Sun Nov 4 01:00:00 2007 EST isdst=0

So you see mine is correct and I am also running v10.4.8. I'm in the New York area: EST (GMT -5).

Did Apple patch some timezones and not others?

---
Cheers!
-- Bob Jakuc


[ Reply to This | # ]

Update timezone files for earlier Daylight Savings Time
Authored by: barbarella on Jan 31, '07 09:43:00AM

I'm in Central and my 10.4.8 system shows the correct values.



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: kyngchaos on Jan 31, '07 10:05:27AM

I just checked all the US timezones, all OK.

MacBook (Core Duo) 10.4.8, all security updates, I've always applied combo updaters. I also checked a PB G4, 10.4.7, same method of applting combo updaters.

A 10.3.9 Mac I checked needs the update.



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: plambert on Jan 31, '07 10:13:53AM

It looks like the US timezone entries were updated, but not all the others were.

Those affected should file a bug with Apple, or if you've AppleCare coverage, contact them and report the problem.



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: brainbox1100 on Jan 31, '07 11:43:58AM

Hi:

Whatever patch Apple release may have updated your time zone. The localtime is just a link to the appropriate time zone file, so it will be different from system to system depending on where the Mac thinks it is. The article does a listing of the file to show it's a link.

My actual time zone is America/Vancouver (America as in the continent, not the country so that's Vancouver Canada as apposed to Vancouver Washington).

zdump -v America/Vancouver | grep 2007



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: Kip on Jan 31, '07 01:14:34PM

I'm guessing that since observation of Daylight Saving Time is up to the discretion of each province individually in Canada, that perhaps Apple hadn't researched in time for the 10.4.6 update (released April 3, 2006) whether or not Canadian provinces were going to switch.

I imagine that Apple will update the other timezones with a patch before March.



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: stevebr on Feb 01, '07 09:21:19AM

You are correct about the provinces getting discretion.

FWIW, on my machine (10.4.8) America/Montreal and America/Toronto both have the new date, while America/Vancouver does not. I know Quebec and Ontario are both going to use the new date, but I don't know about BC.

The zoneinfo may be correct if BC isn't switching to the new dates. If they are, somebody needs to tell Apple in the next couple of weeks.

Aside:
As if the switch wasn't boneheaded enough, the Canadian federal government had to leave it up to the provinces. Decentralization is fine and dandy, but applying it to something that needs national and even international standards to umm... you know... *work properly* is just plain stupid.



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: morespace54 on Feb 01, '07 11:43:14AM

Well on this Mac (10.3.9) in America/Montreal, the date has not been updated. Did Apple only updated Tiger clients?



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: stevebr on Feb 01, '07 01:07:52PM

It would seem so. Other posts attached to this hint mention a 3rd-party patch available via AFP548 that should help in your situation.



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: Kip on Feb 15, '07 07:06:32PM
I see that Apple has released a new update to the timezone files. http://docs.info.apple.com/article.html?artnum=305056

[ Reply to This | # ]
It's easier with a man-made patch
Authored by: brett_x on Jan 31, '07 10:43:22AM
A user at AFP548.com has posted a patch (in a package installer or a script) to update the time zone properly for those who are stuck in 10.3 land. (I trust it since it's been posted on the site for a few days, but always verify what you are installing before putting in your admin name / password.)

http://www.afp548.com/article.php?story=20070128143720897



[ Reply to This | # ]
Hint doesn't update everything, use AFP548 patch
Authored by: extra88 on Jan 31, '07 11:43:59AM
First, the 10.4.6 update should have corrected this for Tiger users. I would be concerned about other things not being updated and retry using an OS X Combo update rather than simply updating the zoneinfo stuff manually.

Second, for Panther users, following these instructions only updates one location of time zone info. There's a second one called ICU which needs to be updated through different means. ICU is what affects iCal, the menubar clock, and (I think) any Cocoa app that cares about the time.

The page on AFP548 brett linked to has a link to an installer package that will update both zoneinfo and ICU data. If you don't feel like trusting it, there's also a shell script you can use to download, compile, and install the new data. You can edit the script to stop where you want or perform the commands manually. The AFP548 article says it's for 10.3.9 but it might also work on Macs running Jaguar. At very least, the shell script would be a good place to start for fixing it yourself.

Here's the article link again:
http://www.afp548.com/article.php?story=20070128143720897


[ Reply to This | # ]
Hint doesn't update everything, use AFP548 patch
Authored by: brainbox1100 on Jan 31, '07 11:46:06AM

That's why this is listed as a UNIX hint and not a 10.4 or 10.3 hint. Thanks for pointing this out though; I'll check them as well.



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: gxw on Jan 31, '07 07:05:50PM

FYI, the Canada/Mountain time zone was not updated by the 4.6 patch.



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: gboudrea on Feb 01, '07 03:49:23AM

America/Montreal was fine (not sure since when; 4.6 I'd guess).



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: SketchyClown on Feb 01, '07 02:47:31PM
Thanks for the Hint. I too am in Vancouver and had heard that the 10.4.6 update had patched this. I was unaware that it hadn't patched my time zone though. Followed your instructions and it worked like a charm. Thanks again!

---
If it ain't broke, don't fix it!

[ Reply to This | # ]

Update timezone files for earlier Daylight Savings Time
Authored by: BeowulfVsGrendel on Feb 07, '07 09:06:16AM

I typed this:

my-computer-power-mac-g5:~ mycomp$ foo$ zdump -v /etc/localtime | grep 2007

and the following is how Terminal responded:

-bash: foo$: command not found

After typing it with different spaces, etc., tried copying and pasting. The basic problem seems to be foo$



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: smkolins on Feb 09, '07 11:38:40AM

yeap, foo $ is some kind of generic string for the command prompt. Not stupposed to be typed.

---
Possess a pure, kindly, and radiant heart!



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: kyngchaos on Mar 12, '07 08:25:30AM

Well, that didn't work. None of the Macs where I work that I updated the timezone files with this method had the new daylight savings kick in. All the other Macs where I updated with Apple's timezone update are OK. Apple must be doing something else than just the unix timezone system.



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: kyngchaos on Mar 12, '07 08:52:16AM

Aha! The system time DID update. It's just the menubar clock that's wrong. That must be the extra bit included in Apple's timezone update.



[ Reply to This | # ]
Update timezone files for earlier Daylight Savings Time
Authored by: barbie187 on Mar 12, '07 05:19:14PM

Your systems should work correctly if you swap /usr/share/icu/icudt32b.dat with one from a correctly patched system.



[ Reply to This | # ]