Hi,

I got the UNIX shell (ie logs) and asterisk voicemail to work with timezones.  I don't have any new revelations, just putting together the pieces from others here.

FYI, I am using a Soekris with a three partition CF; /, /mnt/opt, and /mnt/kd .

Key points:
1)  The zoneinfo database from 0.3.0 ( /mnt/opt/zoneinfo ) works fine with asterisk in 0.4.2, just file data structures, no library code.

2)  We need a new rc.conf variable, say TIMEZONE_TZ to set the unique uClibc timezone data.  Someday an automatic method of generating TIMEZONE_TZ from TIMEZONE would be good... but until then the user can just set it.

This is what I did:

1) Create a zoneinfo directory in /mnt/opt/.  Copy as many entries (Country/City) as you need from /mnt/opt/ of 0.3.0.

The files can be found here: (remember they are binary files when moving them)

2) Create a symbolic link from /usr/share/zoneinfo to /mnt/opt/zoneinfo

ln -s /mnt/opt/zoneinfo /usr/share/zoneinfo

3) Add a new TIMEZONE_TZ variable to rc.conf

##Timezone
##You need ast-opt for the additional timezones.
##If you define this variable, AstLinux will copy this file from
##/mnt/opt/zoneinfo/$TIMEZONE to /tmp/etc/localtime on startup
## Until TIMEZONE_TZ is generated from TIMEZONE we have to do it by hand
##GMT (UTC) is the default
TIMEZONE=America/Chicago
TIMEZONE_TZ=CST6CDT

4) Change /etc/rc, the timezone section should look like this

if [ -f /mnt/kd/TZ ]
then
cp /mnt/kd/TZ /tmp/etc/TZ
fi

if [ "$TIMEZONE_TZ" ]
then
echo "$TIMEZONE_TZ" > /tmp/etc/TZ
fi

if [ "$TIMEZONE" ]
then
cp /mnt/opt/zoneinfo/$TIMEZONE /tmp/etc/localtime
fi

5) Configure your voicemail.conf with a "tz=" and [zonemessages] entries.

6) reboot

That is all there is to it.
If this looks good to Darrick and Kristian they can add it.

Lonnie



_______________________________________________
Astlinux-users mailing list
[email protected]
http://lists.kriscompanies.com/mailman/listinfo/astlinux-users

Donations to support AstLinux are graciously accepted via PayPal to [EMAIL 
PROTECTED]

Reply via email to