[Contents] [Prev] [Next] [Index] [Report an Error]

How to Import and Install Time Zone Files

To import and install time zone files, follow these steps:

  1. Download the time zone files archive and untar them to a temporary directory such as /var/tmp:
    # mkdir -p /var/tmp/tz && cd /var/tmp/tz && rm *
    
    # wget 'ftp://elsie.nci.nih.gov/pub/tzdata*.tar.gz'
    # tar xvzf tzdata*.gz

    africa
    antarctica
    asia
    australasia
    europe
    northamerica
    southamerica
    pacificnew
    etcetera
    factory
    backward
    systemv
    solar87
    solar88
    solar89
    iso3166.tab
    zone.tab
    leapseconds
    yearistype.sh

    Note: If needed, you can edit the above untarred files to create or modify time zones.

  2. Select the names of time zone files to compile and feed them to the following script.
    For example, to generate northamerica and asia tz files:
    # /usr/libexec/ui/compile-tz northamerica asia
    
  3. Enable the use of the generated tz files using the CLI:
    [edit]
    # set system use-imported-time-zones

    [edit]
    # set system time-zone ?

    This should show the newly generated tz files in /var/db/zoneinfo/.

  4. Set the time zone and commit:
    [edit]
    # set system time-zone <your-time-zone>
    # commit
  5. Verify that the time zone change has taken effect:
    [edit]
    # run show system uptime

[Contents] [Prev] [Next] [Index] [Report an Error]