chiark / gitweb /
logind: change TasksMax= value for user logins to 33%
[elogind.git] / man / loginctl.xml
1 <?xml version='1.0'?> <!--*-nxml-*-->
2 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
3   "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
4
5 <!--
6   This file is part of elogind.
7
8   Copyright 2010 Lennart Poettering
9
10   elogind 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   elogind 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 elogind; If not, see <http://www.gnu.org/licenses/>.
22 -->
23
24 <refentry id="loginctl" xmlns:xi="http://www.w3.org/2001/XInclude">
25
26   <refentryinfo>
27     <title>loginctl</title>
28     <productname>elogind</productname>
29
30     <authorgroup>
31       <author>
32         <contrib>Developer</contrib>
33         <firstname>Lennart</firstname>
34         <surname>Poettering</surname>
35         <email>lennart@poettering.net</email>
36       </author>
37     </authorgroup>
38   </refentryinfo>
39
40   <refmeta>
41     <refentrytitle>loginctl</refentrytitle>
42     <manvolnum>1</manvolnum>
43   </refmeta>
44
45   <refnamediv>
46     <refname>loginctl</refname>
47     <refpurpose>Control the elogind login manager</refpurpose>
48   </refnamediv>
49
50   <refsynopsisdiv>
51     <cmdsynopsis>
52       <command>loginctl</command>
53       <arg choice="opt" rep="repeat">OPTIONS</arg>
54       <arg choice="req">COMMAND</arg>
55       <arg choice="opt" rep="repeat">NAME</arg>
56     </cmdsynopsis>
57   </refsynopsisdiv>
58
59   <refsect1>
60     <title>Description</title>
61
62     <para><command>loginctl</command> may be used to introspect and
63     control the state of the
64     <citerefentry><refentrytitle>elogind</refentrytitle><manvolnum>8</manvolnum></citerefentry>
65     login manager.</para>
66   </refsect1>
67
68   <refsect1>
69     <title>Options</title>
70
71     <para>The following options are understood:</para>
72
73     <variablelist>
74       <varlistentry>
75         <term><option>--no-ask-password</option></term>
76
77         <listitem><para>Do not query the user for authentication for
78         privileged operations.</para></listitem>
79       </varlistentry>
80
81       <varlistentry>
82         <term><option>-p</option></term>
83         <term><option>--property=</option></term>
84
85         <listitem><para>When showing session/user/seat properties,
86         limit display to certain properties as specified as argument.
87         If not specified, all set properties are shown. The argument
88         should be a property name, such as
89         <literal>Sessions</literal>. If specified more than once, all
90         properties with the specified names are
91         shown.</para></listitem>
92       </varlistentry>
93
94       <varlistentry>
95         <term><option>--value</option></term>
96
97         <listitem>
98           <para>When printing properties with <command>show</command>,
99           only print the value, and skip the property name and
100           <literal>=</literal>.</para>
101         </listitem>
102       </varlistentry>
103
104       <varlistentry>
105         <term><option>-a</option></term>
106         <term><option>--all</option></term>
107
108         <listitem><para>When showing session/user/seat properties,
109         show all properties regardless of whether they are set or
110         not.</para></listitem>
111       </varlistentry>
112
113       <varlistentry>
114         <term><option>-l</option></term>
115         <term><option>--full</option></term>
116
117         <listitem><para>Do not ellipsize process tree entries.</para>
118         </listitem>
119       </varlistentry>
120
121       <varlistentry>
122         <term><option>--kill-who=</option></term>
123
124         <listitem><para>When used with
125         <command>kill-session</command>, choose which processes to
126         kill. Must be one of <option>leader</option>, or
127         <option>all</option> to select whether to kill only the leader
128         process of the session or all processes of the session. If
129         omitted, defaults to <option>all</option>.</para></listitem>
130       </varlistentry>
131
132       <varlistentry>
133         <term><option>-s</option></term>
134         <term><option>--signal=</option></term>
135
136         <listitem><para>When used with <command>kill-session</command>
137         or <command>kill-user</command>, choose which signal to send
138         to selected processes. Must be one of the well known signal
139         specifiers, such as <constant>SIGTERM</constant>,
140         <constant>SIGINT</constant> or <constant>SIGSTOP</constant>.
141         If omitted, defaults to
142         <constant>SIGTERM</constant>.</para></listitem>
143       </varlistentry>
144
145       <xi:include href="user-system-options.xml" xpointer="host" />
146       <xi:include href="user-system-options.xml" xpointer="machine" />
147
148       <xi:include href="standard-options.xml" xpointer="no-pager" />
149       <xi:include href="standard-options.xml" xpointer="no-legend" />
150       <xi:include href="standard-options.xml" xpointer="help" />
151       <xi:include href="standard-options.xml" xpointer="version" />
152     </variablelist>
153   </refsect1>
154
155   <refsect1>
156     <title>Commands</title>
157
158     <para>The following commands are understood:</para>
159
160     <refsect2><title>Session Commands</title><variablelist>
161
162       <varlistentry>
163         <term><command>list-sessions</command></term>
164
165         <listitem><para>List current sessions.</para></listitem>
166       </varlistentry>
167
168       <varlistentry>
169         <term><command>session-status</command> <optional><replaceable>ID</replaceable>...</optional></term>
170
171         <listitem><para>Show terse runtime status information about
172         one or more sessions. Takes one or more session identifiers as
173         parameters. If no session identifiers are passed the status of
174         the caller's session is shown. This function is intended to
175         generate human-readable output. If you are looking for
176         computer-parsable output, use <command>show-session</command>
177         instead.</para></listitem>
178       </varlistentry>
179
180       <varlistentry>
181         <term><command>show-session</command> <optional><replaceable>ID</replaceable>...</optional></term>
182
183         <listitem><para>Show properties of one or more sessions or the
184         manager itself. If no argument is specified, properties of the
185         manager will be shown. If a session ID is specified,
186         properties of the session are shown. By default, empty
187         properties are suppressed. Use <option>--all</option> to show
188         those too. To select specific properties to show, use
189         <option>--property=</option>. This command is intended to be
190         used whenever computer-parsable output is required. Use
191         <command>session-status</command> if you are looking for
192         formatted human-readable output.</para></listitem>
193       </varlistentry>
194
195       <varlistentry>
196         <term><command>activate</command> <optional><replaceable>ID</replaceable></optional></term>
197
198         <listitem><para>Activate a session. This brings a session into
199         the foreground, if another session is currently in the
200         foreground on the respective seat. Takes a session identifier
201         as argument. If no argument is specified the session of the
202         caller is put into foreground.</para></listitem>
203       </varlistentry>
204
205       <varlistentry>
206         <term><command>lock-session</command> <optional><replaceable>ID</replaceable>...</optional></term>
207         <term><command>unlock-session</command> <optional><replaceable>ID</replaceable>...</optional></term>
208
209         <listitem><para>Activates/deactivates the screen lock on one
210         or more sessions, if the session supports it. Takes one or
211         more session identifiers as arguments. If no argument is
212         specified the session of the caller is locked/unlocked.
213         </para></listitem>
214       </varlistentry>
215
216       <varlistentry>
217         <term><command>lock-sessions</command></term>
218         <term><command>unlock-sessions</command></term>
219
220         <listitem><para>Activates/deactivates the screen lock on all
221         current sessions supporting it. </para></listitem>
222       </varlistentry>
223
224       <varlistentry>
225         <term><command>terminate-session</command> <replaceable>ID</replaceable>...</term>
226
227         <listitem><para>Terminates a session. This kills all processes
228         of the session and deallocates all resources attached to the
229         session. </para></listitem>
230       </varlistentry>
231
232       <varlistentry>
233         <term><command>kill-session</command> <replaceable>ID</replaceable>...</term>
234
235         <listitem><para>Send a signal to one or more processes of the
236         session. Use <option>--kill-who=</option> to select which
237         process to kill. Use <option>--signal=</option> to select the
238         signal to send.</para></listitem>
239       </varlistentry>
240     </variablelist></refsect2>
241
242     <refsect2><title>User Commands</title><variablelist>
243       <varlistentry>
244         <term><command>list-users</command></term>
245
246         <listitem><para>List currently logged in users.
247         </para></listitem>
248       </varlistentry>
249
250       <varlistentry>
251         <term><command>user-status</command> <optional><replaceable>USER</replaceable>...</optional></term>
252
253         <listitem><para>Show terse runtime status information about
254         one or more logged in users. Takes one or more user names or numeric
255         user IDs as parameters. If no parameters are passed the status
256         of the caller's user is shown. This function is intended to
257         generate human-readable output. If you are looking for
258         computer-parsable output, use <command>show-user</command>
259         instead. Users may be specified by their usernames or numeric
260         user IDs. </para></listitem>
261       </varlistentry>
262
263       <varlistentry>
264         <term><command>show-user</command> <optional><replaceable>USER</replaceable>...</optional></term>
265
266         <listitem><para>Show properties of one or more users or the
267         manager itself. If no argument is specified, properties of the
268         manager will be shown. If a user is specified, properties of
269         the user are shown. By default, empty properties are
270         suppressed. Use <option>--all</option> to show those too. To
271         select specific properties to show, use
272         <option>--property=</option>. This command is intended to be
273         used whenever computer-parsable output is required. Use
274         <command>user-status</command> if you are looking for
275         formatted human-readable output.</para></listitem>
276       </varlistentry>
277
278       <varlistentry>
279         <term><command>enable-linger</command> <optional><replaceable>USER</replaceable>...</optional></term>
280         <term><command>disable-linger</command> <optional><replaceable>USER</replaceable>...</optional></term>
281
282         <listitem><para>Enable/disable user lingering for one or more
283         users. If enabled for a specific user, a user manager is
284         spawned for the user at boot and kept around after logouts.
285         This allows users who are not logged in to run long-running
286         services. Takes one or more user names or numeric UIDs as
287         argument. If no argument is specified enables/disables
288         lingering for the user of the session of the caller.
289         </para></listitem>
290       </varlistentry>
291
292       <varlistentry>
293         <term><command>terminate-user</command> <replaceable>USER</replaceable>...</term>
294
295         <listitem><para>Terminates all sessions of a user. This kills
296         all processes of all sessions of the user and deallocates all
297         runtime resources attached to the user.</para></listitem>
298       </varlistentry>
299
300       <varlistentry>
301         <term><command>kill-user</command> <replaceable>USER</replaceable>...</term>
302
303         <listitem><para>Send a signal to all processes of a user. Use
304         <option>--signal=</option> to select the signal to send.
305         </para></listitem>
306       </varlistentry>
307     </variablelist></refsect2>
308
309     <refsect2><title>Seat Commands</title><variablelist>
310       <varlistentry>
311         <term><command>list-seats</command></term>
312
313         <listitem><para>List currently available seats on the local
314         system.</para></listitem>
315       </varlistentry>
316
317       <varlistentry>
318         <term><command>seat-status</command> <optional><replaceable>NAME</replaceable>...</optional></term>
319
320         <listitem><para>Show terse runtime status information about
321         one or more seats. Takes one or more seat names as parameters.
322         If no seat names are passed the status of the caller's
323         session's seat is shown. This function is intended to generate
324         human-readable output. If you are looking for
325         computer-parsable output, use <command>show-seat</command>
326         instead.</para></listitem>
327       </varlistentry>
328
329       <varlistentry>
330         <term><command>show-seat</command> <optional><replaceable>NAME</replaceable>...</optional></term>
331
332         <listitem><para>Show properties of one or more seats or the
333         manager itself. If no argument is specified, properties of the
334         manager will be shown. If a seat is specified, properties of
335         the seat are shown. By default, empty properties are
336         suppressed. Use <option>--all</option> to show those too. To
337         select specific properties to show, use
338         <option>--property=</option>. This command is intended to be
339         used whenever computer-parsable output is required. Use
340         <command>seat-status</command> if you are looking for
341         formatted human-readable output.</para></listitem>
342       </varlistentry>
343
344       <varlistentry>
345         <term><command>attach</command> <replaceable>NAME</replaceable> <replaceable>DEVICE</replaceable>...</term>
346
347         <listitem><para>Persistently attach one or more devices to a
348         seat. The devices should be specified via device paths in the
349         <filename>/sys</filename> file system. To create a new seat,
350         attach at least one graphics card to a previously unused seat
351         name. Seat names may consist only of a-z, A-Z, 0-9,
352         <literal>-</literal> and <literal>_</literal> and must be
353         prefixed with <literal>seat</literal>. To drop assignment of a
354         device to a specific seat, just reassign it to a different
355         seat, or use <command>flush-devices</command>.
356         </para></listitem>
357       </varlistentry>
358
359       <varlistentry>
360         <term><command>flush-devices</command></term>
361
362         <listitem><para>Removes all device assignments previously
363         created with <command>attach</command>. After this call, only
364         automatically generated seats will remain, and all seat
365         hardware is assigned to them.</para></listitem>
366       </varlistentry>
367
368       <varlistentry>
369         <term><command>terminate-seat</command> <replaceable>NAME</replaceable>...</term>
370
371         <listitem><para>Terminates all sessions on a seat. This kills
372         all processes of all sessions on the seat and deallocates all
373         runtime resources attached to them.</para></listitem>
374       </varlistentry>
375     </variablelist></refsect2>
376
377     <refsect2><title>System Commands</title><variablelist>
378     </variablelist></refsect2>
379     <varlistentry>
380       <term><command>poweroff</command></term>
381
382       <listitem>
383         <para>Print a wall message to all users, shut down and
384           power-off the system.</para>
385       </listitem>
386     </varlistentry>
387     <varlistentry>
388       <term><command>reboot <optional><replaceable>arg</replaceable></optional></command></term>
389
390       <listitem>
391         <para>Print a wall message to all users, shut down and
392           reboot the system.</para>
393
394         <para>If the optional argument
395         <replaceable>arg</replaceable> is given, it will be passed
396         as the optional argument to the
397         <citerefentry><refentrytitle>reboot</refentrytitle><manvolnum>2</manvolnum></citerefentry>
398         system call. The value is architecture and firmware
399         specific. As an example, <literal>recovery</literal> might
400         be used to trigger system recovery, and
401         <literal>fota</literal> might be used to trigger a
402         <quote>firmware over the air</quote> update.</para>
403       </listitem>
404     </varlistentry>
405
406     <varlistentry>
407       <term><command>suspend</command></term>
408
409       <listitem>
410         <para>Suspend the system.
411         </para>
412       </listitem>
413     </varlistentry>
414
415     <varlistentry>
416       <term><command>hibernate</command></term>
417
418       <listitem>
419         <para>Hibernate the system.
420         </para>
421       </listitem>
422     </varlistentry>
423
424     <varlistentry>
425       <term><command>hybrid-sleep</command></term>
426
427       <listitem>
428         <para>Hibernate and suspend the system.</para>
429       </listitem>
430     </varlistentry>
431   </refsect1>
432   <refsect1>
433     <title>Exit status</title>
434
435     <para>On success, 0 is returned, a non-zero failure code
436     otherwise.</para>
437   </refsect1>
438
439   <xi:include href="less-variables.xml" />
440
441   <refsect1>
442     <title>See Also</title>
443     <para>
444       <citerefentry><refentrytitle>elogind</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
445       <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
446       <citerefentry><refentrytitle>logind.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>
447     </para>
448   </refsect1>
449
450 </refentry>