Jun 11 2011

This guide is to learn how to set correctly the timezone in a Gentoo Linux and Mexico/General timezone.

First copy or link the proper zone to localtime:

pluton ~ # ln -sf /usr/share/zoneinfo/Mexico/General /etc/localtime
pluton ~ # ls -l /etc/localtime
lrwxrwxrwx 1 root root 23 Jun  6 18:13 /etc/localtime -> /usr/share/zoneinfo/GMT

Now specify your timezone:

pluton ~ # cat /etc/conf.d/hwclock
TIMEZONE="Mexico/General"

clock="UTC"
clock_systohc="YES"
clock_hctosys="YES"
clock_args=""

Restart the service:

pluton ~ # /etc/init.d/hwclock restart
 * WARNING: you are stopping a boot service
 * Caching service dependencies ...                                                                                                                                                                 [ ok ]
 * Setting hardware clock using the system clock [UTC] ...                                                                                                                                          [ ok ]
 * Setting system clock using the hardware clock [UTC] ... 

And that's it:

pluton ~ # date
Mon Jun  6 18:24:57 GMT 2011