chiark / gitweb /
9881e9819e29bc22b540abce5af3d5cb0bad9f22
[elogind.git] / man / systemd-install.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 systemd.
7
8   Copyright 2010 Lennart Poettering
9
10   systemd is free software; you can redistribute it and/or modify it
11   under the terms of the GNU General Public License as published by
12   the Free Software Foundation; either version 2 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   General Public License for more details.
19
20   You should have received a copy of the GNU General Public License
21   along with systemd; If not, see <http://www.gnu.org/licenses/>.
22 -->
23
24 <refentry id="systemd">
25
26         <refentryinfo>
27                 <title>systemd-install</title>
28                 <productname>systemd</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>systemd-install</refentrytitle>
42                 <manvolnum>1</manvolnum>
43         </refmeta>
44
45         <refnamediv>
46                 <refname>systemd-install</refname>
47                 <refpurpose>Enable or disable a systemd unit
48                 definition file</refpurpose>
49         </refnamediv>
50
51         <refsynopsisdiv>
52                 <cmdsynopsis>
53                         <command>systemd-install <arg choice="opt" rep="repeat">options</arg> <option>enable</option> <arg choice="opt" rep="repeat">name</arg></command>
54                 </cmdsynopsis>
55                 <cmdsynopsis>
56                         <command>systemd-install <arg choice="opt" rep="repeat">options</arg> <option>disable</option> <arg choice="opt" rep="repeat">name</arg></command>
57                 </cmdsynopsis>
58                 <cmdsynopsis>
59                         <command>systemd-install <arg choice="opt" rep="repeat">options</arg> <option>test</option> <arg choice="opt" rep="repeat">name</arg></command>
60                 </cmdsynopsis>
61         </refsynopsisdiv>
62
63         <refsect1>
64                 <title>Description</title>
65
66                 <para><command>systemd-install</command> enables or
67                 disables systemd units, or checks whether they are
68                 enabled.</para>
69
70                 <para>The following options are understood:</para>
71
72                 <variablelist>
73                         <varlistentry>
74                                 <term>--help</term>
75
76                                 <listitem><para>Prints a short help
77                                 text and exits.</para></listitem>
78                         </varlistentry>
79
80                         <varlistentry>
81                                 <term>--force</term>
82
83                                 <listitem><para>Enable/disable a
84                                 service even if it conflicts
85                                 with/contradicts another service. This
86                                 might have the effect of disabling
87                                 another service that was
88                                 enabled.</para></listitem>
89                         </varlistentry>
90
91                         <varlistentry>
92                                 <term>--system</term>
93
94                                 <listitem><para>Enable/disable a
95                                 system service.</para></listitem>
96                         </varlistentry>
97
98                         <varlistentry>
99                                 <term>--session</term>
100
101                                 <listitem><para>Enable/disable a
102                                 session service for the calling
103                                 user.</para></listitem>
104                         </varlistentry>
105
106                         <varlistentry>
107                                 <term>--global</term>
108
109                                 <listitem><para>Enable/disable a
110                                 session service for all
111                                 users.</para></listitem>
112                         </varlistentry>
113                 </variablelist>
114
115                 <para>The following verbs are understood:</para>
116
117                 <variablelist>
118                         <varlistentry>
119                                 <term>enable</term>
120
121                                 <listitem><para>Enable a unit. This
122                                 will create a number of symlinks as
123                                 encoded in the [Install] section of a
124                                 unit file.</para></listitem>
125                         </varlistentry>
126
127                         <varlistentry>
128                                 <term>disable</term>
129
130                                 <listitem><para>Disable a unit. This
131                                 will removed a number of symlinks as
132                                 encoded in the [Install] section of a
133                                 unit file.</para></listitem>
134                         </varlistentry>
135
136                         <varlistentry>
137                                 <term>test</term>
138
139                                 <listitem><para>Checks whether any of
140                                 the units specified are
141                                 installed. This will check for the
142                                 existance of a number of symlinks as
143                                 encoded in the [Install] section of a
144                                 unit file.</para></listitem>
145                         </varlistentry>
146                 </variablelist>
147
148         </refsect1>
149
150         <refsect1>
151                 <title>Exit status</title>
152
153                 <para>On success 0 is returned, a non-zero failure
154                 code otherwise.</para>
155         </refsect1>
156
157         <refsect1>
158                 <title>See Also</title>
159                 <para>
160                         <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
161                         <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>
162                 </para>
163         </refsect1>
164
165 </refentry>