IBM Support

How to change the LOCALE (Language and Country) and TIMEZONE for the IBM Technology for Java (IT4J) VM on the IBM i?

Question & Answer


Question

This document describes how to change the LOCALE (Language and Country) and TIMEZONE for an IBM Technology for Java™ (IT4J) VM on the IBM i.

Answer

The default time zone, language, and country used by the IBM Technology for Java™ (IT4J) VM can be changed by setting the "user.timezone", "user.language", and "user.country" Java™ properties.

NOTE: The "user.language" and "user.country" properties make up the LOCALE used by the IT4J.  You can include the Java™ properties in the /QIBM/UserData/Java400/SystemDefault.properties file to change these properties system-wide for all JVMs on the IBM i. The SystemDefault.properties file must have a CCSID of 819 or 1252.

user.timezone

  • Java Property:
    • user.timezone=America/Chicago
      (This will set the time zone to the US Central Time Zone)

    JVM Argument:
    • -Duser.timezone=America/New_York
      (This will set the time zone to the US Eastern Time Zone)

    Some examples of supported time zone values are listed here.
  • NOTE: Use the "Alternate Name" as the value for the "user.timezone" property.

user.language

  • Java Property:
    • user.language=es
      (This will set the language to Spanish)




    •  
    • JVM Argument:
      • -Duser.language=de
        (This will set the language to German)

    user.country

    • Java Property:
      • user.country=CA
        (This will set the country to Canada)

      JVM Argument:
      • -Duser.country=DE
        (This will set the country to Germany)

    More information on the "user.language" and "user.country" Java™ properties and values can be found here.

[{"Type":"MASTER","Line of Business":{"code":"LOB57","label":"Power"},"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SWG60","label":"IBM i"},"Platform":[{"code":"PF012","label":"IBM i"}],"Version":"7.1.0"}]

Document Information

Modified date:
18 December 2019

UID

nas8N1020141