/etc insider

since 1999 (and still editing)

What time zone does localtime define?

| Comments

Someday you wake up having a hangover headache, issue date to locate yourself in time and realize you have no idea where did /etc/localtime come from? This oneliner can help:

1
2
find /usr/share/zoneinfo -type f | xargs -r md5sum | fgrep `md5sum /etc/localtime|cut -d' ' -f1`
e4ca381035a34b7a852184cc0dd89baa  /usr/share/zoneinfo/posixrules

of course /etc/localtime happens to be a symlink sometimes, but this is too trivial even for hangover.

Comments