locale.conf — Configuration file for locale settings
/etc/locale.conf file configures
system-wide locale settings. It is read at early boot by
The format of
locale.conf is a newline-separated list of environment-like
shell-compatible variable assignments, ignoring comments and empty lines. It is possible to source the
configuration from shell scripts, however, beyond mere variable assignments, no shell features are
supported, allowing applications to read the file without implementing a shell compatible execution
os-release(5) for a
detailed description of the format.
Note that the kernel command line options
locale.LC_IDENTIFICATION= may be
used to override the locale settings at boot.
The locale settings configured in
/etc/locale.conf are system-wide and are
inherited by every service or user, unless overridden or unset by
individual programs or users.
Depending on the operating system, other configuration files might be checked for locale configuration as well, however only as fallback.
/etc/locale.conf can be updated
may be used to alter the settings in this file during runtime from
the command line. Use
to customize them on mounted (but not booted) system images.
The following locale settings may be set using
LC_ALL may not be configured in this
file. For details about the meaning and semantics of these
settings, refer to
Example 1. German locale with English messages
# Custom settings LANG=de_DE.UTF-8 LC_MESSAGES=en_US.UTF-8