Go to main content

International Language Environments Guide for Oracle® Solaris 11.3

Exit Print View

Updated: December 2018
 
 

Setting the Locale in a Terminal Session

You can change the locale in a terminal session by setting the LANG variable as follows:

$ export LANG=locale

For example, to change to the de_DE.UTF-8 locale, use the following command:

$ export LANG=de_DE.UTF-8

To verify the locale has been successfully changed, run the locale command:

$ locale
LANG=de_DE.UTF-8 
LC_CTYPE="de_DE.UTF-8" 
LC_NUMERIC="de_DE.UTF-8"
LC_TIME="de_DE.UTF-8" 
LC_COLLATE="de_DE.UTF-8" 
LC_MONETARY="de_DE.UTF-8" 
LC_MESSAGES="de_DE.UTF-8" 
LC_ALL=

For more information, see the locale(1) man page.

To obtain the list of locales available in a system, use the following command:

$ locale -a

For more information about installing more locales, see Managing Available Locales.