chiark / gitweb /
systemd-fsck: always connect to systemd-fsckd
[elogind.git] / man / systemd-machine-id-setup.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 2012 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-machine-id-setup"
25     xmlns:xi="http://www.w3.org/2001/XInclude">
26
27   <refentryinfo>
28     <title>systemd-machine-id-setup</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-machine-id-setup</refentrytitle>
43     <manvolnum>1</manvolnum>
44   </refmeta>
45
46   <refnamediv>
47     <refname>systemd-machine-id-setup</refname>
48     <refpurpose>Initialize the machine ID in /etc/machine-id</refpurpose>
49   </refnamediv>
50
51   <refsynopsisdiv>
52     <cmdsynopsis>
53       <command>systemd-machine-id-setup</command>
54     </cmdsynopsis>
55   </refsynopsisdiv>
56
57   <refsect1>
58     <title>Description</title>
59
60     <para><command>systemd-machine-id-setup</command> may be used by
61     system installer tools to initialize the machine ID stored in
62     <filename>/etc/machine-id</filename> at install time with a
63     randomly generated ID. See
64     <citerefentry><refentrytitle>machine-id</refentrytitle><manvolnum>5</manvolnum></citerefentry>
65     for more information about this file.</para>
66
67     <para>This tool will execute no operation if
68     <filename>/etc/machine-id</filename> is already
69     initialized.</para>
70
71     <para>If a valid D-Bus machine ID is already configured for the
72     system, the D-Bus machine ID is copied and used to initialize the
73     machine ID in <filename>/etc/machine-id</filename>.</para>
74
75     <para>If run inside a KVM virtual machine and a UUID is passed via
76     the <option>-uuid</option> option, this UUID is used to initialize
77     the machine ID instead of a randomly generated one. The caller
78     must ensure that the UUID passed is sufficiently unique and is
79     different for every booted instanced of the VM.</para>
80
81     <para>Similar, if run inside a Linux container environment and a
82     UUID is set for the container this is used to initialize the
83     machine ID. For details see the documentation of the <ulink
84     url="http://www.freedesktop.org/wiki/Software/systemd/ContainerInterface">Container
85     Interface</ulink>.</para>
86
87     <para>Use
88     <citerefentry><refentrytitle>systemd-firstboot</refentrytitle><manvolnum>1</manvolnum></citerefentry>
89     to initialize the machine ID on mounted (but not booted) system
90     images.</para>
91
92   </refsect1>
93
94   <refsect1>
95     <title>Options</title>
96
97     <para>The following options are understood:</para>
98
99     <variablelist>
100       <varlistentry>
101         <term><option>--root=<replaceable>root</replaceable></option></term>
102         <listitem><para>Takes a directory path as an argument. All
103         paths will be prefixed with the given alternate
104         <replaceable>root</replaceable> path, including config search
105         paths. </para></listitem>
106       </varlistentry>
107       <xi:include href="standard-options.xml" xpointer="help" />
108       <xi:include href="standard-options.xml" xpointer="version" />
109     </variablelist>
110
111   </refsect1>
112
113   <refsect1>
114     <title>Exit status</title>
115
116     <para>On success, 0 is returned, a non-zero failure code
117     otherwise.</para>
118   </refsect1>
119
120   <refsect1>
121     <title>See Also</title>
122     <para>
123       <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
124       <citerefentry><refentrytitle>machine-id</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
125       <citerefentry><refentrytitle>dbus-uuidgen</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
126       <citerefentry><refentrytitle>systemd-firstboot</refentrytitle><manvolnum>1</manvolnum></citerefentry>
127     </para>
128   </refsect1>
129
130 </refentry>