chiark / gitweb /
include <poll.h> instead of <sys/poll.h>
[elogind.git] / man / systemd-update-done.service.xml
1 <?xml version="1.0"?>
2 <!--*-nxml-*-->
3 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
4 <!--
5   This file is part of systemd.
6
7   Copyright 2014 Lennart Poettering
8
9   systemd is free software; you can redistribute it and/or modify it
10   under the terms of the GNU Lesser General Public License as published by
11   the Free Software Foundation; either version 2.1 of the License, or
12   (at your option) any later version.
13
14   systemd is distributed in the hope that it will be useful, but
15   WITHOUT ANY WARRANTY; without even the implied warranty of
16   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17   Lesser General Public License for more details.
18
19   You should have received a copy of the GNU Lesser General Public License
20   along with systemd; If not, see <http://www.gnu.org/licenses/>.
21 -->
22 <refentry id="systemd-update-done.service">
23
24   <refentryinfo>
25     <title>systemd-update-done.service</title>
26     <productname>systemd</productname>
27
28     <authorgroup>
29       <author>
30         <contrib>Developer</contrib>
31         <firstname>Lennart</firstname>
32         <surname>Poettering</surname>
33         <email>lennart@poettering.net</email>
34       </author>
35     </authorgroup>
36   </refentryinfo>
37
38   <refmeta>
39     <refentrytitle>systemd-update-done.service</refentrytitle>
40     <manvolnum>8</manvolnum>
41   </refmeta>
42
43   <refnamediv>
44     <refname>systemd-update-done.service</refname>
45     <refname>systemd-update-done</refname>
46     <refpurpose>Mark <filename>/etc</filename> and <filename>/var</filename> fully updated</refpurpose>
47   </refnamediv>
48
49   <refsynopsisdiv>
50     <para><filename>systemd-update-done.service</filename></para>
51     <para><filename>/usr/lib/systemd/systemd-update-done</filename></para>
52   </refsynopsisdiv>
53
54   <refsect1>
55     <title>Description</title>
56
57     <para><filename>systemd-update-done.service</filename> is a
58     service that is invoked as part of the first boot after the vendor
59     operating system resources in <filename>/usr</filename> have been
60     updated. This is useful to implement offline updates of
61     <filename>/usr</filename> which might requires updates to
62     <filename>/etc</filename> or <filename>/var</filename> on the
63     following boot.</para>
64
65     <para><filename>systemd-update-done.service</filename> updates the
66     file modification time (mtime) of the stamp files
67     <filename>/etc/.updated</filename> and
68     <filename>/var/.updated</filename> to the modification time of the
69     <filename>/usr</filename> directory, unless the stamp files are
70     already newer.</para>
71
72     <para>Services that shall run after offline upgrades of
73     <filename>/usr</filename> should order themselves before
74     <filename>systemd-update-done.service</filename>, and use the
75     <varname>ConditionNeedsUpdate=</varname> (see
76     <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>)
77     condition to make sure to run when <filename>/etc</filename> or
78     <filename>/var</filename> are older than <filename>/usr</filename>
79     according to the modification times of the files described above.
80     This requires that updates to <filename>/usr</filename> are always
81     followed by an update of the modification time of
82     <filename>/usr</filename>, for example by invoking
83     <citerefentry project='man-pages'><refentrytitle>touch</refentrytitle><manvolnum>1</manvolnum></citerefentry>
84     on it.</para>
85
86   </refsect1>
87
88   <refsect1>
89     <title>See Also</title>
90     <para>
91       <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
92       <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
93       <citerefentry project='man-pages'><refentrytitle>touch</refentrytitle><manvolnum>1</manvolnum></citerefentry>
94     </para>
95   </refsect1>
96
97 </refentry>