Debian and a hardware clock set to local time
Linux, Open Source March 1st, 2006For some reason, I’ve always set the hardware clocks on my systems to local time, rather than UTC. Although I know this isn’t the recommended approach, it’s never been a problem as we don’t have daylight savings time in South Africa. Since I upgraded my laptop from Debian GNU/Linux 3.1 to testing, however, after every reboot the system time has been out of sync with the hardware time. The two differed by the difference between local time and UTC.
After much Googling, I discovered that the cause of the problem is the init script that sets the system clock. It is called before /usr is mounted, which means that /etc/localtime (which points to the correct timezone in /usr/share/zoneinfo) is a dangling symlink. To work around the problem, I copied the correct timezone file to /etc/localtime, thereby making it available before /usr is mounted. An ugly workaround, but it seems to have solved the problem.
For more information, see bug #342887.

Recent Comments