]>
Commit | Line | Data |
---|---|---|
ee486472 | 1 | <?xml version='1.0'?> <!--*-nxml-*--> |
ee486472 | 2 | <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" |
12b42c76 | 3 | "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"> |
ee486472 LP |
4 | |
5 | <!-- | |
572eb058 | 6 | SPDX-License-Identifier: LGPL-2.1+ |
ee486472 LP |
7 | --> |
8 | ||
9 | <refentry id="locale.conf"> | |
798d3a52 ZJS |
10 | <refentryinfo> |
11 | <title>locale.conf</title> | |
12 | <productname>systemd</productname> | |
798d3a52 ZJS |
13 | </refentryinfo> |
14 | ||
15 | <refmeta> | |
16 | <refentrytitle>locale.conf</refentrytitle> | |
17 | <manvolnum>5</manvolnum> | |
18 | </refmeta> | |
19 | ||
20 | <refnamediv> | |
21 | <refname>locale.conf</refname> | |
22 | <refpurpose>Configuration file for locale settings</refpurpose> | |
23 | </refnamediv> | |
24 | ||
25 | <refsynopsisdiv> | |
26 | <para><filename>/etc/locale.conf</filename></para> | |
27 | </refsynopsisdiv> | |
28 | ||
29 | <refsect1> | |
30 | <title>Description</title> | |
31 | ||
32 | <para>The <filename>/etc/locale.conf</filename> file configures | |
b938cb90 | 33 | system-wide locale settings. It is read at early boot by |
798d3a52 ZJS |
34 | <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>.</para> |
35 | ||
36 | <para>The basic file format of <filename>locale.conf</filename> is | |
37 | a newline-separated list of environment-like shell-compatible | |
38 | variable assignments. It is possible to source the configuration | |
39 | from shell scripts, however, beyond mere variable assignments, no | |
40 | shell features are supported, allowing applications to read the | |
41 | file without implementing a shell compatible execution | |
42 | engine.</para> | |
43 | ||
44 | <para>Note that the kernel command line options | |
45 | <varname>locale.LANG=</varname>, | |
46 | <varname>locale.LANGUAGE=</varname>, | |
47 | <varname>locale.LC_CTYPE=</varname>, | |
48 | <varname>locale.LC_NUMERIC=</varname>, | |
49 | <varname>locale.LC_TIME=</varname>, | |
50 | <varname>locale.LC_COLLATE=</varname>, | |
51 | <varname>locale.LC_MONETARY=</varname>, | |
52 | <varname>locale.LC_MESSAGES=</varname>, | |
53 | <varname>locale.LC_PAPER=</varname>, | |
54 | <varname>locale.LC_NAME=</varname>, | |
55 | <varname>locale.LC_ADDRESS=</varname>, | |
56 | <varname>locale.LC_TELEPHONE=</varname>, | |
57 | <varname>locale.LC_MEASUREMENT=</varname>, | |
58 | <varname>locale.LC_IDENTIFICATION=</varname> may be | |
59 | used to override the locale settings at boot.</para> | |
60 | ||
61 | <para>The locale settings configured in | |
62 | <filename>/etc/locale.conf</filename> are system-wide and are | |
63 | inherited by every service or user, unless overridden or unset by | |
64 | individual programs or individual users.</para> | |
65 | ||
66 | <para>Depending on the operating system, other configuration files | |
67 | might be checked for locale configuration as well, however only as | |
68 | fallback.</para> | |
69 | ||
aaa50185 | 70 | <para><filename>/etc/locale.conf</filename> is usually created and updated |
8968e36f ZJS |
71 | using |
72 | <citerefentry><refentrytitle>systemd-localed.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. | |
73 | <citerefentry project='man-pages'><refentrytitle>localectl</refentrytitle><manvolnum>1</manvolnum></citerefentry> | |
798d3a52 ZJS |
74 | may be used to alter the settings in this file during runtime from |
75 | the command line. Use | |
76 | <citerefentry><refentrytitle>systemd-firstboot</refentrytitle><manvolnum>1</manvolnum></citerefentry> | |
8968e36f | 77 | to initialize them on mounted (but not booted) system images.</para> |
798d3a52 ZJS |
78 | </refsect1> |
79 | ||
80 | <refsect1> | |
81 | <title>Options</title> | |
82 | ||
83 | <para>The following locale settings may be set using | |
84 | <filename>/etc/locale.conf</filename>: | |
85 | <varname>LANG=</varname>, | |
86 | <varname>LANGUAGE=</varname>, | |
87 | <varname>LC_CTYPE=</varname>, | |
88 | <varname>LC_NUMERIC=</varname>, | |
89 | <varname>LC_TIME=</varname>, | |
90 | <varname>LC_COLLATE=</varname>, | |
91 | <varname>LC_MONETARY=</varname>, | |
92 | <varname>LC_MESSAGES=</varname>, | |
93 | <varname>LC_PAPER=</varname>, | |
94 | <varname>LC_NAME=</varname>, | |
95 | <varname>LC_ADDRESS=</varname>, | |
96 | <varname>LC_TELEPHONE=</varname>, | |
97 | <varname>LC_MEASUREMENT=</varname>, | |
98 | <varname>LC_IDENTIFICATION=</varname>. | |
99 | Note that <varname>LC_ALL</varname> may not be configured in this | |
100 | file. For details about the meaning and semantics of these | |
101 | settings, refer to | |
3ba3a79d | 102 | <citerefentry project='man-pages'><refentrytitle>locale</refentrytitle><manvolnum>7</manvolnum></citerefentry>.</para> |
798d3a52 ZJS |
103 | </refsect1> |
104 | ||
105 | <refsect1> | |
106 | <title>Example</title> | |
107 | ||
108 | <example> | |
109 | <title>German locale with English messages</title> | |
110 | ||
111 | <para><filename>/etc/locale.conf</filename>:</para> | |
112 | ||
113 | <programlisting>LANG=de_DE.UTF-8 | |
409dee2e | 114 | LC_MESSAGES=en_US.UTF-8</programlisting> |
798d3a52 ZJS |
115 | </example> |
116 | ||
117 | </refsect1> | |
118 | ||
119 | <refsect1> | |
120 | <title>See Also</title> | |
121 | <para> | |
122 | <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>, | |
3ba3a79d ZJS |
123 | <citerefentry project='man-pages'><refentrytitle>locale</refentrytitle><manvolnum>7</manvolnum></citerefentry>, |
124 | <citerefentry project='man-pages'><refentrytitle>localectl</refentrytitle><manvolnum>1</manvolnum></citerefentry>, | |
798d3a52 ZJS |
125 | <citerefentry><refentrytitle>systemd-localed.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>, |
126 | <citerefentry><refentrytitle>systemd-firstboot</refentrytitle><manvolnum>1</manvolnum></citerefentry> | |
127 | </para> | |
128 | </refsect1> | |
ee486472 LP |
129 | |
130 | </refentry> |