systemd-analyze.xml | systemd-analyze.xml | |||
---|---|---|---|---|
skipping to change at line 98 | skipping to change at line 98 | |||
<command>systemd-analyze</command> | <command>systemd-analyze</command> | |||
<arg choice="opt" rep="repeat">OPTIONS</arg> | <arg choice="opt" rep="repeat">OPTIONS</arg> | |||
<arg choice="plain">dump</arg> | <arg choice="plain">dump</arg> | |||
</cmdsynopsis> | </cmdsynopsis> | |||
<cmdsynopsis> | <cmdsynopsis> | |||
<command>systemd-analyze</command> | <command>systemd-analyze</command> | |||
<arg choice="opt" rep="repeat">OPTIONS</arg> | <arg choice="opt" rep="repeat">OPTIONS</arg> | |||
<arg choice="plain">set-log-level</arg> | <arg choice="plain">set-log-level</arg> | |||
<arg choice="opt"><replaceable>LEVEL</replaceable>< /arg> | <arg choice="opt"><replaceable>LEVEL</replaceable>< /arg> | |||
</cmdsynopsis> | </cmdsynopsis> | |||
<cmdsynopsis> | ||||
<command>systemd-analyze</command> | ||||
<arg choice="opt" rep="repeat">OPTIONS</arg> | ||||
<arg choice="plain">verify</arg> | ||||
<arg choice="opt" rep="repeat"><replaceable>FILES</ | ||||
replaceable></arg> | ||||
</cmdsynopsis> | ||||
</refsynopsisdiv> | </refsynopsisdiv> | |||
<refsect1> | <refsect1> | |||
<title>Description</title> | <title>Description</title> | |||
<para><command>systemd-analyze</command> may be used | <para><command>systemd-analyze</command> may be used | |||
to determine system boot-up performance statistics and | to determine system boot-up performance statistics and | |||
retrieve other state and tracing information from the | retrieve other state and tracing information from the | |||
system and service manager.</para> | system and service manager, and to verify the | |||
correctness of unit files.</para> | ||||
<para><command>systemd-analyze time</command> | <para><command>systemd-analyze time</command> | |||
prints the time spent in the kernel before | prints the time spent in the kernel before | |||
userspace has been reached, the time spent in the | userspace has been reached, the time spent in the | |||
initial RAM disk (initrd) before normal system | initial RAM disk (initrd) before normal system | |||
userspace has been reached, and the time normal system | userspace has been reached, and the time normal system | |||
userspace took to initialize. Note that these | userspace took to initialize. Note that these | |||
measurements simply measure the time passed up to the | measurements simply measure the time passed up to the | |||
point where all system services have been spawned, but | point where all system services have been spawned, but | |||
not necessarily until they fully finished | not necessarily until they fully finished | |||
skipping to change at line 174 | skipping to change at line 181 | |||
applications.</para> | applications.</para> | |||
<para><command>systemd-analyze set-log-level | <para><command>systemd-analyze set-log-level | |||
<replaceable>LEVEL</replaceable></command> changes the | <replaceable>LEVEL</replaceable></command> changes the | |||
current log level of the <command>systemd</command> | current log level of the <command>systemd</command> | |||
daemon to <replaceable>LEVEL</replaceable> (accepts | daemon to <replaceable>LEVEL</replaceable> (accepts | |||
the same values as <option>--log-level=</option> | the same values as <option>--log-level=</option> | |||
described in | described in | |||
<citerefentry><refentrytitle>systemd</refentrytitle><manvol num>1</manvolnum></citerefentry>).</para> | <citerefentry><refentrytitle>systemd</refentrytitle><manvol num>1</manvolnum></citerefentry>).</para> | |||
<para><command>systemd-analyze verify</command> will | ||||
load unit files and print warnings if any errors are | ||||
detected. Files specified on the command line will be | ||||
loaded, but also any other units referenced by | ||||
them. This command works by prepending the directories | ||||
for all command line arguments at the beginning of the | ||||
unit load path, which means that all units files found | ||||
in those directories will be used in preference to the | ||||
unit files found in the standard locations, even if | ||||
not listed explicitly.</para> | ||||
<para>If no command is passed, <command>systemd-analyze | <para>If no command is passed, <command>systemd-analyze | |||
time</command> is implied.</para> | time</command> is implied.</para> | |||
</refsect1> | </refsect1> | |||
<refsect1> | <refsect1> | |||
<title>Options</title> | <title>Options</title> | |||
<para>The following options are understood:</para> | <para>The following options are understood:</para> | |||
<variablelist> | <variablelist> | |||
<varlistentry> | <varlistentry> | |||
<term><option>--user</option></term> | <term><option>--user</option></term> | |||
<listitem><para>Shows performance data | <listitem><para>Operates on the user | |||
of user sessions instead of the system | systemd instance.</para></listitem> | |||
manager.</para></listitem> | ||||
</varlistentry> | </varlistentry> | |||
<varlistentry> | <varlistentry> | |||
<term><option>--system</option></term> | <term><option>--system</option></term> | |||
<listitem><para>Shows performance data | <listitem><para>Operates on the system | |||
of the system manager. This is the | systemd instance. This is the implied | |||
implied default.</para></listitem> | default.</para></listitem> | |||
</varlistentry> | </varlistentry> | |||
<varlistentry> | <varlistentry> | |||
<term><option>--order</option></term> | <term><option>--order</option></term> | |||
<term><option>--require</option></term> | <term><option>--require</option></term> | |||
<listitem><para>When used in | <listitem><para>When used in | |||
conjunction with the | conjunction with the | |||
<command>dot</command> command (see | <command>dot</command> command (see | |||
above), selects which dependencies are | above), selects which dependencies are | |||
skipping to change at line 260 | skipping to change at line 277 | |||
<listitem><para>When used in conjunction | <listitem><para>When used in conjunction | |||
with the <command>critical-chain</command> | with the <command>critical-chain</command> | |||
command (see above), also show units, which | command (see above), also show units, which | |||
finished <replaceable>timespan</replaceable > earlier, than the | finished <replaceable>timespan</replaceable > earlier, than the | |||
latest unit in the same level. The unit of | latest unit in the same level. The unit of | |||
<replaceable>timespan</replaceable> is seco nds | <replaceable>timespan</replaceable> is seco nds | |||
unless specified with a different unit, | unless specified with a different unit, | |||
e.g. "50ms".</para></listitem> | e.g. "50ms".</para></listitem> | |||
</varlistentry> | </varlistentry> | |||
<varlistentry> | ||||
<term><option>--no-man</option></term> | ||||
<listitem><para>Do not invoke man to verify | ||||
the existence | ||||
of man pages listen in <varname>Documentati | ||||
on=</varname>. | ||||
</para></listitem> | ||||
</varlistentry> | ||||
<xi:include href="user-system-options.xml" xpointer ="host" /> | <xi:include href="user-system-options.xml" xpointer ="host" /> | |||
<xi:include href="user-system-options.xml" xpointer ="machine" /> | <xi:include href="user-system-options.xml" xpointer ="machine" /> | |||
<xi:include href="standard-options.xml" xpointer="h elp" /> | <xi:include href="standard-options.xml" xpointer="h elp" /> | |||
<xi:include href="standard-options.xml" xpointer="v ersion" /> | <xi:include href="standard-options.xml" xpointer="v ersion" /> | |||
<xi:include href="standard-options.xml" xpointer="n o-pager" /> | <xi:include href="standard-options.xml" xpointer="n o-pager" /> | |||
</variablelist> | </variablelist> | |||
</refsect1> | </refsect1> | |||
<refsect1> | <refsect1> | |||
<title>Exit status</title> | <title>Exit status</title> | |||
<para>On success, 0 is returned, a non-zero failure | <para>On success, 0 is returned, a non-zero failure | |||
code otherwise.</para> | code otherwise.</para> | |||
</refsect1> | </refsect1> | |||
<refsect1> | <refsect1> | |||
<title>Examples</title> | <title>Examples for <command>dot</command></title> | |||
<para>This plots all dependencies of any unit whose | <example> | |||
name starts with <literal>avahi-daemon.</literal>:</para> | <title>Plots all dependencies of any unit whose | |||
name starts with <literal>avahi-daemon</literal></t | ||||
itle> | ||||
<programlisting>$ systemd-analyze dot 'avahi-daemon.*' | do | <programlisting>$ systemd-analyze dot 'avahi-daemon | |||
t -Tsvg > avahi.svg | .*' | dot -Tsvg > avahi.svg | |||
$ eog avahi.svg</programlisting> | $ eog avahi.svg</programlisting> | |||
</example> | ||||
<para>This plots the dependencies between all known target | <example> | |||
units:</para> | <title>Plots the dependencies between all known tar | |||
get units</title> | ||||
<programlisting>systemd-analyze dot --to-pattern='*.target' --from-pattern='*.target' | dot -Tsvg > targets.svg | <programlisting>systemd-analyze dot --to-pattern='* .target' --from-pattern='*.target' | dot -Tsvg > targets.svg | |||
$ eog targets.svg</programlisting> | $ eog targets.svg</programlisting> | |||
</example> | ||||
</refsect1> | ||||
<refsect1> | ||||
<title>Examples for <command>verify</command></title> | ||||
<para>The following errors are currently detected:</para> | ||||
<itemizedlist> | ||||
<listitem><para>unknown sections and | ||||
directives, </para></listitem> | ||||
<listitem><para>missing dependencies which are | ||||
required to start the given unit, | ||||
</para></listitem> | ||||
<listitem><para>man pages listed in | ||||
<varname>Documentation=</varname> which are | ||||
not found in the system,</para></listitem> | ||||
<listitem><para>commands listed in | ||||
<varname>ExecStart=</varname> and similar | ||||
which are not found in the system or not | ||||
executable.</para></listitem> | ||||
</itemizedlist> | ||||
<example> | ||||
<title>Misspelt directives</title> | ||||
<programlisting>$ cat ./user.slice | ||||
[Unit] | ||||
WhatIsThis=11 | ||||
Documentation=man:nosuchfile(1) | ||||
Requires=different.service | ||||
[Service] | ||||
Desription=x | ||||
$ systemd-verify ./user.slice | ||||
[./user.slice:9] Unknown lvalue 'WhatIsThis' in section 'Unit' | ||||
[./user.slice:13] Unknown section 'Service'. Ignoring. | ||||
Error: org.freedesktop.systemd1.LoadFailed: | ||||
Unit different.service failed to load: | ||||
No such file or directory. | ||||
Failed to create user.slice/start: Invalid argument | ||||
user.slice: man nosuchfile(1) command failed with code 16 | ||||
</programlisting> | ||||
</example> | ||||
<example> | ||||
<title>Missing service units</title> | ||||
<programlisting>$ tail ./a.socket ./b.socket | ||||
==> ./a.socket <== | ||||
[Socket] | ||||
ListenStream=100 | ||||
==> ./b.socket <== | ||||
[Socket] | ||||
ListenStream=100 | ||||
Accept=yes | ||||
$ systemd-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> | ||||
</example> | ||||
</refsect1> | </refsect1> | |||
<xi:include href="less-variables.xml" /> | <xi:include href="less-variables.xml" /> | |||
<refsect1> | <refsect1> | |||
<title>See Also</title> | <title>See Also</title> | |||
<para> | <para> | |||
<citerefentry><refentrytitle>systemd</refentrytitle ><manvolnum>1</manvolnum></citerefentry>, | <citerefentry><refentrytitle>systemd</refentrytitle ><manvolnum>1</manvolnum></citerefentry>, | |||
<citerefentry><refentrytitle>systemctl</refentrytit le><manvolnum>1</manvolnum></citerefentry> | <citerefentry><refentrytitle>systemctl</refentrytit le><manvolnum>1</manvolnum></citerefentry> | |||
</para> | </para> | |||
End of changes. 13 change blocks. | ||||
16 lines changed or deleted | 113 lines changed or added | |||
This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/ |