[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#822733: tzdata: Drop /etc/timezone



On 2016-04-26 23:37, Martin Pitt wrote:
> Package: tzdata
> Version: 2016d-2
> Severity: wishlist
> 
> /etc/localtime got turned into a symlink in 2016a-1 (see bug #803144),
> now that /usr gets mounted from the initrd.
> 
> This now leaves /etc/timezone completely redundant, as you should get
> exactly the same answer by readlink /etc/localtime -- and if you do
> not get the same answer, you have an inconsistency. /etc/localtime
> obviously "wins" for the actual clock (as that's what programs are
> reading), but you presumably get the /etc/timezone value in some
> "system configuration tool" packages which read /etc/timezone first.
> 
> https://codesearch.debian.net/perpackage-results/%2Fetc%2Ftimezone
> shows a fair number of hits, but it's actually not so bad: as
> /etc/timezone is a Debianism and /etc/localtime the distro-agnostic
> standard, a lot of software which isn't Debian specific already looks
> at both and only falls back to /etc/timezone if /etc/localtime does
> not exist. A desktop installation boots fine and with the correct
> time/zone after removing /etc/timezone.

Unfortunately it seems a lot of software are actually using
/etc/timezone to configure the time zone. When switching to a symlink
this made people unhappy, see for example bug#813226. This bug points to
the following query:

https://github.com/search?q=%2Fetc%2Ftimezone+dpkg-reconfigure+noninteractive+tzdata&type=Code&utf8=%E2%9C%93

> If you are generally open to the idea, I can look through the above
> codesearch results more closely to see which packages need fixing,
> file bugs, and block this bug on those. But as that's quite some work,
> I'd first like to discuss this with you.

What we can probably do is to stop looking or creating /etc/timezone
if it doesn't exist, but keep updating it if it exists. What do you
think?

Aurelien

-- 
Aurelien Jarno                          GPG: 4096R/1DDD8C9B
aurelien@aurel32.net                 http://www.aurel32.net

Attachment: signature.asc
Description: PGP signature


Reply to: