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 <!-- SPDX-License-Identifier: LGPL-2.1+ -->
6 <refentry id=
"systemd-id128" xmlns:
xi=
"http://www.w3.org/2001/XInclude">
9 <title>systemd-id128
</title>
10 <productname>systemd
</productname>
14 <refentrytitle>systemd-id128
</refentrytitle>
15 <manvolnum>1</manvolnum>
19 <refname>systemd-id128
</refname>
20 <refpurpose>Generate and print sd-
128 identifiers
</refpurpose>
25 <command>systemd-id128
</command>
26 <arg choice=
"opt" rep=
"repeat">OPTIONS
</arg>
27 <arg choice=
"plain">new
</arg>
31 <command>systemd-id128
</command>
32 <arg choice=
"opt" rep=
"repeat">OPTIONS
</arg>
33 <arg choice=
"plain">machine-id
</arg>
37 <command>systemd-id128
</command>
38 <arg choice=
"opt" rep=
"repeat">OPTIONS
</arg>
39 <arg choice=
"plain">boot-id
</arg>
43 <command>systemd-id128
</command>
44 <arg choice=
"opt" rep=
"repeat">OPTIONS
</arg>
45 <arg choice=
"plain">invocation-id
</arg>
50 <title>Description
</title>
52 <para><command>id128
</command> may be used to conveniently print
53 <citerefentry><refentrytitle>sd-id128
</refentrytitle><manvolnum>3</manvolnum></citerefentry>
54 UUIDs. What identifier is printed depends on the specific verb.
</para>
56 <para>With
<command>new
</command>, a new random identifier will be generated.
</para>
58 <para>With
<command>machine-id
</command>, the identifier of the current machine will be
60 <citerefentry><refentrytitle>machine-id
</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
63 <para>With
<command>boot-id
</command>, the identifier of the current boot will be
66 <para>Both
<command>machine-id
</command> and
<command>boot-id
</command> may be combined
67 with the
<option>--app-specific=
<replaceable>app-id
</replaceable></option> switch to
68 generate application-specific IDs. See
69 <citerefentry><refentrytitle>sd_id128_get_machine
</refentrytitle><manvolnum>3</manvolnum></citerefentry>
70 for the discussion when this is useful.
</para>
72 <para>With
<command>invocation-id
</command>, the identifier of the current service invocation
73 will be printed. This is available in systemd services. See
74 <citerefentry><refentrytitle>systemd.exec
</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
79 <title>Options
</title>
81 <para>The following options are understood:
</para>
85 <term><option>-p
</option></term>
86 <term><option>--pretty
</option></term>
88 <listitem><para>Generate output as programming language snippets.
</para></listitem>
92 <term><option>-a
<replaceable>app-id
</replaceable></option></term>
93 <term><option>--app-specific=
<replaceable>app-id
</replaceable></option></term>
95 <listitem><para>With this option, an identifier that is the result of hashing the
96 application identifier
<replaceable>app-id
</replaceable> and the machine identifier will be
97 printed. The
<replaceable>app-id
</replaceable> argument must be a valid sd-id128 string
98 identifying the application.
</para>
102 <xi:include href=
"standard-options.xml" xpointer=
"help" />
103 <xi:include href=
"standard-options.xml" xpointer=
"version" />
108 <title>Exit status
</title>
110 <para>On success,
0 is returned, a non-zero failure code otherwise.
</para>
114 <title>See Also
</title>
116 <citerefentry><refentrytitle>systemd
</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
117 <citerefentry><refentrytitle>sd-id128
</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
118 <citerefentry><refentrytitle>sd_id128_get_machine
</refentrytitle><manvolnum>3</manvolnum></citerefentry>