]> git.ipfire.org Git - thirdparty/systemd.git/blame - man/systemd.scope.xml
verify: use manager_load_startable_unit_or_warn() to load units for verification
[thirdparty/systemd.git] / man / systemd.scope.xml
CommitLineData
3802a3d3 1<?xml version='1.0'?> <!--*- Mode: nxml; nxml-child-indent: 2; indent-tabs-mode: nil -*-->
d868475a 2<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
12b42c76 3"http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
d868475a
ZJS
4
5<!--
572eb058
ZJS
6 SPDX-License-Identifier: LGPL-2.1+
7
5de0ccff 8 This file is part of systemd.
d868475a 9
5de0ccff 10 Copyright 2013 Zbigniew Jędrzejewski-Szmek
d868475a 11
5de0ccff
ZJS
12 systemd is free software; you can redistribute it and/or modify it
13 under the terms of the GNU Lesser General Public License as published by
14 the Free Software Foundation; either version 2.1 of the License, or
15 (at your option) any later version.
d868475a 16
5de0ccff
ZJS
17 systemd is distributed in the hope that it will be useful, but
18 WITHOUT ANY WARRANTY; without even the implied warranty of
19 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20 Lesser General Public License for more details.
d868475a 21
5de0ccff
ZJS
22 You should have received a copy of the GNU Lesser General Public License
23 along with systemd; If not, see <http://www.gnu.org/licenses/>.
d868475a
ZJS
24-->
25
26<refentry id="systemd.scope">
27 <refentryinfo>
28 <title>systemd.scope</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>systemd.scope</refentrytitle>
43 <manvolnum>5</manvolnum>
44 </refmeta>
45
46 <refnamediv>
47 <refname>systemd.scope</refname>
48 <refpurpose>Scope unit configuration</refpurpose>
49 </refnamediv>
50
51 <refsynopsisdiv>
52 <para><filename><replaceable>scope</replaceable>.scope</filename></para>
53 </refsynopsisdiv>
54
55 <refsect1>
56 <title>Description</title>
57
9365b048
LP
58 <para>Scope units are not configured via unit configuration files,
59 but are only created programmatically using the bus interfaces of
60 systemd. They are named similar to filenames. A unit whose name
61 ends in <literal>.scope</literal> refers to a scope unit. Scopes
fbce1139 62 units manage a set of system processes. Unlike service units, scope
9365b048
LP
63 units manage externally created processes, and do not fork off
64 processes on its own.</para>
d868475a 65
9365b048 66 <para>The main purpose of scope units is grouping worker processes
847ae0ae 67 of a system service for organization and for managing resources.</para>
9365b048
LP
68
69 <para><command>systemd-run <option>--scope</option></command> may
70 be used to easily launch a command in a new scope unit from the
71 command line.</para>
d868475a 72
ea021cc3 73 <para>See the <ulink
28a0ad81 74 url="https://www.freedesktop.org/wiki/Software/systemd/ControlGroupInterface/">New
72f4d966 75 Control Group Interfaces</ulink> for an introduction on how to make
ea021cc3 76 use of scope units from programs.</para>
c129bd5d
LP
77 </refsect1>
78
79 <refsect1>
45f09f93 80 <title>Implicit Dependencies</title>
c129bd5d 81
45f09f93 82 <para>Implicit dependencies may be added as result of
c129bd5d
LP
83 resource control parameters as documented in
84 <citerefentry><refentrytitle>systemd.resource-control</refentrytitle><manvolnum>5</manvolnum></citerefentry>.</para>
45f09f93 85 </refsect1>
c129bd5d 86
45f09f93
JL
87 <refsect1>
88 <title>Default Dependencies</title>
89
90 <para>The following dependencies are added unless
91 <varname>DefaultDependencies=no</varname> is set:</para>
92
93 <itemizedlist>
94 <listitem><para>Scope units will automatically have dependencies of
95 type <varname>Conflicts=</varname> and
96 <varname>Before=</varname> on
97 <filename>shutdown.target</filename>. These ensure
98 that scope units are removed prior to system
99 shutdown. Only scope units involved with early boot or
100 late system shutdown should disable
101 <varname>DefaultDependencies=</varname> option.</para></listitem>
102 </itemizedlist>
d868475a
ZJS
103 </refsect1>
104
105 <refsect1>
106 <title>See Also</title>
107 <para>
108 <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
109 <citerefentry><refentrytitle>systemd-run</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
110 <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
3fde5f30 111 <citerefentry><refentrytitle>systemd.resource-control</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
d868475a
ZJS
112 <citerefentry><refentrytitle>systemd.service</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
113 <citerefentry><refentrytitle>systemd.directives</refentrytitle><manvolnum>7</manvolnum></citerefentry>.
114 </para>
115 </refsect1>
116
117</refentry>