74 days ago
Manually adjusting daylight savings time on Ubuntu
Without so much as a ‘by your leave’ Fiji’s government has decided to implement daylight savings … on 3 weeks notice!
Whatever the justification for daylight savings, short notice is generally a “Very Bad Idea”® particularly when there are computer systems involved.
This post on TripAdvisor hints at some of the confusion this change is causing.
All time-sensitive travel events and tickets with any international connection booked for December 2009 to April 2010, before the daylight savings were announced, now carry invalid information.
@sanjuroku suggests that the best way to manage this confusion is to ignore the changes and proceed as usual on Fiji Standard Time.
@avonsys suggests switching to New Zealand Time for a while.
If these float your boat, then so be it. If you, like me, are a bit OC about this sort of thing, then you can roll up your sleeves and rewire your system.
I addressed the Windows junkies on Twitter
Update: Microsoft has just released a hotfix to allow for Fiji Daylight Savings: KB977748
I now offer up the following guide to manually editing time zone rules for Fiji’s tiny Ubuntu (and Debian) community.
Fire up a terminal and make yourself a safe place to play
$ mkdir /tmp/tzdata
$ cd /tmp/tzdata
Now let’s get the official time zone data (and if necessary, the tools to work with it)
$ apt-get install dpkg-dev (if you don’t already have this)
$ apt-get source tzdata
Let’s find the data that references Fiji
$ cd tzdata-2009r
$ nano australasia (or use vi or emacs or whatever puts text-editing hair on your chest)
Look for the Fiji section (around line 250) and add these 2 rules below the existing rules.
Rule Fiji 2009 only - Nov lastSun 2:00 1:00 S Rule Fiji 2010 only - Apr lastSun 3:00 0 -
These boil down as follows:
- For the timezone ‘Fiji’, on the last Sunday of November (in 2009 only), adjust the time to save 1 hour and change the time code to FJST.
- For the timezone ‘Fiji’, on the last Sunday of April (in 2010 only), revert the time so there is no difference from normal Fiji Time, and revert the time code to FJT.
Save the file and exit your text editor.
Now we compile our new rules, and tell the system to start using them.
$ sudo /usr/sbin/zic australasia
$ sudo dpkg-reconfigure tzdata
Select Pacific then Fiji
Now let’s make sure the new time rules are showing up:
$ zdump -v /etc/localtime | egrep ’2009|2010’
Should look something like this:
/etc/localtime Sat Nov 28 13:59:59 2009 UTC = Sun Nov 29 01:59:59 2009 FJT isdst=0 gmtoff=43200
/etc/localtime Sat Nov 28 14:00:00 2009 UTC = Sun Nov 29 03:00:00 2009 FJST isdst=1 gmtoff=46800
/etc/localtime Sat Apr 24 13:59:59 2010 UTC = Sun Apr 25 02:59:59 2010 FJST isdst=1 gmtoff=46800
/etc/localtime Sat Apr 24 14:00:00 2010 UTC = Sun Apr 25 02:00:00 2010 FJT isdst=0 gmtoff=43200
Now we’re good for this year. Let’s hope “the powers that be” give us all a little more warning next time.
Hat tip to http://wiki.debian.org/TimeZoneChanges
Filed by Jachin Sheehy under Living-in-Fiji Software
Comment [397]






