chiark / gitweb /
doc: reword "shared per-thread" wording
[elogind.git] / man / systemd-tmpfiles.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 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
24 <refentry id="systemd-tmpfiles">
25
26         <refentryinfo>
27                 <title>systemd-tmpfiles</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-tmpfiles</refentrytitle>
42                 <manvolnum>8</manvolnum>
43         </refmeta>
44
45         <refnamediv>
46                 <refname>systemd-tmpfiles</refname>
47                 <refname>systemd-tmpfiles-setup.service</refname>
48                 <refname>systemd-tmpfiles-setup-dev.service</refname>
49                 <refname>systemd-tmpfiles-clean.service</refname>
50                 <refname>systemd-tmpfiles-clean.timer</refname>
51                 <refpurpose>Creates, deletes and cleans up volatile
52                 and temporary files and directories</refpurpose>
53         </refnamediv>
54
55         <refsynopsisdiv>
56                 <cmdsynopsis>
57                         <command>systemd-tmpfiles</command>
58                         <arg choice="opt" rep="repeat">OPTIONS</arg>
59                         <arg choice="opt" rep="repeat"><replaceable>CONFIGFILE</replaceable></arg>
60                 </cmdsynopsis>
61
62                 <para><filename>systemd-tmpfiles-setup.service</filename></para>
63                 <para><filename>systemd-tmpfiles-setup-dev.service</filename></para>
64                 <para><filename>systemd-tmpfiles-clean.service</filename></para>
65                 <para><filename>systemd-tmpfiles-clean.timer</filename></para>
66         </refsynopsisdiv>
67
68         <refsect1>
69                 <title>Description</title>
70
71                 <para><command>systemd-tmpfiles</command> creates,
72                 deletes, and cleans up volatile and temporary files and
73                 directories, based on the configuration file format and
74                 location specified in
75                 <citerefentry><refentrytitle>tmpfiles.d</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
76                 </para>
77
78                 <para>If invoked with no arguments, it applies all
79                 directives from all configuration files. If one or
80                 more filenames are passed on the command line, only
81                 the directives in these files are applied. If only
82                 the basename of a configuration file is specified,
83                 all configuration directories as specified in
84                 <citerefentry><refentrytitle>tmpfiles.d</refentrytitle><manvolnum>5</manvolnum></citerefentry>
85                 are searched for a matching file.</para>
86         </refsect1>
87
88         <refsect1>
89                 <title>Options</title>
90
91                 <para>The following options are understood:</para>
92
93                 <variablelist>
94                         <varlistentry>
95                                 <term><option>-h</option></term>
96                                 <term><option>--help</option></term>
97
98                                 <listitem><para>Prints a short help
99                                 text and exits.</para></listitem>
100                         </varlistentry>
101
102                         <varlistentry>
103                                 <term><option>--version</option></term>
104
105                                 <listitem><para>Prints a short version
106                                 string and exits.</para></listitem>
107                         </varlistentry>
108
109                         <varlistentry>
110                                 <term><option>--create</option></term>
111                                 <listitem><para>If this option is
112                                 passed, all files and directories
113                                 marked with <varname>f</varname>,
114                                 <varname>F</varname>,
115                                 <varname>w</varname>,
116                                 <varname>d</varname>,
117                                 <varname>D</varname>,
118                                 <varname>p</varname>,
119                                 <varname>L</varname>,
120                                 <varname>c</varname>,
121                                 <varname>b</varname>,
122                                 <varname>m</varname> in the
123                                 configuration files are created or
124                                 written to. Files and directories
125                                 marked with <varname>z</varname>,
126                                 <varname>Z</varname>,
127                                 <varname>m</varname> have their
128                                 ownership, access mode and security
129                                 labels set. </para></listitem>
130                         </varlistentry>
131
132                         <varlistentry>
133                                 <term><option>--clean</option></term>
134                                 <listitem><para>If this option is
135                                 passed, all files and directories with
136                                 an age parameter configured will be
137                                 cleaned up.</para></listitem>
138                         </varlistentry>
139
140                         <varlistentry>
141                                 <term><option>--remove</option></term>
142                                 <listitem><para>If this option is
143                                 passed, all files and directories
144                                 marked with <varname>r</varname>,
145                                 <varname>R</varname> in the
146                                 configuration files are
147                                 removed.</para></listitem>
148                         </varlistentry>
149                         <varlistentry>
150                                 <term><option>--boot</option></term>
151                                 <listitem><para>Also execute lines
152                                 with an exclamation mark.
153                                 </para></listitem>
154                         </varlistentry>
155                         <varlistentry>
156                                 <term><option>--prefix=PATH</option></term>
157                                 <listitem><para>Only apply rules that
158                                 apply to paths with the specified
159                                 prefix. This option can be specified
160                                 multiple times.</para></listitem>
161                         </varlistentry>
162                         <varlistentry>
163                                 <term><option>--exclude-prefix=PATH</option></term>
164                                 <listitem><para>Ignore rules that
165                                 apply to paths with the specified
166                                 prefix. This option can be specified
167                                 multiple times.</para></listitem>
168                         </varlistentry>
169                 </variablelist>
170
171                 <para>It is possible to combine
172                 <option>--create</option>, <option>--clean</option>,
173                 and <option>--remove</option> in one invocation. For
174                 example, during boot the following command line is
175                 executed to ensure that all temporary and volatile
176                 directories are removed and created according to the
177                 configuration file:</para>
178
179                 <programlisting>systemd-tmpfiles --remove --create</programlisting>
180
181         </refsect1>
182
183         <refsect1>
184                 <title>Exit status</title>
185
186                 <para>On success, 0 is returned, a non-zero failure
187                 code otherwise.</para>
188         </refsect1>
189
190         <refsect1>
191                 <title>See Also</title>
192                 <para>
193                         <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
194                         <citerefentry><refentrytitle>tmpfiles.d</refentrytitle><manvolnum>5</manvolnum></citerefentry>
195                 </para>
196         </refsect1>
197
198 </refentry>