]>
Commit | Line | Data |
---|---|---|
7cd28a8a LP |
1 | <?xml version='1.0'?> <!--*-nxml-*--> |
2 | <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" | |
12b42c76 | 3 | "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"> |
7cd28a8a LP |
4 | |
5 | <!-- | |
6 | This file is part of systemd. | |
7 | ||
8 | Copyright 2012 Lennart Poettering | |
9 | ||
10 | systemd is free software; you can redistribute it and/or modify it | |
11 | under the terms of the GNU Lesser General Public License as published by | |
12 | the Free Software Foundation; either version 2.1 of the License, or | |
13 | (at your option) any later version. | |
14 | ||
15 | systemd is distributed in the hope that it will be useful, but | |
16 | WITHOUT ANY WARRANTY; without even the implied warranty of | |
17 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
18 | Lesser General Public License for more details. | |
19 | ||
20 | You should have received a copy of the GNU Lesser General Public License | |
21 | along with systemd; If not, see <http://www.gnu.org/licenses/>. | |
22 | --> | |
23 | ||
21ac6ff1 | 24 | <refentry id="localectl" conditional='ENABLE_LOCALED' |
798d3a52 ZJS |
25 | xmlns:xi="http://www.w3.org/2001/XInclude"> |
26 | ||
27 | <refentryinfo> | |
28 | <title>localectl</title> | |
29 | <productname>systemd</productname> | |
30 | ||
31 | <authorgroup> | |
32 | <author> | |
33 | <contrib>Developer</contrib> | |
34 | <firstname>Lennart</firstname> | |
35 | <surname>Poettering</surname> | |
36 | <email>lennart@poettering.net</email> | |
37 | </author> | |
38 | </authorgroup> | |
39 | </refentryinfo> | |
40 | ||
41 | <refmeta> | |
42 | <refentrytitle>localectl</refentrytitle> | |
43 | <manvolnum>1</manvolnum> | |
44 | </refmeta> | |
45 | ||
46 | <refnamediv> | |
47 | <refname>localectl</refname> | |
48 | <refpurpose>Control the system locale and keyboard layout settings</refpurpose> | |
49 | </refnamediv> | |
50 | ||
51 | <refsynopsisdiv> | |
52 | <cmdsynopsis> | |
53 | <command>localectl</command> | |
54 | <arg choice="opt" rep="repeat">OPTIONS</arg> | |
55 | <arg choice="req">COMMAND</arg> | |
56 | </cmdsynopsis> | |
57 | </refsynopsisdiv> | |
58 | ||
59 | <refsect1> | |
60 | <title>Description</title> | |
61 | ||
62 | <para><command>localectl</command> may be used to query and change | |
dfc6109f ZJS |
63 | the system locale and keyboard layout settings. It communicates with |
64 | <citerefentry><refentrytitle>systemd-localed</refentrytitle><manvolnum>8</manvolnum></citerefentry> | |
65 | to modify files such as <filename>/etc/locale.conf</filename> and | |
66 | <filename>/etc/vconsole.conf</filename>.</para> | |
798d3a52 ZJS |
67 | |
68 | <para>The system locale controls the language settings of system | |
69 | services and of the UI before the user logs in, such as the | |
70 | display manager, as well as the default for users after | |
71 | login.</para> | |
72 | ||
73 | <para>The keyboard settings control the keyboard layout used on | |
74 | the text console and of the graphical UI before the user logs in, | |
75 | such as the display manager, as well as the default for users | |
76 | after login.</para> | |
77 | ||
dfc6109f ZJS |
78 | <para>Note that the changes performed using this tool might require |
79 | the initramfs to be rebuilt to take effect during early system boot. | |
80 | The initramfs is not rebuilt automatically by <filename>localectl</filename>. | |
81 | </para> | |
82 | ||
83 | <para>Note that | |
798d3a52 | 84 | <citerefentry><refentrytitle>systemd-firstboot</refentrytitle><manvolnum>1</manvolnum></citerefentry> |
dfc6109f | 85 | may be used to initialize the system locale for mounted (but not booted) |
798d3a52 ZJS |
86 | system images.</para> |
87 | </refsect1> | |
88 | ||
89 | <refsect1> | |
90 | <title>Options</title> | |
91 | ||
92 | <para>The following options are understood:</para> | |
93 | ||
94 | <variablelist> | |
95 | <varlistentry> | |
96 | <term><option>--no-ask-password</option></term> | |
97 | ||
98 | <listitem><para>Do not query the user for authentication for | |
99 | privileged operations.</para></listitem> | |
100 | </varlistentry> | |
101 | ||
102 | <varlistentry> | |
103 | <term><option>--no-convert</option></term> | |
104 | ||
105 | <listitem><para>If <command>set-keymap</command> or | |
106 | <command>set-x11-keymap</command> is invoked and this option | |
107 | is passed, then the keymap will not be converted from the | |
108 | console to X11, or X11 to console, | |
109 | respectively.</para></listitem> | |
110 | </varlistentry> | |
111 | ||
112 | <xi:include href="user-system-options.xml" xpointer="host" /> | |
113 | ||
114 | <xi:include href="standard-options.xml" xpointer="help" /> | |
115 | <xi:include href="standard-options.xml" xpointer="version" /> | |
116 | <xi:include href="standard-options.xml" xpointer="no-pager" /> | |
117 | </variablelist> | |
118 | ||
119 | <para>The following commands are understood:</para> | |
120 | ||
121 | <variablelist> | |
122 | <varlistentry> | |
123 | <term><command>status</command></term> | |
124 | ||
125 | <listitem><para>Show current settings of the system locale and | |
126 | keyboard mapping.</para></listitem> | |
127 | </varlistentry> | |
128 | ||
129 | <varlistentry> | |
1eecafb8 | 130 | <term><command>set-locale LOCALE…</command></term> |
798d3a52 ZJS |
131 | |
132 | <listitem><para>Set the system locale. This takes one or more | |
133 | assignments such as "LANG=de_DE.utf8", | |
134 | "LC_MESSAGES=en_GB.utf8", and so on. See | |
3ba3a79d | 135 | <citerefentry project='man-pages'><refentrytitle>locale</refentrytitle><manvolnum>7</manvolnum></citerefentry> |
798d3a52 ZJS |
136 | for details on the available settings and their meanings. Use |
137 | <command>list-locales</command> for a list of available | |
138 | locales (see below). </para></listitem> | |
139 | </varlistentry> | |
140 | ||
141 | <varlistentry> | |
142 | <term><command>list-locales</command></term> | |
143 | ||
144 | <listitem><para>List available locales useful for | |
145 | configuration with | |
146 | <command>set-locale</command>.</para></listitem> | |
147 | </varlistentry> | |
148 | ||
149 | <varlistentry> | |
150 | <term><command>set-keymap MAP [TOGGLEMAP]</command></term> | |
151 | ||
152 | <listitem><para>Set the system keyboard mapping for the | |
153 | console and X11. This takes a mapping name (such as "de" or | |
154 | "us"), and possibly a second one to define a toggle keyboard | |
155 | mapping. Unless <option>--no-convert</option> is passed, the | |
156 | selected setting is also applied as the default system | |
157 | keyboard mapping of X11, after converting it to the closest | |
158 | matching X11 keyboard mapping. Use | |
159 | <command>list-keymaps</command> for a list of available | |
160 | keyboard mappings (see below).</para></listitem> | |
161 | </varlistentry> | |
162 | ||
163 | <varlistentry> | |
164 | <term><command>list-keymaps</command></term> | |
165 | ||
166 | <listitem><para>List available keyboard mappings for the | |
167 | console, useful for configuration with | |
168 | <command>set-keymap</command>.</para></listitem> | |
169 | </varlistentry> | |
170 | ||
171 | <varlistentry> | |
172 | <term><command>set-x11-keymap LAYOUT [MODEL [VARIANT [OPTIONS]]]</command></term> | |
173 | ||
174 | <listitem><para>Set the system default keyboard mapping for | |
175 | X11 and the virtual console. This takes a keyboard mapping | |
176 | name (such as <literal>de</literal> or <literal>us</literal>), | |
177 | and possibly a model, variant, and options, see | |
178 | <citerefentry><refentrytitle>kbd</refentrytitle><manvolnum>4</manvolnum></citerefentry> | |
179 | for details. Unless <option>--no-convert</option> is passed, | |
180 | the selected setting is also applied as the system console | |
181 | keyboard mapping, after converting it to the closest matching | |
182 | console keyboard mapping.</para></listitem> | |
183 | </varlistentry> | |
184 | ||
185 | <varlistentry> | |
186 | <term><command>list-x11-keymap-models</command></term> | |
187 | <term><command>list-x11-keymap-layouts</command></term> | |
188 | <term><command>list-x11-keymap-variants [LAYOUT]</command></term> | |
189 | <term><command>list-x11-keymap-options</command></term> | |
190 | ||
191 | <listitem><para>List available X11 keymap models, layouts, | |
192 | variants and options, useful for configuration with | |
193 | <command>set-keymap</command>. The command | |
194 | <command>list-x11-keymap-variants</command> optionally takes a | |
195 | layout parameter to limit the output to the variants suitable | |
196 | for the specific layout.</para></listitem> | |
197 | </varlistentry> | |
198 | </variablelist> | |
199 | ||
200 | </refsect1> | |
201 | ||
202 | <refsect1> | |
203 | <title>Exit status</title> | |
204 | ||
205 | <para>On success, 0 is returned, a non-zero failure code | |
206 | otherwise.</para> | |
207 | </refsect1> | |
208 | ||
209 | <xi:include href="less-variables.xml" /> | |
210 | ||
211 | <refsect1> | |
212 | <title>See Also</title> | |
213 | <para> | |
214 | <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>, | |
3ba3a79d ZJS |
215 | <citerefentry project='man-pages'><refentrytitle>locale</refentrytitle><manvolnum>7</manvolnum></citerefentry>, |
216 | <citerefentry project='man-pages'><refentrytitle>locale.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>, | |
798d3a52 | 217 | <citerefentry><refentrytitle>vconsole.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>, |
3ba3a79d | 218 | <citerefentry project='mankier'><refentrytitle>loadkeys</refentrytitle><manvolnum>1</manvolnum></citerefentry>, |
798d3a52 ZJS |
219 | <citerefentry><refentrytitle>kbd</refentrytitle><manvolnum>4</manvolnum></citerefentry>, |
220 | <ulink url="http://www.x.org/releases/current/doc/xorg-docs/input/XKB-Config.html"> | |
221 | The XKB Configuration Guide | |
222 | </ulink>, | |
223 | <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>, | |
224 | <citerefentry><refentrytitle>systemd-localed.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>, | |
dfc6109f | 225 | <citerefentry><refentrytitle>systemd-firstboot</refentrytitle><manvolnum>1</manvolnum></citerefentry>, |
0a07667d | 226 | <citerefentry project='die-net'><refentrytitle>mkinitrd</refentrytitle><manvolnum>8</manvolnum></citerefentry> |
798d3a52 ZJS |
227 | </para> |
228 | </refsect1> | |
7cd28a8a LP |
229 | |
230 | </refentry> |