The translation is temporarily closed for contributions due to maintenance, please come back later.
English Persian
System Locale and Keyboard Configuration
indexterm:[keyboard configuration] The *system locale* specifies the language settings of system services and user interfaces. The *keyboard layout* settings control the layout used on the text console and graphical user interfaces.
These settings can be made by modifying the `/etc/locale.conf` configuration file or by using the [application]*localectl* utility. Also, you can use the graphical user interface to perform the task; for a description of this method, see link:++[{MAJOROS} Installation Guide].
Setting the System Locale
System-wide locale settings are stored in the `/etc/locale.conf` file, which is read at early boot by the `systemd` daemon. The locale settings configured in `/etc/locale.conf` are inherited by every service or user, unless individual programs or individual users override them.
The basic file format of `/etc/locale.conf` is a newline-separated list of variable assignments. For example, German locale with English messages in `/etc/locale.conf` looks as follows:
Here, the LC_MESSAGES option determines the locale used for diagnostic messages written to the standard error output. To further specify locale settings in `/etc/locale.conf`, you can use several other options, the most relevant are summarized in xref:System_Locale_and_Keyboard_Configuration.adoc#tab-locale_options[Options configurable in /etc/locale.conf]. See the `locale(7)` manual page for detailed information on these options. Note that the LC_ALL option, which represents all possible options, should not be configured in `/etc/locale.conf`.
Options configurable in /etc/locale.conf
|LANG|Provides a default value for the system locale.
|LC_COLLATE|Changes the behavior of functions which compare strings in the local alphabet.
|LC_CTYPE|Changes the behavior of the character handling and classification functions and the multibyte character functions.
|LC_NUMERIC|Describes the way numbers are usually printed, with details such as decimal point versus decimal comma.
|LC_TIME|Changes the display of the current time, 24-hour versus 12-hour clock.
|LC_MESSAGES|Determines the locale used for diagnostic messages written to the standard error output.
Displaying the Current Status
The [command]#localectl# command can be used to query and change the system locale and keyboard layout settings. To show the current settings, use the [option]`status` option:
[command]#localectl# [option]`status`
The output of the previous command lists the currently set locale, keyboard layout configured for the console and for the X11 window system.
~]${nbsp}localectl status
System Locale: LANG=en_US.UTF-8
VC Keymap: us
X11 Layout: n/a
Listing Available Locales
To list all locales available for your system, type:
[command]#localectl# [option]`list-locales`
Listing Locales
Imagine you want to select a specific English locale, but you are not sure if it is available on the system. You can check that by listing all English locales with the following command: