PATH=/opt/foo/bin:$PATH
LD_LIBRARY_PATH=/opt/foo/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}
XDG_DATA_DIRS=/opt/foo/share:${XDG_DATA_DIRS:-/usr/local/share/:/usr/share/}
- </programlisting>
+</programlisting>
</example>
</refsect2>
</refsect1>
#include <systemd/sd-messages.h>
#include <systemd/sd-path.h>
#include <systemd/sd-varlink.h>
- </programlisting>
+</programlisting>
<cmdsynopsis>
<command>pkg-config --cflags --libs libsystemd</command>
sbvarsign --attr "${attr}" --key PK.key --cert PK.pem --output PK.auth PK PK.esl
sbvarsign --attr "${attr}" --key PK.key --cert PK.pem --output KEK.auth KEK KEK.esl
sbvarsign --attr "${attr}" --key KEK.key --cert KEK.pem --output db.auth db db.esl
- </programlisting>
+</programlisting>
<para>This feature is considered dangerous because even if all the required files are signed with the
keys being loaded, some files necessary for the system to function properly still won't be. This
timeout 0
default 01234567890abcdef1234567890abdf0-*
editor no
- </programlisting>
+</programlisting>
<para>The menu will not be shown by default (the menu can still be shown by
pressing and holding a key during boot). One of the entries with files with a
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
can be used to further customize the behavior of this method via flags defined as follows:</para>
<programlisting>
#define SD_HOMED_UPDATE_OFFLINE (UINT64_C(1) << 0)
- </programlisting>
+</programlisting>
<para>When <constant>SD_HOMED_UPDATE_OFFLINE</constant> (0x01) is set, no attempt is made to update the copies
of the user record and blob directory that are embedded into the home directory. Changes will be stored, however,
and may be propagated into the home directory the next time it is reconciled (most likely when the user next logs in).
interface org.freedesktop.DBus.Properties { ... };
interface org.freedesktop.DBus.ObjectManager { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
<programlisting>$ gdbus introspect --system \
--dest org.freedesktop.hostname1 \
--object-path /org/freedesktop/hostname1
- </programlisting>
+</programlisting>
</example>
</refsect1>
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
<programlisting>$ gdbus introspect --system \
--dest org.freedesktop.import1 \
--object-path /org/freedesktop/import1
- </programlisting>
+</programlisting>
</example>
<example>
<programlisting>$ gdbus introspect --system \
--dest org.freedesktop.import1 \
--object-path /org/freedesktop/import1/transfer/_1
- </programlisting>
+</programlisting>
</example>
</refsect1>
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
$ gdbus introspect --system \
--dest org.freedesktop.locale1 \
--object-path /org/freedesktop/locale1
- </programlisting>
+</programlisting>
</example>
</refsect1>
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--property SleepOperation is not documented!-->
#define SD_LOGIND_SOFT_REBOOT (UINT64_C(1) << 2)
#define SD_LOGIND_SOFT_REBOOT_IF_NEXTROOT_SET_UP (UINT64_C(1) << 3)
#define SD_LOGIND_SKIP_INHIBITORS (UINT64_C(1) << 4)
- </programlisting>
+</programlisting>
<para>When the <varname>flags</varname> is 0 then these methods behave just like the versions without
flags. Since systemd version 257 active inhibitors are honoured by default for privileged users too.
<constant>SD_LOGIND_ROOT_CHECK_INHIBITORS</constant> (0x01) now only applies to weak inhibitors, to
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
<programlisting>$ gdbus introspect --system --dest org.freedesktop.login1 \
--object-path /org/freedesktop/login1
- </programlisting>
+</programlisting>
<para>or</para>
<programlisting>$ busctl introspect org.freedesktop.login1 /org/freedesktop/login1
- </programlisting>
+</programlisting>
</example>
<example>
<programlisting>$ gdbus introspect --system --dest org.freedesktop.login1 \
--object-path /org/freedesktop/login1/seat/seat0
- </programlisting>
+</programlisting>
<para>or</para>
<programlisting>$ busctl introspect org.freedesktop.login1 /org/freedesktop/login1/seat/seat0
- </programlisting>
+</programlisting>
<para>Seat <literal>seat0</literal> is the default seat, so it'll be present unless local configuration
is made to reassign all devices to a different seat. The list of seats and users can be acquired with
<programlisting>$ gdbus introspect --system --dest org.freedesktop.login1 \
--object-path /org/freedesktop/login1/user/_1000
- </programlisting>
+</programlisting>
<para>or</para>
<programlisting>$ busctl introspect org.freedesktop.login1 /org/freedesktop/login1/user/_1000
- </programlisting>
+</programlisting>
</example>
<example>
<programlisting>$ gdbus introspect --system --dest org.freedesktop.login1 \
--object-path /org/freedesktop/login1/session/45
- </programlisting>
+</programlisting>
<para>or</para>
<programlisting>$ busctl introspect org.freedesktop.login1 /org/freedesktop/login1/session/45
- </programlisting>
+</programlisting>
</example>
</refsect1>
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--method UnregisterMachine is not documented!-->
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--method GetUIDShift is not documented!-->
$ gdbus introspect --system \
--dest org.freedesktop.machine1 \
--object-path /org/freedesktop/machine1
- </programlisting>
+</programlisting>
</example>
<example>
$ gdbus introspect --system \
--dest org.freedesktop.machine1 \
--object-path /org/freedesktop/machine1/machine/rawhide
- </programlisting>
+</programlisting>
</example>
</refsect1>
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--method ListLinks is not documented!-->
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--method SetNTP is not documented!-->
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--property Description is not documented!-->
interface org.freedesktop.DBus.Properties { ... };
interface org.freedesktop.network1.Link { ... };
};
- </programlisting>
+</programlisting>
<!--property Leases is not documented!-->
interface org.freedesktop.DBus.Properties { ... };
interface org.freedesktop.network1.Link { ... };
};
- </programlisting>
+</programlisting>
<!--property State is not documented!-->
interface org.freedesktop.DBus.Properties { ... };
interface org.freedesktop.network1.Link { ... };
};
- </programlisting>
+</programlisting>
<!--property State is not documented!-->
$ gdbus introspect --system \
--dest org.freedesktop.network1 \
--object-path /org/freedesktop/network1
- </programlisting>
+</programlisting>
</example>
<example>
$ gdbus introspect --system \
--dest org.freedesktop.network1 \
--object-path /org/freedesktop/network1/link/_11
- </programlisting>
+</programlisting>
</example>
</refsect1>
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--method DumpByFileDescriptor is not documented!-->
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
#define SD_SYSTEMD_PORTABLE_RUNTIME (UINT64_C(1) << 0)
#define SD_SYSTEMD_PORTABLE_FORCE_ATTACH (UINT64_C(1) << 1)
#define SD_SYSTEMD_PORTABLE_FORCE_EXTENSION (UINT64_C(1) << 2)
- </programlisting>
+</programlisting>
</refsect2>
<refsect2>
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--method GetOSRelease is not documented!-->
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
$ gdbus introspect --system \
--dest org.freedesktop.resolve1 \
--object-path /org/freedesktop/resolve1
- </programlisting>
+</programlisting>
</example>
<example>
$ gdbus introspect --system \
--dest org.freedesktop.resolve1 \
--object-path /org/freedesktop/resolve1/link/_11
- </programlisting>
+</programlisting>
</example>
</refsect1>
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--method GetUnitByInvocationID is not documented!-->
#define SD_SYSTEMD_UNIT_RUNTIME (UINT64_C(1) << 0)
#define SD_SYSTEMD_UNIT_FORCE (UINT64_C(1) << 1)
#define SD_SYSTEMD_UNIT_PORTABLE (UINT64_C(1) << 2)
- </programlisting>
+</programlisting>
<para><varname>SD_SYSTEMD_UNIT_RUNTIME</varname> will enable or disable the unit for runtime only,
<varname>SD_SYSTEMD_UNIT_FORCE</varname> controls whether symlinks pointing to other units shall be
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--method EnqueueJob is not documented!-->
interface org.freedesktop.DBus.Properties { ... };
interface org.freedesktop.systemd1.Unit { ... };
};
- </programlisting>
+</programlisting>
<!--method GetProcesses is not documented!-->
<programlisting>
#define SD_EXEC_DIRECTORY_READ_ONLY (UINT64_C(1) << 0)
- </programlisting>
+</programlisting>
<para><varname>ExtraFileDescriptorNames</varname> contains file descriptor names passed to the service via
the <varname>ExtraFileDescriptors</varname> property in the <function>StartTransientUnit()</function>
interface org.freedesktop.DBus.Properties { ... };
interface org.freedesktop.systemd1.Unit { ... };
};
- </programlisting>
+</programlisting>
<!--method GetProcesses is not documented!-->
interface org.freedesktop.DBus.Properties { ... };
interface org.freedesktop.systemd1.Unit { ... };
};
- </programlisting>
+</programlisting>
<para>Target units have neither type-specific methods nor properties.</para>
</refsect1>
interface org.freedesktop.DBus.Properties { ... };
interface org.freedesktop.systemd1.Unit { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
interface org.freedesktop.DBus.Properties { ... };
interface org.freedesktop.systemd1.Unit { ... };
};
- </programlisting>
+</programlisting>
<!--method GetProcesses is not documented!-->
interface org.freedesktop.DBus.Properties { ... };
interface org.freedesktop.systemd1.Unit { ... };
};
- </programlisting>
+</programlisting>
<!--property Where is not documented!-->
interface org.freedesktop.DBus.Properties { ... };
interface org.freedesktop.systemd1.Unit { ... };
};
- </programlisting>
+</programlisting>
<!--property OnClockChange is not documented!-->
interface org.freedesktop.DBus.Properties { ... };
interface org.freedesktop.systemd1.Unit { ... };
};
- </programlisting>
+</programlisting>
<!--method GetProcesses is not documented!-->
interface org.freedesktop.DBus.Properties { ... };
interface org.freedesktop.systemd1.Unit { ... };
};
- </programlisting>
+</programlisting>
<!--property MakeDirectory is not documented!-->
interface org.freedesktop.DBus.Properties { ... };
interface org.freedesktop.systemd1.Unit { ... };
};
- </programlisting>
+</programlisting>
<!--method GetProcesses is not documented!-->
interface org.freedesktop.DBus.Properties { ... };
interface org.freedesktop.systemd1.Unit { ... };
};
- </programlisting>
+</programlisting>
<!--method GetProcesses is not documented!-->
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--method GetAfter is not documented!-->
$ gdbus introspect --system \
--dest org.freedesktop.systemd1 \
--object-path /org/freedesktop/systemd1
- </programlisting>
+</programlisting>
</example>
<example>
/org/freedesktop/systemd1 \
org.freedesktop.systemd1.Manager \
GetUnit s systemd-resolved.service | cut -d'"' -f2)
- </programlisting>
+</programlisting>
</example>
<example>
<programlisting>
$ gdbus introspect --system --dest org.freedesktop.systemd1 \
--object-path /org/freedesktop/systemd1/job/1292
- </programlisting>
+</programlisting>
</example>
</refsect1>
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
<programlisting>
#define SD_SYSUPDATE_OFFLINE (UINT64_C(1) << 0)
- </programlisting>
+</programlisting>
<para>When <constant>SD_SYSUPDATE_OFFLINE</constant> is set, this method returns only the versions
installed locally. Otherwise, this method pulls metadata from the network and returns all versions
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
<programlisting>$ gdbus introspect --system \
--dest org.freedesktop.sysupdate1 \
--object-path /org/freedesktop/sysupdate1
- </programlisting>
+</programlisting>
</example>
<example>
<programlisting>$ gdbus introspect --system \
--dest org.freedesktop.sysupdate1 \
--object-path /org/freedesktop/sysupdate1/target/host
- </programlisting>
+</programlisting>
</example>
<example>
<programlisting>$ gdbus introspect --system \
--dest org.freedesktop.sysupdate1 \
--object-path /org/freedesktop/sysupdate1/job/_1
- </programlisting>
+</programlisting>
</example>
</refsect1>
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--Autogenerated cross-references for systemd.directives, do not edit-->
$ gdbus introspect --system \
--dest org.freedesktop.timedate1 \
--object-path /org/freedesktop/timedate1
- </programlisting>
+</programlisting>
</example>
</refsect1>
interface org.freedesktop.DBus.Introspectable { ... };
interface org.freedesktop.DBus.Properties { ... };
};
- </programlisting>
+</programlisting>
<!--method SetRuntimeNTPServers is not documented!-->
$ gdbus introspect --system \
--dest org.freedesktop.timesync1 \
--object-path /org/freedesktop/timesync1
- </programlisting>
+</programlisting>
</example>
</refsect1>
pam_set_data(handle, "systemd.cpu_weight", (void *)"100", cleanup);
pam_set_data(handle, "systemd.io_weight", (void *)"340", cleanup);
pam_set_data(handle, "systemd.runtime_max_sec", (void *)"3600", cleanup);
- </programlisting>
+</programlisting>
</para>
</refsect1>
-auth optional pam_gnome_keyring.so
-session optional pam_gnome_keyring.so auto_start
-session optional pam_kwallet5.so auto_start
- </programlisting>
+</programlisting>
<para>And add the following lines to your display manager's systemd service file, so it can access root's keyring:</para>
<programlisting>
[Service]
KeyringMode=inherit
- </programlisting>
+</programlisting>
<para>In this setup, early during the boot process,
<citerefentry><refentrytitle>systemd-cryptsetup@.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>
<para>Append a structure composed of a string and a D-Bus path:</para>
<programlisting>sd_bus_message_append(m, "(so)", "a string", "/a/path");
- </programlisting>
+</programlisting>
<para>Append an array of UNIX file descriptors:</para>
<programlisting>sd_bus_message_append(m, "ah", 3, STDIN_FILENO, STDOUT_FILENO, STDERR_FILENO);
- </programlisting>
+</programlisting>
<para>Append a variant, with the real type "g" (signature),
and value "sdbusisgood":</para>
</para>
<programlisting>sd_bus_message_append(m, "a{is}", 3, 1, "a", 2, "b", 3, NULL);
- </programlisting>
+</programlisting>
</refsect1>
<refsect1>
STRING "AnExplicitProperty";
};
};
- </programlisting>
+</programlisting>
</para>
</refsect1>
const char *s, *t, *u;
sd_bus_message_read(m, "a{is}", 3, &i, &s, &j, &t, &k, &u);
- </programlisting>
+</programlisting>
<para>Read a single file descriptor, and duplicate it in order to keep it open after the message is
freed.</para>
|
v
FINISHED
- </programlisting>
+</programlisting>
</refsect1>
<refsect1>
sd_notify(0, "READY=1");
/* set timeout to 5 seconds */
sd_notify_barrier(0, 5 * 1000000);
- </programlisting>
+</programlisting>
</example>
</refsect1>
Sun 2017-02-26 18:55:42 EST 1min 14s left Thu 2017-02-23 13:54:44 EST 3 days ago systemd-tmpfiles-clean.timer systemd-tmpfiles-clean.service
Sun 2017-02-26 20:37:16 EST 1h 42min left Sun 2017-02-26 11:56:36 EST 6h ago apt-daily.timer apt-daily.service
Sun 2017-02-26 20:57:49 EST 2h 3min left Sun 2017-02-26 11:56:36 EST 6h ago snapd.refresh.timer snapd.refresh.service
- </programlisting>
+</programlisting>
</para>
<para><emphasis>NEXT</emphasis> shows the next time the timer will run.</para>
[Unit]
AllowedCPUs=7,11
EOF
- </programlisting>
+</programlisting>
<para>Multiple drop-ins may be "edited" in this mode; the same contents will be written to all of
them.</para>
23ms sysroot.mount
11ms initrd-udevadm-cleanup-db.service
3ms sys-kernel-config.mount
- </programlisting>
+</programlisting>
</example>
</refsect2>
# /etc/systemd/logind.conf.d/50-override.conf
... some administrator override
- </programlisting>
+</programlisting>
</example>
</refsect2>
0
$ systemd-analyze compare-versions 1 ge 2; echo $?
1
- </programlisting>
+</programlisting>
</example>
</refsect2>
No such file or directory.
Failed to create user.slice/start: Invalid argument
user.slice: man nosuchfile(1) command failed with code 16
- </programlisting>
+</programlisting>
</example>
<example>
$ systemd-analyze verify ./a.socket ./b.socket
Service a.service not loaded, a.socket cannot be started.
Service b@0.service not loaded, b.socket cannot be started.
- </programlisting>
+</programlisting>
</example>
<example>
$ systemd-analyze verify /tmp/source:alias.service
alias.service:7: Unknown key name 'MysteryKey' in section 'Service', ignoring.
- </programlisting>
+</programlisting>
</example>
</refsect2>
"buildId" : "b5e428254abf14237b0ae70ed85fffbb98a78f88"
}
}
- </programlisting>
+</programlisting>
</example>
</refsect2>
"range": 1
}
}
- </programlisting>
+</programlisting>
</example>
</refsect1>
COREDUMP_CGROUP=/user.slice/user-1000.slice/user@1000.service/app.slice/app-….scope
COREDUMP_FILENAME=/var/lib/systemd/coredump/core.Web….552351.….zst
…
- </programlisting>
+</programlisting>
<para>The following fields are saved (if known) with the journal entry</para>
pos: ...
flags: ...
...
- </programlisting>
+</programlisting>
<para>The first line contains the file descriptor number <replaceable>fd</replaceable> and the path,
while subsequent lines show the contents of
$ systemd-id128 show 773f91ef-66d4-49b5-bd83-d683bf40ad16
NAME ID
user-home 773f91ef66d449b5bd83d683bf40ad16
- </programlisting>
+</programlisting>
</example>
<example>
$ systemd-id128 -Pu show 3a9d668b-4db7-4939-8a4a-5e78a03bffb7 \
-a 1fb8f24b-02df-458d-9659-cc8ace68e28a
47b82cb1-5339-43da-b2a6-1c350aef1bd1
- </programlisting>
+</programlisting>
<para>On a given machine with the ID 3a9d668b-4db7-4939-8a4a-5e78a03bffb7, for the application
1fb8f24b-02df-458d-9659-cc8ace68e28a, we generate an application-specific machine ID
<para>Copy local journal events to a different journal directory:
<programlisting>
journalctl -o export | systemd-journal-remote -o /tmp/dir/foo.journal -
- </programlisting>
+</programlisting>
</para>
<para>Retrieve all available events from a remote
<filename>/var/log/journal/remote/remote-some.host.journal</filename>:
<programlisting>
systemd-journal-remote --url http://some.host:19531/
- </programlisting>
+</programlisting>
</para>
<para>Retrieve current boot events and wait for new events from a remote
<filename>/var/log/journal/remote/remote-some.host.journal</filename>:
<programlisting>
systemd-journal-remote --url http://some.host:19531/entries?boot&follow
- </programlisting>
+</programlisting>
</para>
</refsect1>
--public-key=tpm2-pcr-public-key-initrd.pem \
--phase=enter-initrd
Wrote unsigned vmlinux-1.2.3.efi
- </programlisting>
+</programlisting>
<para><command>ukify</command> prints out both invocations of <command>systemd-measure</command> as
informative output (the lines starting with <literal>+</literal>); this allows us to see how
send them out over the network using the usual rules for multi-label name routing <footnote><para>For
example, if <filename>/etc/resolv.conf</filename> has <programlisting>nameserver 127.0.0.53
search foobar.com barbar.com
- </programlisting>and we look up <literal>localhost</literal>, <filename>nss-dns</filename> will send
+</programlisting>and we look up <literal>localhost</literal>, <filename>nss-dns</filename> will send
the following queries to <filename>systemd-resolved</filename> listening on 127.0.0.53:53: first
<literal>localhost.foobar.com</literal>, then <literal>localhost.barbar.com</literal>, and finally
<literal>localhost</literal>. If (hopefully) the first two queries fail,
<programlisting>$ systemd-run -t echo "<${INVOCATION_ID}>" '<${INVOCATION_ID}>'
<> <5d0149bfa2c34b79bccb13074001eb20>
- </programlisting>
+</programlisting>
<para>The first argument is expanded by the shell (double quotes), but the second one is not expanded
by the shell (single quotes).
<programlisting>$ systemd-run --expand-environment=no -t bash \
-c 'echo $SHELL $$ >/dev/stdout'
/bin/bash 12345
- </programlisting>
+</programlisting>
<para>The last argument is passed verbatim to the
<citerefentry project='man-pages'><refentrytitle>bash</refentrytitle><manvolnum>1</manvolnum></citerefentry>
<programlisting>
$ mkosi -d arch -p systemd -p linux --autologin -o image.raw -f build
$ systemd-vmspawn --image=image.raw
- </programlisting>
+</programlisting>
</example>
<example>
$ sha256sum -c Fedora-Cloud-&fedora_latest_version;-&fedora_cloud_release;-x86_64-CHECKSUM
# machinectl import-raw Fedora-Cloud-Base-&fedora_latest_version;-&fedora_cloud_release;.x86_64.raw.xz fedora-&fedora_latest_version;-cloud
# systemd-vmspawn -M fedora-&fedora_latest_version;-cloud
- </programlisting>
+</programlisting>
</example>
<example>
--linux mkosi.output/system.efi \
--forward-journal=vm.journal \
enforcing=0
- </programlisting>
+</programlisting>
- <para>Note: this example also uses a kernel command line argument to ensure SELinux isn't started in enforcing mode.</para>
+ <para>Note: this example also uses a kernel command line argument to ensure SELinux isn't started in
+ enforcing mode.</para>
</example>
<example>
--vsock-cid $my_vsock_cid \
enforcing=0
$ ssh root@vsock/$my_vsock_cid -i /run/user/$UID/systemd/vmspawn/machine-*-system-ed25519
- </programlisting>
+</programlisting>
</example>
</refsect1>
[Service]
ExecStart=/bin/myprogram
- </programlisting>
+</programlisting>
<para>A service <filename index="false">mysuccess.service</filename> which can trigger an
<varname>OnSuccess=</varname> dependency.</para>
[Service]
ExecStart=/bin/mysecondprogram
- </programlisting>
+</programlisting>
<para>A service <filename index="false">myhandler.service</filename> which can be triggered
by any of the above services.</para>
[Service]
ExecStart=/bin/bash -c "echo $MONITOR_SERVICE_RESULT $MONITOR_EXIT_CODE $MONITOR_EXIT_STATUS $MONITOR_INVOCATION_ID $MONITOR_UNIT"
- </programlisting>
+</programlisting>
<para>If <filename index="false">myfailer.service</filename> were to run and exit in failure,
then <filename index="false">myhandler.service</filename> would be triggered and the
MONITOR_EXIT_STATUS=1
MONITOR_INVOCATION_ID=cc8fdc149b2b4ca698d4f259f4054236
MONITOR_UNIT=myfailer.service
- </programlisting>
+</programlisting>
<para>If <filename index="false">mysuccess.service</filename> were to run and exit in success,
then <filename index="false">myhandler.service</filename> would be triggered and the
MONITOR_EXIT_STATUS=0
MONITOR_INVOCATION_ID=6ab9af147b8c4a3ebe36e7a5f8611697
MONITOR_UNIT=mysuccess.service
- </programlisting>
+</programlisting>
</example>
<programlisting>ID_NET_NAME_ONBOARD=eno1
ID_NET_NAME_ONBOARD_LABEL=Ethernet Port 1
- </programlisting>
+</programlisting>
</example>
<example>
ID_NET_NAME_ALLOW=1
ID_NET_NAME_ALLOW_DEV_PORT=0
ID_NET_NAME_ALLOW_PHYS_PORT_NAME=0
- </programlisting>
+</programlisting>
</example>
</refsect1>
[FooOverUDP]
Port=5555
Protocol=4
- </programlisting>
+</programlisting>
</example>
<example>
<title>/etc/systemd/network/25-fou-ipip.netdev</title>
Remote=10.65.208.211
FooOverUDP=yes
FOUDestinationPort=5555
- </programlisting>
+</programlisting>
</example>
<example>
<title>/etc/systemd/network/25-tap.netdev</title>
<programlisting>[NetDev]
Name=macvtap-test
Kind=macvtap
- </programlisting>
+</programlisting>
</example>
<example>
<title>/etc/systemd/network/25-wireguard.netdev</title>
Tunnel=sit-tun
Tunnel=gre-tun
Tunnel=vti-tun
- </programlisting>
+</programlisting>
<programlisting>/etc/systemd/network/25-tunnel-ipip.netdev
[NetDev]
Name=ipip-tun
Kind=ipip
- </programlisting>
+</programlisting>
<programlisting>/etc/systemd/network/25-tunnel-sit.netdev
[NetDev]
Name=sit-tun
Kind=sit
- </programlisting>
+</programlisting>
<programlisting>/etc/systemd/network/25-tunnel-gre.netdev
[NetDev]
Name=gre-tun
Kind=gre
- </programlisting>
+</programlisting>
<programlisting>/etc/systemd/network/25-tunnel-vti.netdev
[NetDev]
Name=vti-tun
Kind=vti
- </programlisting>
+</programlisting>
<para>This will bring interface <literal>ens1</literal> up and create an IPIP tunnel,
a SIT tunnel, a GRE tunnel, and a VTI tunnel using it.</para>
/ \
b1.service b2.service
CPUWeight=1000
- </programlisting>
+</programlisting>
<para>In this hierarchy, the <option>cpu</option> controller is enabled for all units shown except
<filename>b1.service</filename> and <filename>b2.service</filename>. Because there is no explicit
yearly → *-01-01 00:00:00
quarterly → *-01,04,07,10-01 00:00:00
semiannually → *-01,07-01 00:00:00
- </programlisting>
+</programlisting>
<para>Examples for valid timestamps and their
normalized form:</para>
Type=oneshot
# Perform some special action for when %i exits unexpectedly.
ExecStart=/usr/sbin/myfailurehandler %i
- </programlisting>
+</programlisting>
<para>We can then add an instance of
<filename index='false'>failure-handler@.service</filename> as an
<programlisting>[Unit]
OnFailure=failure-handler@%N.service
- </programlisting>
+</programlisting>
<para>Now, after running <command>systemctl daemon-reload</command> all
services will have acquired an <varname>OnFailure=</varname> dependency on
<command>mkdir /etc/systemd/system/failure-handler@.service.d/</command>
<command>ln -s /dev/null /etc/systemd/system/failure-handler@.service.d/10-all.conf</command>
<command>systemctl daemon-reload</command>
- </programlisting>
+</programlisting>
<para>This ensures that if a <filename index='false'>failure-handler@.service</filename> instance fails it will not trigger an instance named
<filename index='false'>failure-handler@failure-handler.service</filename>.</para>
<title>Create a directory with a SMACK attribute</title>
<programlisting>D /run/cups - - - -
t /run/cups - - - - security.SMACK64=printing user.attr-with-spaces="foo bar"
- </programlisting>
+</programlisting>
<para>The directory will be owned by root and have default mode. Its contents are
not subject to time-based cleanup, but will be obliterated when
--linux=/lib/modules/6.0.9-300.fc37.x86_64/vmlinuz \
--initrd=/some/path/initramfs-6.0.9-300.fc37.x86_64.img \
--cmdline='quiet rw'
- </programlisting>
+</programlisting>
<para>This creates an unsigned UKI <filename>./vmlinuz.unsigned.efi</filename>.</para>
</example>
--secureboot-certificate=sb.cert \
--sign-kernel \
--cmdline='quiet rw rhgb'
- </programlisting>
+</programlisting>
<para>This creates a signed UKI <filename index='false'>./vmlinuz.signed.efi</filename>.
The initrd section contains two concatenated parts, <filename index='false'>early_cpio</filename>
$ ukify -c ukify.conf build \
--linux=/lib/modules/6.0.9-300.fc37.x86_64/vmlinuz \
--initrd=/some/path/initramfs-6.0.9-300.fc37.x86_64.img
- </programlisting>
+</programlisting>
<para>One "initrd" (<filename index='false'>early_cpio</filename>) is specified in the config file, and
the other initrd (<filename index='false'>initramfs-6.0.9-300.fc37.x86_64.img</filename>) is specified
--sbat='sbat,1,SBAT Version,sbat,1,https://github.com/rhboot/shim/blob/main/SBAT.md
uki-addon.author,1,UKI Addon for System,uki-addon.author,1,https://www.freedesktop.org/software/systemd/man/systemd-stub.html'
--output=debug.addon.efi
- </programlisting>
+</programlisting>
<para>This creates a signed PE binary that contains the additional kernel command line parameter
<literal>debug</literal> with SBAT metadata referring to the owner of the addon.</para>
<programlisting>$ ukify build \
--profile='TITLE=Base' \
--output=profile0.efi
- </programlisting>
+</programlisting>
<para>Add a second profile (@1):</para>
ID=storagetm' \
--cmdline='quiet rw rd.systemd.unit=stroage-target-mode.target' \
--output=profile1.efi
- </programlisting>
+</programlisting>
<para>Add a third profile (@2):</para>
ID=factory-reset' \
--cmdline='quiet rw systemd.unit=factory-reset.target' \
--output=profile2.efi
- </programlisting>
+</programlisting>
<para>Then, create a UKI and include all the generated profiles:</para>
--join-profile=profile1.efi \
--join-profile=profile2.efi \
--output=base.efi
- </programlisting>
+</programlisting>
<para>The resulting UKI <filename>base-with-profile-0-1-2.efi</filename> will now contain three profiles.</para>
</example>
xml = etree.fromstring(out, parser=xml_parser())
new_text, declarations, interfaces = xml_to_text(node, xml, only_interface=interface)
- programlisting.text = '\n' + new_text + ' '
+ programlisting.text = '\n' + new_text
if declarations:
missing = check_documented(document, declarations, stats, interface, missing_version)