[systemd-commits] 10 commits - Makefile.am man/daemon.xml man/halt.xml man/pam_systemd.xml man/runlevel.xml man/sd_booted.xml man/sd-daemon.xml man/sd_is_fifo.xml man/sd_listen_fds.xml man/sd_notify.xml man/shutdown.xml man/systemadm.xml man/systemctl.xml man/systemd-install.xml man/systemd.unit.xml man/systemd.xml man/telinit.xml src/install.c src/log.c src/main.c src/manager.c src/notify.c src/pam-module.c src/path-lookup.c src/sd-daemon.h src/systemctl.c

Lennart Poettering lennart at kemper.freedesktop.org
Wed Jun 23 18:09:52 PDT 2010


 Makefile.am             |   26 +-
 man/daemon.xml          |   11 
 man/halt.xml            |  181 +++++++++++++++
 man/pam_systemd.xml     |  300 +++++++++++++++++++++++++
 man/runlevel.xml        |    9 
 man/sd-daemon.xml       |    2 
 man/sd_booted.xml       |    4 
 man/sd_is_fifo.xml      |    4 
 man/sd_listen_fds.xml   |   24 +-
 man/sd_notify.xml       |   20 +
 man/shutdown.xml        |  156 +++++++++++++
 man/systemadm.xml       |  111 +++++++++
 man/systemctl.xml       |  458 ++++++++++++++++++++++++++++++++++++++
 man/systemd-install.xml |   31 +-
 man/systemd.unit.xml    |   26 +-
 man/systemd.xml         |  566 +++++++++++++++++++++++++++++++++++++++++++++++-
 man/telinit.xml         |  195 ++++++++++++++++
 src/install.c           |    4 
 src/log.c               |    4 
 src/main.c              |    4 
 src/manager.c           |    2 
 src/notify.c            |    2 
 src/pam-module.c        |   37 ++-
 src/path-lookup.c       |    2 
 src/sd-daemon.h         |   18 +
 src/systemctl.c         |   36 +--
 26 files changed, 2156 insertions(+), 77 deletions(-)

New commits:
commit 7874bcd6028d1efbb4451c8b5cf5b2ac8d77af74
Author: Lennart Poettering <lennart at poettering.net>
Date:   Thu Jun 24 03:09:36 2010 +0200

    man: extend manual page documentation

diff --git a/Makefile.am b/Makefile.am
index b650dab..91e66fd 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -319,7 +319,9 @@ dist_man_MANS = \
 	man/halt.8 \
 	man/shutdown.8 \
 	man/systemd-install.1 \
-	man/pam_systemd.8
+	man/pam_systemd.8 \
+	man/systemadm.1 \
+	man/systemctl.1
 
 nodist_man_MANS = \
 	man/systemd.special.7
@@ -339,7 +341,9 @@ dist_noinst_DATA = \
 	man/halt.html \
 	man/shutdown.html \
 	man/systemd-install.html \
-	man/pam_systemd.html
+	man/pam_systemd.html \
+	man/systemadm.html \
+	man/systemctl.html
 
 nodist_noinst_DATA = \
 	man/systemd.special.html
@@ -362,7 +366,9 @@ EXTRA_DIST += \
 	man/halt.xml \
 	man/shutdown.xml \
 	man/systemd-install.xml \
-	man/pam_systemd.xml
+	man/pam_systemd.xml \
+	man/systemadm.xml \
+	man/systemctl.xml
 
 systemd_SOURCES = \
 	src/main.c
diff --git a/man/halt.xml b/man/halt.xml
index f07e04a..97a53ba 100644
--- a/man/halt.xml
+++ b/man/halt.xml
@@ -173,7 +173,8 @@
                 <para>
                         <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
-                        <citerefentry><refentrytitle>shutdown</refentrytitle><manvolnum>8</manvolnum></citerefentry>
+                        <citerefentry><refentrytitle>shutdown</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>wall</refentrytitle><manvolnum>1</manvolnum></citerefentry>
                 </para>
         </refsect1>
 
diff --git a/man/pam_systemd.xml b/man/pam_systemd.xml
index e790dd3..796035f 100644
--- a/man/pam_systemd.xml
+++ b/man/pam_systemd.xml
@@ -207,6 +207,10 @@
                 tools like
                 <citerefentry><refentrytitle>screen</refentrytitle><manvolnum>1</manvolnum></citerefentry>.</para>
 
+                <para>If the options are omitted they default to
+                <option>create-session=1</option>,
+                <option>kill-session=0</option>,
+                <option>kill-user=0</option>.</para>
         </refsect1>
 
         <refsect1>
diff --git a/man/sd_listen_fds.xml b/man/sd_listen_fds.xml
index 4164a99..54874fd 100644
--- a/man/sd_listen_fds.xml
+++ b/man/sd_listen_fds.xml
@@ -160,6 +160,26 @@
         </refsect1>
 
         <refsect1>
+                <title>Environment</title>
+
+                <variablelist>
+                        <varlistentry>
+                                <term><varname>$LISTEN_PID</varname></term>
+                                <term><varname>$LISTEN_FDS</varname></term>
+
+                                <listitem><para>Set by the init system
+                                for supervised processes that use
+                                socket-based activation. This
+                                environment variable specifies the
+                                data
+                                <function>sd_listen_fds()</function>
+                                parses. See above for
+                                details.</para></listitem>
+                        </varlistentry>
+                </variablelist>
+        </refsect1>
+
+        <refsect1>
                 <title>See Also</title>
 
                 <para>
diff --git a/man/sd_notify.xml b/man/sd_notify.xml
index 9d55ca4..6a68955 100644
--- a/man/sd_notify.xml
+++ b/man/sd_notify.xml
@@ -228,6 +228,24 @@
         </refsect1>
 
         <refsect1>
+                <title>Environment</title>
+
+                <variablelist>
+                        <varlistentry>
+                                <term><varname>$NOTIFY_SOCKET</varname></term>
+
+                                <listitem><para>Set by the init system
+                                for supervised processes for status
+                                and start-up completion
+                                notification. This environment variable
+                                specifies the socket
+                                <function>sd_notify()</function> talks
+                                to. See above for details.</para></listitem>
+                        </varlistentry>
+                </variablelist>
+        </refsect1>
+
+        <refsect1>
                 <title>Examples</title>
 
                 <example>
diff --git a/man/shutdown.xml b/man/shutdown.xml
index bff6821..ab14e3d 100644
--- a/man/shutdown.xml
+++ b/man/shutdown.xml
@@ -148,7 +148,8 @@
                 <para>
                         <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
-                        <citerefentry><refentrytitle>halt</refentrytitle><manvolnum>8</manvolnum></citerefentry>
+                        <citerefentry><refentrytitle>halt</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>wall</refentrytitle><manvolnum>1</manvolnum></citerefentry>
                 </para>
         </refsect1>
 
diff --git a/man/systemadm.xml b/man/systemadm.xml
new file mode 100644
index 0000000..1c92a17
--- /dev/null
+++ b/man/systemadm.xml
@@ -0,0 +1,111 @@
+<?xml version='1.0'?> <!--*-nxml-*-->
+<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
+        "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
+
+<!--
+  This file is part of systemd.
+
+  Copyright 2010 Lennart Poettering
+
+  systemd is free software; you can redistribute it and/or modify it
+  under the terms of the GNU General Public License as published by
+  the Free Software Foundation; either version 2 of the License, or
+  (at your option) any later version.
+
+  systemd is distributed in the hope that it will be useful, but
+  WITHOUT ANY WARRANTY; without even the implied warranty of
+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  General Public License for more details.
+
+  You should have received a copy of the GNU General Public License
+  along with systemd; If not, see <http://www.gnu.org/licenses/>.
+-->
+
+<refentry id="systemadm">
+
+        <refentryinfo>
+                <title>systemadm</title>
+                <productname>systemd</productname>
+
+                <authorgroup>
+                        <author>
+                                <contrib>Developer</contrib>
+                                <firstname>Lennart</firstname>
+                                <surname>Poettering</surname>
+                                <email>lennart at poettering.net</email>
+                        </author>
+                </authorgroup>
+        </refentryinfo>
+
+        <refmeta>
+                <refentrytitle>systemadm</refentrytitle>
+                <manvolnum>1</manvolnum>
+        </refmeta>
+
+        <refnamediv>
+                <refname>systemadm</refname>
+                <refpurpose>Graphical frontend for the systemd system
+                and session manager</refpurpose>
+        </refnamediv>
+
+        <refsynopsisdiv>
+                <cmdsynopsis>
+                        <command>systemadm <arg choice="opt" rep="repeat">OPTIONS</arg></command>
+                </cmdsynopsis>
+        </refsynopsisdiv>
+
+        <refsect1>
+                <title>Description</title>
+
+                <para><command>systemadm</command> is a graphical
+                frontend for the systemd system and session manager
+                and allows introspection and control of
+                systemd.</para>
+        </refsect1>
+
+        <refsect1>
+                <title>Options</title>
+
+                <para>The following options are understood:</para>
+
+                <variablelist>
+                        <varlistentry>
+                                <term><option>--h</option></term>
+                                <term><option>--help</option></term>
+
+                                <listitem><para>Prints a short help
+                                text and exits.</para></listitem>
+                        </varlistentry>
+
+
+                        <varlistentry>
+                                <term><option>--system</option></term>
+
+                                <listitem><para>Connect to the systemd
+                                system
+                                manager. (Default)</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>--session</option></term>
+
+                                <listitem><para>Connect to the systemd
+                                session manager of the calling
+                                user.</para></listitem>
+                        </varlistentry>
+
+                </variablelist>
+
+                <para>In addition to this a number of of parameters
+                common to all Gtk+ programs are supported.</para>
+        </refsect1>
+
+        <refsect1>
+                <title>See Also</title>
+                <para>
+                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>
+                </para>
+        </refsect1>
+
+</refentry>
diff --git a/man/systemctl.xml b/man/systemctl.xml
new file mode 100644
index 0000000..696a506
--- /dev/null
+++ b/man/systemctl.xml
@@ -0,0 +1,458 @@
+<?xml version='1.0'?> <!--*-nxml-*-->
+<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
+        "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
+
+<!--
+  This file is part of systemd.
+
+  Copyright 2010 Lennart Poettering
+
+  systemd is free software; you can redistribute it and/or modify it
+  under the terms of the GNU General Public License as published by
+  the Free Software Foundation; either version 2 of the License, or
+  (at your option) any later version.
+
+  systemd is distributed in the hope that it will be useful, but
+  WITHOUT ANY WARRANTY; without even the implied warranty of
+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  General Public License for more details.
+
+  You should have received a copy of the GNU General Public License
+  along with systemd; If not, see <http://www.gnu.org/licenses/>.
+-->
+
+<refentry id="systemd-install">
+
+        <refentryinfo>
+                <title>systemctl</title>
+                <productname>systemd</productname>
+
+                <authorgroup>
+                        <author>
+                                <contrib>Developer</contrib>
+                                <firstname>Lennart</firstname>
+                                <surname>Poettering</surname>
+                                <email>lennart at poettering.net</email>
+                        </author>
+                </authorgroup>
+        </refentryinfo>
+
+        <refmeta>
+                <refentrytitle>systemctl</refentrytitle>
+                <manvolnum>1</manvolnum>
+        </refmeta>
+
+        <refnamediv>
+                <refname>systemctl</refname>
+                <refpurpose>Control the systemd system and session manager</refpurpose>
+        </refnamediv>
+
+        <refsynopsisdiv>
+                <cmdsynopsis>
+                        <command>systemctl <arg choice="opt" rep="repeat">OPTIONS</arg> <arg choice="req">COMMAND</arg> <arg choice="opt" rep="repeat">NAME</arg></command>
+                </cmdsynopsis>
+        </refsynopsisdiv>
+
+        <refsect1>
+                <title>Description</title>
+
+                <para><command>systemctl</command> may be used to
+                introspect and control the state of the
+                <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>
+                system and session manager.</para>
+        </refsect1>
+
+        <refsect1>
+                <title>Options</title>
+
+                <para>The following options are understood:</para>
+
+                <variablelist>
+                        <varlistentry>
+                                <term><option>--help</option></term>
+                                <term><option>--h</option></term>
+
+                                <listitem><para>Prints a short help
+                                text and exits.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>--type=</option></term>
+
+                                <listitem><para>When listing units,
+                                limit display to certain unit
+                                types. If not specified units of all
+                                types will be shown. The argument
+                                should be a unit type name such as
+                                <option>service</option>,
+                                <option>socket</option> and
+                                similar.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>--all</option></term>
+
+                                <listitem><para>When listing units,
+                                show all units, regardless of their
+                                state, including inactive
+                                units.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>--replace</option></term>
+
+                                <listitem><para>If the requested
+                                operation conflicts with an exisiting
+                                unfinished operation, replace the
+                                existing operation by the requested
+                                operation. If this is not specified
+                                the requested operation will
+                                fail.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>--system</option></term>
+
+                                <listitem><para>Talk to the systemd
+                                system manager. (Default)</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>--session</option></term>
+
+                                <listitem><para>Talk to the systemd
+                                session manager of the calling user.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>--block</option></term>
+
+                                <listitem><para>Synchronously wait for
+                                the requested operation to
+                                finish.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>--no-wall</option></term>
+
+                                <listitem><para>Don't send wall
+                                message before
+                                halt, power-off, reboot.</para></listitem>
+                        </varlistentry>
+                </variablelist>
+
+                <para>The following commands are understood:</para>
+
+                <variablelist>
+                        <varlistentry>
+                                <term><command>list-units</command></term>
+
+                                <listitem><para>List known units.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>list-jobs</command></term>
+
+                                <listitem><para>List jobs that are in progress.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>clear-jobs</command></term>
+
+                                <listitem><para>Cancel all jobs that are in progress.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>load [NAME...]</command></term>
+
+                                <listitem><para>Load one or more units
+                                specified on the command line. This
+                                will simply load their configuration
+                                from disk, but not start them. To
+                                start them you need to use the
+                                <command>start</command> command which
+                                will implicitly load a unit that has
+                                not been loaded yet. Note that systemd
+                                garbage collects loaded units that are
+                                not active or referenced by an active
+                                unit. This means that units loaded
+                                this way will usually not stay loaded
+                                for long. Also note that this command
+                                cannot be used to reload unit
+                                configuration. Use the
+                                <command>daemon-reload</command>
+                                command for that. All in all this
+                                command is of little use except for
+                                debugging.</para>
+                                <para>This command should not be
+                                confused with the
+                                <command>daemon-reload</command> or
+                                <command>reload</command>
+                                commands.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><command>cancel [JOB...]</command></term>
+
+                                <listitem><para>Cancel one or more
+                                jobs specified on the command line by
+                                their numeric job
+                                IDs.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>start [NAME...]</command></term>
+
+                                <listitem><para>Start one or more
+                                units specified on the command
+                                line.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>stop [NAME...]</command></term>
+
+                                <listitem><para>Stop one or more units
+                                specified on the command
+                                line.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>restart [NAME...]</command></term>
+
+                                <listitem><para>Restart one or more
+                                units specified on the command
+                                line.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>reload [NAME...]</command></term>
+
+                                <listitem><para>Asks all services
+                                whose units are listed on the command
+                                line to reload their
+                                configuration. Note that this will
+                                reload the daemon configuration
+                                itself, not the unit configuration
+                                file of systemd. If you want systemd
+                                to reload the configuration file of a
+                                unit use the
+                                <command>daemon-reload</command>
+                                command. In other words: for the
+                                example case of Apache, this will
+                                reload Apache's
+                                <filename>httpd.conf</filename> in the
+                                web server, not the
+                                <filename>apache.service</filename>
+                                systemd unit file. </para> <para>This
+                                command should not be confused with
+                                the <command>daemon-reload</command>
+                                or <command>load</command>
+                                commands.</para></listitem>
+
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>isolate [NAME]</command></term>
+
+                                <listitem><para>Start the unit
+                                specified on the command line and its
+                                dependencies and stop all
+                                others.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>monitor</command></term>
+
+                                <listitem><para>Monitor unit/job
+                                changes. This is mostly useful for
+                                debugging purposes and prints a line
+                                each time systemd loads or unloads a
+                                unit configuration file, or a unit
+                                property changes.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>dump</command></term>
+
+                                <listitem><para>Dump server
+                                status. This will output a (usually
+                                very long) human readable manager
+                                status dump. Its format is subject to
+                                change without notice and should not
+                                be parsed by
+                                applications.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>snapshot [NAME]</command></term>
+
+                                <listitem><para>Create a snapshot. If
+                                a snapshot name is specified the new
+                                snapshot will be named after it. If
+                                none is specified an automatic
+                                snapshot name is generated. In either
+                                case the snapshot name used is printed
+                                to STDOUT.</para>
+
+                                <para>A snapshot refers to a saved
+                                state of the systemd manager. It is
+                                implemented itself as unit that is
+                                generated dynamically with this
+                                command and has dependencies on all
+                                units active at the time. At a later
+                                time the user may return to this state
+                                by using the
+                                <command>isolate</command> command on
+                                the snapshot unit.</para></listitem>
+
+                                <para>Snapshots are only useful for
+                                saving and restoring which units are
+                                running or are stopped, they do not
+                                save/restore any other
+                                state. Snapshots are dynamic and lost
+                                on reboot.</para>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>daemon-reload</command></term>
+
+                                <listitem><para>Reload systemd manager
+                                configuration. This will reload all
+                                unit files and recreate the entire
+                                dependency tree. While the daemon is
+                                reloaded all sockets systemd listens
+                                on on behalf of user configuration will
+                                stay accessible.</para> <para>This
+                                command should not be confused with
+                                the <command>load</command> or
+                                <command>reload</command>
+                                commands.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>daemon-reexec</command></term>
+
+                                <listitem><para>Reexecute the systemd
+                                manager. This will serialize the
+                                manager state, reexecute the process
+                                and deserialize the state again. This
+                                command is of little use except for
+                                debugging and package
+                                upgrades. Sometimes it might be
+                                helpful as a heavy-weight
+                                <command>daemon-reload</command>. While
+                                the daemon is reexecuted all sockets
+                                systemd listens on on behalf of user
+                                configuration will stay
+                                accessible.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>daemon-exit</command></term>
+
+                                <listitem><para>Ask the systemd
+                                manager to quit. This is only
+                                supported for session managers
+                                (i.e. in conjunction with the
+                                <option>--session</option> option) and
+                                will fail otherwise.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>show-environment</command></term>
+
+                                <listitem><para>Dump the systemd
+                                manager environment block. The
+                                environment block will be dumped in
+                                straight-forward form suitable for
+                                sourcing into a shell script. This
+                                environment block will be passed to
+                                all processes the manager
+                                spawns.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>set-environment [NAME=VALUE...]</command></term>
+
+                                <listitem><para>Set one or more
+                                systemd manager environment variables,
+                                as specified on the command
+                                line.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>unset-environment [NAME...]</command></term>
+
+                                <listitem><para>Unset one or more
+                                systemd manager environment
+                                variables. If only a variable name is
+                                specified it will be removed
+                                regardless of its value. If a variable
+                                and a value are specified the variable
+                                is only removed if it has the
+                                specified value.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><command>halt</command></term>
+
+                                <listitem><para>Shut down and halt the
+                                system. This is mostly equivalent to
+                                <command>start halt.target</command>
+                                but also prints a wall message to all
+                                users.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>poweroff</command></term>
+
+                                <listitem><para>Shut down and
+                                power-off the system. This is mostly
+                                equivalent to <command>start
+                                poweroff.target</command> but also
+                                prints a wall message to all
+                                users.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>reboot</command></term>
+
+                                <listitem><para>Shut down and
+                                reboot the system. This is mostly
+                                equivalent to <command>start
+                                reboot.target</command> but also
+                                prints a wall message to all
+                                users.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>default</command></term>
+
+                                <listitem><para>Enter default
+                                mode. This is mostly equivalent to
+                                <command>start
+                                default.target</command>.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>rescue</command></term>
+
+                                <listitem><para>Enter rescue
+                                mode. This is mostly equivalent to
+                                <command>isolate
+                                rescue.target</command> but also
+                                prints a wall message to all
+                                users.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><command>emergency</command></term>
+
+                                <listitem><para>Enter emergency
+                                mode. This is mostly equivalent to
+                                <command>isolate
+                                emergency.service</command> but also
+                                prints a wall message to all
+                                users.</para></listitem>
+                        </varlistentry>
+                </variablelist>
+
+        </refsect1>
+
+        <refsect1>
+                <title>Exit status</title>
+
+                <para>On success 0 is returned, a non-zero failure
+                code otherwise.</para>
+        </refsect1>
+
+        <refsect1>
+                <title>See Also</title>
+                <para>
+                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>systemadm</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>systemd.special</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>wall</refentrytitle><manvolnum>1</manvolnum></citerefentry>
+                </para>
+        </refsect1>
+
+</refentry>
diff --git a/man/systemd.xml b/man/systemd.xml
index f754348..36bce96 100644
--- a/man/systemd.xml
+++ b/man/systemd.xml
@@ -122,9 +122,9 @@
 
                                 <listitem><para>Dump understood unit
                                 configuration items. This outputs a
-                                terse list of configuration items
-                                understood in unit definition
-                                files.</para></listitem>
+                                terse but complete list of
+                                configuration items understood in unit
+                                definition files.</para></listitem>
                         </varlistentry>
                         <varlistentry>
                                 <term><option>--confirm-spawn</option></term>
@@ -192,32 +192,362 @@
                                 it defaults to
                                 <option>true</option>.</para></listitem>
                         </varlistentry>
-
-
                 </variablelist>
         </refsect1>
 
         <refsect1>
                 <title>Directories</title>
+
+                <variablelist>
+                        <varlistentry>
+                                <term>System unit directories</term>
+
+                                <listitem><para>The systemd system
+                                manager reads unit configuration from
+                                various directories. Packages that
+                                want to install unit files shall place
+                                them in the directory returned by
+                                <command>pkg-config systemd
+                                --variable=systemdsystemunitdir</command>. Other
+                                directories checked are
+                                <filename>/usr/local/share/systemd/system</filename>
+                                and
+                                <filename>/usr/share/systemd/system</filename>. User
+                                configuration always takes
+                                precedence. <command>pkg-config
+                                systemd
+                                --variable=systemdsystemconfdir</command>
+                                returns the path of the system
+                                configuration directory. Packages
+                                should alter this directory only with
+                                the
+                                <citerefentry><refentrytitle>systemd-install</refentrytitle><manvolnum>1</manvolnum></citerefentry>
+                                tool.</para></listitem>
+                        </varlistentry>
+                </variablelist>
+
+                <variablelist>
+                        <varlistentry>
+                                <term>Session unit directories</term>
+
+                                <listitem><para>Similar rules apply
+                                for the session unit
+                                directories. However, here the <ulink
+                                url="http://standards.freedesktop.org/basedir-spec/basedir-spec-latest.html">XDG
+                                Base Directory specification</ulink>
+                                is followed to find
+                                units. Applications should place their
+                                unit files in the directory returned
+                                by <command>pkg-config systemd
+                                --variable=systemdsessionunitdir</command>. Global
+                                configuration is done in the
+                                directory reported by
+                                <command>pkg-config systemd
+                                --variable=systemdsessionconfdir</command>. The
+                                <citerefentry><refentrytitle>systemd-install</refentrytitle><manvolnum>1</manvolnum></citerefentry>
+                                tool can handle both global (i.e. for
+                                all users) and private (for one user)
+                                enabling/disabling of
+                                units.</para></listitem>
+                        </varlistentry>
+                </variablelist>
+
+                <variablelist>
+                        <varlistentry>
+                                <term>SysV init scripts directory</term>
+
+                                <listitem><para>The location of the
+                                SysV init script directory varies
+                                between distributions. If systemd
+                                cannot find a native unit file for a
+                                requested service it will look for a
+                                SysV init script of the same name
+                                (with the
+                                <filename>.service</filename> suffix
+                                removed).</para></listitem>
+                        </varlistentry>
+                </variablelist>
+
+                <variablelist>
+                        <varlistentry>
+                                <term>SysV runlevel link farm directory</term>
+
+                                <listitem><para>The location of the
+                                SysV runlevel link farm directory
+                                varies between distributions. systemd
+                                will take the link farm into account
+                                when figuring out whether a service
+                                shall be enabled. Note that a service
+                                unit with a native unit configuration
+                                file can be started by activating it
+                                in the SysV runlevel link
+                                farm.</para></listitem>
+                        </varlistentry>
+                </variablelist>
         </refsect1>
 
         <refsect1>
-                <title>Signal</title>
+                <title>Signals</title>
 
                 <variablelist>
                         <varlistentry>
-                                <term><filename>SIGTERM</filename></term>
+                                <term>SIGTERM</term>
+
+                                <listitem><para>Upon receiving this
+                                signal the systemd system manager
+                                serializes its state, reexecutes
+                                itself and deserializes the saved
+                                state again. This is mostly equivalent
+                                to <command>systemctl
+                                daemon-reexec</command>.</para>
+
+                                <para>systemd session managers will
+                                start the
+                                <filename>exit.target</filename> unit
+                                when this signal is received. This is
+                                mostly equivalent to
+                                <command>systemctl --session start
+                                exit.target</command>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term>SIGINT</term>
+
+                                <listitem><para>Upon receiving this
+                                signal the systemd system manager will
+                                start the
+                                <filename>ctrl-alt-del.target</filename> unit. This
+                                is mostly equivalent to
+                                <command>systemctl start
+                                ctl-alt-del.target</command>.</para>
+
+                                <para>systemd session managers
+                                treat this signal the same way as
+                                SIGTERM.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term>SIGWINCH</term>
+
+                                <listitem><para>When this signal is
+                                received the systemd system manager
+                                will start the
+                                <filename>kbrequest.target</filename>
+                                unit. This is mostly equivalent to
+                                <command>systemctl start
+                                kbrequest.target</command>.</para>
+
+                                <para>This signal is ignored by
+                                systemd session
+                                managers.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term>SIGPWR</term>
+
+                                <listitem><para>When this signal is
+                                received the systemd manager
+                                will start the
+                                <filename>sigpwr.target</filename>
+                                unit. This is mostly equivalent to
+                                <command>systemctl start
+                                sigpwr.target</command>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term>SIGUSR1</term>
+
+                                <listitem><para>When this signal is
+                                received the systemd manager will try
+                                to reconnect to the D-Bus
+                                bus.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term>SIGUSR2</term>
+
+                                <listitem><para>When this signal is
+                                received the systemd manager will log
+                                its complete state in human readable
+                                form. The data logged is the same as
+                                printed by <command>systemctl
+                                dump</command>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term>SIGHUP</term>
+
+                                <listitem><para>Reloads the complete
+                                daemon configuration. This is mostly
+                                equivalent to <command>systemctl
+                                daemon-reload</command>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term>SIGRTMIN+0</term>
+
+                                <listitem><para>Enters default mode, starts the
+                                <filename>default.target</filename>
+                                unit. This is mostly equivalent to
+                                <command>systemctl start
+                                default.target</command>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term>SIGRTMIN+1</term>
+
+                                <listitem><para>Enters rescue mode,
+                                starts the
+                                <filename>rescue.target</filename>
+                                unit. This is mostly equivalent to
+                                <command>systemctl isolate
+                                rescue.target</command>.</para></listitem>
+                        </varlistentry>
 
-                                <listitem><para>systemd serializes its
-                                state, reexecutes itself and
-                                deserializes the saved state
-                                again. This is mostly equivalent to
-                                <command>systemctl
-                                daemon-reexec</command>.</para></listitem>
+                        <varlistentry>
+                                <term>SIGRTMIN+2</term>
+
+                                <listitem><para>Enters emergency mode,
+                                starts the
+                                <filename>emergency.service</filename>
+                                unit. This is mostly equivalent to
+                                <command>systemctl isolate
+                                emergency.service</command>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term>SIGRTMIN+3</term>
+
+                                <listitem><para>Halts the machine,
+                                starts the
+                                <filename>halt.target</filename>
+                                unit. This is mostly equivalent to
+                                <command>systemctl start
+                                halt.target</command>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term>SIGRTMIN+4</term>
+
+                                <listitem><para>Powers off the machine,
+                                starts the
+                                <filename>poweroff.target</filename>
+                                unit. This is mostly equivalent to
+                                <command>systemctl start
+                                poweroff.target</command>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term>SIGRTMIN+5</term>
+
+                                <listitem><para>Reboots the machine,
+                                starts the
+                                <filename>reboot.target</filename>
+                                unit. This is mostly equivalent to
+                                <command>systemctl start
+                                reboot.target</command>.</para></listitem>
                         </varlistentry>
                 </variablelist>
         </refsect1>
 
+        <refsect1>
+                <title>Environment</title>
+
+                <variablelist>
+                        <varlistentry>
+                                <term><varname>$SYSTEMD_LOG_LEVEL</varname></term>
+                                <listitem><para>systemd reads the
+                                log level from this environment
+                                variable. This can be overriden with
+                                <option>--log-level=</option>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><varname>$SYSTEMD_LOG_TARGET</varname></term>
+                                <listitem><para>systemd reads the
+                                log target from this environment
+                                variable. This can be overriden with
+                                <option>--log-target=</option>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><varname>$SYSTEMD_LOG_COLOR</varname></term>
+                                <listitem><para>Controls whether
+                                systemd highlights important log
+                                messages. This can be overriden with
+                                <option>--log-color=</option>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><varname>$SYSTEMD_LOG_LOCATION</varname></term>
+                                <listitem><para>Controls whether
+                                systemd prints the code location along
+                                with log messages. This can be
+                                overriden with
+                                <option>--log-location=</option>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><varname>$XDG_CONFIG_HOME</varname></term>
+                                <term><varname>$XDG_CONFIG_DIRS</varname></term>
+                                <term><varname>$XDG_DATA_HOME</varname></term>
+                                <term><varname>$XDG_DATA_DIRS</varname></term>
+
+                                <listitem><para>The systemd session
+                                manager uses these variables in
+                                accordance to the <ulink
+                                url="http://standards.freedesktop.org/basedir-spec/basedir-spec-latest.html">XDG
+                                Base Directory specification</ulink>
+                                to find its configuration.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><varname>$SYSTEMD_UNIT_PATH</varname></term>
+
+                                <listitem><para>Controls where systemd
+                                looks for unit
+                                files.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><varname>$SYSTEMD_SYSVINIT_PATH</varname></term>
+
+                                <listitem><para>Controls where systemd
+                                looks for SysV init scripts.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><varname>$SYSTEMD_SYSVRCND_PATH</varname></term>
+
+                                <listitem><para>Controls where systemd
+                                looks for SysV init script runlevel link
+                                farms.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><varname>$LISTEN_PID</varname></term>
+                                <term><varname>$LISTEN_FDS</varname></term>
+
+                                <listitem><para>Set by systemd for
+                                supervised processes during
+                                socket-based activation. See
+                                <citerefentry><refentrytitle>sd_listen_fds</refentrytitle><manvolnum>3</manvolnum></citerefentry>
+                                for more information.
+                                </para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><varname>$NOTIFY_SOCKET</varname></term>
+
+                                <listitem><para>Set by systemd for
+                                supervised processes for status and
+                                start-up completion notification. See
+                                <citerefentry><refentrytitle>sd_notify</refentrytitle><manvolnum>3</manvolnum></citerefentry>
+                                for more information.
+                                </para></listitem>
+                        </varlistentry>
+                </variablelist>
+        </refsect1>
 
         <refsect1>
                 <title>Sockets and FIFOs</title>
@@ -278,11 +608,18 @@
                 </variablelist>
         </refsect1>
 
-
         <refsect1>
                 <title>See Also</title>
                 <para>
+                        <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>systemadm</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>systemd-install</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>systemd-notify</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>daemon</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>sd-daemon</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>systemd.special</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>pkg-config</refentrytitle><manvolnum>1</manvolnum></citerefentry>
                 </para>
         </refsect1>
 
diff --git a/man/telinit.xml b/man/telinit.xml
index 9251879..bbf43bf 100644
--- a/man/telinit.xml
+++ b/man/telinit.xml
@@ -187,7 +187,8 @@
                 <title>See Also</title>
                 <para>
                         <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
-                        <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>
+                        <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>wall</refentrytitle><manvolnum>1</manvolnum></citerefentry>
                 </para>
         </refsect1>
 
commit 5ec7ed4ec693cd69bdc329c38b220d2462df5eba
Author: Lennart Poettering <lennart at poettering.net>
Date:   Thu Jun 24 03:08:37 2010 +0200

    systemctl: minor --help rewording

diff --git a/src/systemctl.c b/src/systemctl.c
index 321e269..9eb72f9 100644
--- a/src/systemctl.c
+++ b/src/systemctl.c
@@ -1429,7 +1429,7 @@ finish:
 static int systemctl_help(void) {
 
         printf("%s [OPTIONS...] {COMMAND} ...\n\n"
-               "Send control commands to the init daemon.\n\n"
+               "Send control commands to the systemd manager.\n\n"
                "  -h --help      Show this help\n"
                "  -t --type=TYPE List only units of a particular type\n"
                "  -a --all       Show all units, including dead ones\n"
@@ -1452,9 +1452,9 @@ static int systemctl_help(void) {
                "  monitor                         Monitor unit/job changes\n"
                "  dump                            Dump server status\n"
                "  snapshot [NAME]                 Create a snapshot\n"
-               "  daemon-reload                   Reload init daemon configuration\n"
-               "  daemon-reexec                   Reexecute init daemon\n"
-               "  daemon-exit                     Ask the init daemon to quit\n"
+               "  daemon-reload                   Reload systemd manager configuration\n"
+               "  daemon-reexec                   Reexecute systemd manager\n"
+               "  daemon-exit                     Ask the systemd manager to quit\n"
                "  show-environment                Dump environment\n"
                "  set-environment [NAME=VALUE...] Set one or more environment variables\n"
                "  unset-environment [NAME...]     Unset one or more environment variables\n"
commit bf9a6e8bfc2a03e549e35e72218ed9ad2574a6e2
Author: Lennart Poettering <lennart at poettering.net>
Date:   Thu Jun 24 03:08:22 2010 +0200

    path-lookup: unconditionally check /usr and /usr/share unit directories

diff --git a/src/path-lookup.c b/src/path-lookup.c
index 4160d55..2590eb3 100644
--- a/src/path-lookup.c
+++ b/src/path-lookup.c
@@ -182,6 +182,8 @@ int lookup_paths_init(LookupPaths *p, ManagerRunningAs running_as) {
                 } else
                         if (!(p->unit_path = strv_new(
                                               SYSTEM_CONFIG_UNIT_PATH,  /* /etc/systemd/system/ */
+                                              "/usr/local/share/systemd/system",
+                                              "/usr/share/systemd/system",
                                               SYSTEM_DATA_UNIT_PATH,    /* /lib/systemd/system/ */
                                               NULL)))
                                 return -ENOMEM;
commit e6b3f00f6675475b770d3693498b224f232b0d1c
Author: Lennart Poettering <lennart at poettering.net>
Date:   Thu Jun 24 03:07:43 2010 +0200

    manager: both rescue and emergency should be started in isolate mode

diff --git a/src/manager.c b/src/manager.c
index f1a79b5..f9763c8 100644
--- a/src/manager.c
+++ b/src/manager.c
@@ -1879,7 +1879,7 @@ static int manager_process_signal_fd(Manager *m) {
                         if ((int) sfsi.ssi_signo >= SIGRTMIN+0 &&
                             (int) sfsi.ssi_signo < SIGRTMIN+(int) ELEMENTSOF(table)) {
                                 manager_start_target(m, table[sfsi.ssi_signo - SIGRTMIN],
-                                                     sfsi.ssi_signo == 2 ? JOB_ISOLATE : JOB_REPLACE);
+                                                     (sfsi.ssi_signo == 1 || sfsi.ssi_signo == 2) ? JOB_ISOLATE : JOB_REPLACE);
                                 break;
                         }
 
commit 541d6159c6b82c6786730d70b761d1aefffa8deb
Author: Lennart Poettering <lennart at poettering.net>
Date:   Thu Jun 24 03:07:06 2010 +0200

    log: unify log env var prefix

diff --git a/src/log.c b/src/log.c
index 4840185..a47285c 100644
--- a/src/log.c
+++ b/src/log.c
@@ -474,11 +474,11 @@ void log_parse_environment(void) {
                 if (log_set_max_level_from_string(e) < 0)
                         log_warning("Failed to parse log level %s. Ignoring.", e);
 
-        if ((e = getenv("SYSTEMD_SHOW_COLOR")))
+        if ((e = getenv("SYSTEMD_LOG_COLOR")))
                 if (log_show_color_from_string(e) < 0)
                         log_warning("Failed to parse bool %s. Ignoring.", e);
 
-        if ((e = getenv("SYSTEMD_SHOW_LOCATION"))) {
+        if ((e = getenv("SYSTEMD_LOG_LOCATION"))) {
                 if (log_show_location_from_string(e) < 0)
                         log_warning("Failed to parse bool %s. Ignoring.", e);
         }
commit 160cd5c9aa2301892e13950015de7968c764340d
Author: Lennart Poettering <lennart at poettering.net>
Date:   Thu Jun 24 00:11:04 2010 +0200

    man: add more man pages

diff --git a/Makefile.am b/Makefile.am
index e41ba48..b650dab 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -308,14 +308,18 @@ dist_man_MANS = \
 	man/systemd.unit.5 \
 	man/systemd.service.5 \
 	man/daemon.7 \
-	man/systemd.8 \
+	man/systemd.1 \
 	man/sd_notify.3 \
 	man/sd_booted.3 \
 	man/sd_listen_fds.3 \
 	man/sd_is_fifo.3 \
 	man/sd-daemon.7 \
 	man/runlevel.8 \
-	man/systemd-install.1
+	man/telinit.8 \
+	man/halt.8 \
+	man/shutdown.8 \
+	man/systemd-install.1 \
+	man/pam_systemd.8
 
 nodist_man_MANS = \
 	man/systemd.special.7
@@ -331,7 +335,11 @@ dist_noinst_DATA = \
 	man/sd_is_fifo.html \
 	man/sd-daemon.html \
 	man/runlevel.html \
-	man/systemd-install.html
+	man/telinit.html \
+	man/halt.html \
+	man/shutdown.html \
+	man/systemd-install.html \
+	man/pam_systemd.html
 
 nodist_noinst_DATA = \
 	man/systemd.special.html
@@ -350,7 +358,11 @@ EXTRA_DIST += \
 	man/sd_is_fifo.xml \
 	man/sd-daemon.xml \
 	man/runlevel.xml \
-	man/systemd-install.xml
+	man/telinit.xml \
+	man/halt.xml \
+	man/shutdown.xml \
+	man/systemd-install.xml \
+	man/pam_systemd.xml
 
 systemd_SOURCES = \
 	src/main.c
diff --git a/man/daemon.xml b/man/daemon.xml
index 3d1e921..650e0fa 100644
--- a/man/daemon.xml
+++ b/man/daemon.xml
@@ -306,11 +306,12 @@
 
 
         <refsect1>
-                  <title>See Also</title>
-                  <para>
-                          <citerefentry><refentrytitle>daemon</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
-                          <citerefentry><refentrytitle>sd_listen_fds</refentrytitle><manvolnum>3</manvolnum></citerefentry>
-                  </para>
+                <title>See Also</title>
+                <para>
+                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>daemon</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>sd_listen_fds</refentrytitle><manvolnum>3</manvolnum></citerefentry>
+                </para>
         </refsect1>
 
 </refentry>
diff --git a/man/halt.xml b/man/halt.xml
new file mode 100644
index 0000000..f07e04a
--- /dev/null
+++ b/man/halt.xml
@@ -0,0 +1,180 @@
+<?xml version='1.0'?> <!--*-nxml-*-->
+<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
+        "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
+
+<!--
+  This file is part of systemd.
+
+  Copyright 2010 Lennart Poettering
+
+  systemd is free software; you can redistribute it and/or modify it
+  under the terms of the GNU General Public License as published by
+  the Free Software Foundation; either version 2 of the License, or
+  (at your option) any later version.
+
+  systemd is distributed in the hope that it will be useful, but
+  WITHOUT ANY WARRANTY; without even the implied warranty of
+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  General Public License for more details.
+
+  You should have received a copy of the GNU General Public License
+  along with systemd; If not, see <http://www.gnu.org/licenses/>.
+-->
+
+<refentry id="halt">
+
+        <refentryinfo>
+                <title>halt</title>
+                <productname>systemd</productname>
+
+                <authorgroup>
+                        <author>
+                                <contrib>Developer</contrib>
+                                <firstname>Lennart</firstname>
+                                <surname>Poettering</surname>
+                                <email>lennart at poettering.net</email>
+                        </author>
+                </authorgroup>
+        </refentryinfo>
+
+        <refmeta>
+                <refentrytitle>halt</refentrytitle>
+                <manvolnum>8</manvolnum>
+        </refmeta>
+
+        <refnamediv>
+                <refname>halt</refname>
+                <refname>poweroff</refname>
+                <refname>reboot</refname>
+                <refpurpose>Halt, power-off or reboot the machine</refpurpose>
+        </refnamediv>
+
+        <refsynopsisdiv>
+                <cmdsynopsis>
+                        <command>halt <arg choice="opt" rep="repeat">OPTIONS</arg></command>
+                </cmdsynopsis>
+                <cmdsynopsis>
+                        <command>poweroff <arg choice="opt" rep="repeat">OPTIONS</arg></command>
+                </cmdsynopsis>
+                <cmdsynopsis>
+                        <command>reboot <arg choice="opt" rep="repeat">OPTIONS</arg></command>
+                </cmdsynopsis>
+        </refsynopsisdiv>
+
+        <refsect1>
+                <title>Description</title>
+
+                <para><command>halt</command>,
+                <command>poweroff</command>, <command>reboot</command>
+                may be used to halt, power-off or reboot the
+                machine.</para>
+
+        </refsect1>
+
+        <refsect1>
+                <title>Options</title>
+
+                <para>The following options are understood:</para>
+
+                <variablelist>
+                        <varlistentry>
+                                <term><option>--help</option></term>
+
+                                <listitem><para>Prints a short help
+                                text and exits.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>--halt</option></term>
+
+                                <listitem><para>Halt the machine,
+                                regardless which one of the three
+                                commands is invoked.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-p</option></term>
+                                <term><option>--poweroff</option></term>
+
+                                <listitem><para>Power-off the machine,
+                                regardless which one of the three
+                                commands is invoked.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>--reboot</option></term>
+
+                                <listitem><para>Reboot the machine,
+                                regardless which one of the three
+                                commands is invoked.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-f</option></term>
+                                <term><option>--force</option></term>
+
+                                <listitem><para>Force immediate halt,
+                                power-off, reboot. Don't contact the
+                                init system.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-w</option></term>
+                                <term><option>--wtmp-only</option></term>
+
+                                <listitem><para>Only write wtmp
+                                shutdown entry, don't actually halt,
+                                power-off, reboot.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-d</option></term>
+                                <term><option>--no-wtmp</option></term>
+
+                                <listitem><para>Don't write wtmp
+                                shutdown entry.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-n</option></term>
+                                <term><option>--no-sync</option></term>
+
+                                <listitem><para>Don't sync hard disks/storage media before
+                                halt, power-off,
+                                reboot.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>--no-wall</option></term>
+
+                                <listitem><para>Don't send wall
+                                message before
+                                halt, power-off, reboot.</para></listitem>
+                        </varlistentry>
+                </variablelist>
+        </refsect1>
+
+        <refsect1>
+                <title>Exit status</title>
+
+                <para>On success 0 is returned, a non-zero failure
+                code otherwise.</para>
+        </refsect1>
+
+        <refsect1>
+                <title>Notes</title>
+
+                <para>These are legacy commands available for
+                compatibility only.</para>
+        </refsect1>
+
+        <refsect1>
+                <title>See Also</title>
+                <para>
+                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>shutdown</refentrytitle><manvolnum>8</manvolnum></citerefentry>
+                </para>
+        </refsect1>
+
+</refentry>
diff --git a/man/pam_systemd.xml b/man/pam_systemd.xml
new file mode 100644
index 0000000..e790dd3
--- /dev/null
+++ b/man/pam_systemd.xml
@@ -0,0 +1,296 @@
+<?xml version='1.0'?> <!--*-nxml-*-->
+<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
+        "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
+
+<!--
+  This file is part of systemd.
+
+  Copyright 2010 Lennart Poettering
+
+  systemd is free software; you can redistribute it and/or modify it
+  under the terms of the GNU General Public License as published by
+  the Free Software Foundation; either version 2 of the License, or
+  (at your option) any later version.
+
+  systemd is distributed in the hope that it will be useful, but
+  WITHOUT ANY WARRANTY; without even the implied warranty of
+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  General Public License for more details.
+
+  You should have received a copy of the GNU General Public License
+  along with systemd; If not, see <http://www.gnu.org/licenses/>.
+-->
+
+<refentry id="pam_systemd">
+
+        <refentryinfo>
+                <title>pam_systemd</title>
+                <productname>systemd</productname>
+
+                <authorgroup>
+                        <author>
+                                <contrib>Developer</contrib>
+                                <firstname>Lennart</firstname>
+                                <surname>Poettering</surname>
+                                <email>lennart at poettering.net</email>
+                        </author>
+                </authorgroup>
+        </refentryinfo>
+
+        <refmeta>
+                <refentrytitle>pam_systemd</refentrytitle>
+                <manvolnum>8</manvolnum>
+        </refmeta>
+
+        <refnamediv>
+                <refname>pam_systemd</refname>
+                <refpurpose>Register user sessions in the systemd control group hierarchy</refpurpose>
+        </refnamediv>
+
+        <refsynopsisdiv>
+                <cmdsynopsis>
+                        <command>pam_systemd.so</command>
+                </cmdsynopsis>
+        </refsynopsisdiv>
+
+        <refsect1>
+                <title>Description</title>
+
+                <para><command>pam_systemd</command> registers user
+                sessions in the systemd control group
+                hierarchy.</para>
+
+                <para>On login, this module ensures the following:</para>
+
+                <orderedlist>
+                        <listitem><para>If it does not exist yet the
+                        user runtime directory
+                        <filename>/var/run/user/$USER</filename> is
+                        created and its ownership changed to the user
+                        that is logging in.</para></listitem>
+
+                        <listitem><para>If
+                        <option>create-session=1</option> is set the
+                        <varname>$XDG_SESSION_ID</varname> environment
+                        variable is initialized. If auditing is
+                        available and
+                        <command>pam_loginuid.so</command> run before
+                        this module (which es recommended), the
+                        variable is initialized from the auditing
+                        session id
+                        (<filename>/proc/self/sessionid</filename>). Otherwise
+                        an independent session counter is
+                        used.</para></listitem>
+
+                        <listitem><para>If
+                        <option>create-session=1</option> is set a new
+                        control group
+                        <filename>/user/$USER/$XDG_SESSION_ID</filename>
+                        is created and the login process moved into
+                        it.</para></listitem>
+
+                        <listitem><para>If
+                        <option>create-session=0</option> is set a new
+                        control group
+                        <filename>/user/$USER/no-session</filename>
+                        is created and the login process moved into
+                        it.</para></listitem>
+
+                </orderedlist>
+
+                <para>On logout, this module ensures the following:</para>
+
+                <orderedlist>
+                        <listitem><para>If
+                        <varname>$XDG_SESSION_ID</varname> is set and
+                        <option>kill-session=1</option> specified, all
+                        remaining processes in the
+                        <filename>/user/$USER/$XDG_SESSION_ID</filename>
+                        control group are killed and the control group
+                        removed.</para></listitem>
+
+                        <listitem><para>If
+                        <varname>$XDG_SESSION_ID</varname> is set and
+                        <option>kill-session=0</option> specified, all
+                        remaining processes in the
+                        <filename>/user/$USER/$XDG_SESSION_ID</filename>
+                        control group are migrated to
+                        <filename>/user/$USER/no-session</filename> and
+                        the original control group
+                        removed.</para></listitem>
+
+                        <listitem><para>If
+                        <option>kill-user=1</option> is specified, and
+                        no other user session control group remains
+                        except
+                        <filename>/user/$USER/no-session</filename>
+                        all remaining processes in the
+                        <filename>/user/$USER</filename> hierarchy
+                        are killed and the control group removed.</para></listitem>
+
+                        <listitem><para>If
+                        <option>kill-user=0</option> is specified, and
+                        no process remains in the
+                        <filename>/user/$USER</filename> hierarchy the
+                        control group is removed.</para></listitem>
+
+                        <listitem><para>If the
+                        <filename>/user/$USER</filename> control group
+                        was removed the
+                        <varname>$XDG_RUNTIME_DIR</varname> directory
+                        and all its contents are
+                        removed, too.</para></listitem>
+                </orderedlist>
+
+                <para>If the system was not booted up with systemd as
+                init system this module does nothing and immediately
+                returns PAM_SUCCESS.</para>
+
+        </refsect1>
+
+        <refsect1>
+                <title>Options</title>
+
+                <para>The following options are understood:</para>
+
+                <variablelist>
+                        <varlistentry>
+                                <term><option>create-session=</option></term>
+
+                                <listitem><para>Takes a boolean
+                                argument. If true, a new session is
+                                created: the
+                                <varname>$XDG_SESSION_ID</varname>
+                                environment variable is set and the
+                                login process moved to the
+                                <filename>/user/$USER/$XDG_SESSION_ID</filename>
+                                control group. It is recommended that
+                                all services that are directly created
+                                on the user's behalf set this
+                                option. Only for services that shall
+                                automatically be terminated when the
+                                user logs out completely otherwise,
+                                <varname>create-session=0</varname>
+                                should be set.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>kill-session=</option></term>
+
+                                <listitem><para>Takes a boolean
+                                argument. If true, all processes
+                                created by the user during his session
+                                and from his session will be
+                                terminated when he logs out from his
+                                session.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>kill-user=</option></term>
+
+                                <listitem><para>Takes a boolean
+                                argument. If true, all processes
+                                created by the user during his session
+                                and from his session will be
+                                terminated after he logged out
+                                completely. This is a weaker version
+                                of <option>kill-session=1</option> and is
+                                more friendly for users logged in more
+                                than once as their processes are
+                                terminated only on their complete
+                                logout.</para></listitem>
+                        </varlistentry>
+                </variablelist>
+
+                <para>Note that setting <varname>kill-user=1</varname>
+                or even <varname>kill-session=1</varname> will break
+                tools like
+                <citerefentry><refentrytitle>screen</refentrytitle><manvolnum>1</manvolnum></citerefentry>.</para>
+
+        </refsect1>
+
+        <refsect1>
+                <title>Module Types Provided</title>
+
+                <para>Only <option>session</option> is provided.</para>
+        </refsect1>
+
+        <refsect1>
+                <title>Environment</title>
+
+                <variablelist>
+                        <varlistentry>
+                                <term><varname>$XDG_SESSION_ID</varname></term>
+
+                                <listitem><para>A session identifier,
+                                suitable to be used in file names. The
+                                string itself should be considered
+                                opaque, although often it is just the
+                                audit session ID as reported by
+                                <filename>/proc/self/sessionid</filename>. Each
+                                ID will be assigned only once during
+                                machine uptime. It may hence be used
+                                to uniquely label files or other
+                                resources of this
+                                session.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><varname>$XDG_RUNTIME_DIR</varname></term>
+
+                                <listitem><para>Path to a user-private
+                                user-writable directory that is bound
+                                to the user login time on the
+                                machine. It is automatically created
+                                the first time a user logs in and
+                                removed on his final logout. If a user
+                                logs in twice at the same time, both
+                                sessions will see the same
+                                <varname>$XDG_RUNTIME_DIR</varname>
+                                and the same contents. If a user logs
+                                in once, then logs out again, and logs
+                                in again, the directory contents will
+                                have been lost in between, but
+                                applications should not rely on this
+                                behaviour and must be able to deal with
+                                stale files. To store session-private
+                                data in this directory the user should
+                                include the value of <varname>$XDG_SESSION_ID</varname>
+                                in the filename. This directory shall
+                                be used for runtime file system
+                                objects such as AF_UNIX sockets,
+                                FIFOs, PID files and similar. It is
+                                guaranteed that this directory is
+                                local and offers the greatest possible
+                                file system feature set the
+                                operating system
+                                provides.</para></listitem>
+                        </varlistentry>
+                </variablelist>
+        </refsect1>
+
+        <refsect1>
+                <title>Example</title>
+
+                <programlisting>#%PAM-1.0
+auth       required     pam_unix.so
+auth       required     pam_nologin.so
+account    required     pam_unix.so
+password   required     pam_unix.so
+session    required     pam_unix.so
+session    required     pam_loginuid.so
+session    required     pam_systemd.so create-session=1 kill-user=1</programlisting>
+        </refsect1>
+
+        <refsect1>
+                <title>See Also</title>
+                <para>
+                        <citerefentry><refentrytitle>pam.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>pam.d</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>pam</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>pam_loginuid</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>
+                </para>
+        </refsect1>
+
+</refentry>
diff --git a/man/runlevel.xml b/man/runlevel.xml
index 71b6e38..04959b1 100644
--- a/man/runlevel.xml
+++ b/man/runlevel.xml
@@ -21,7 +21,7 @@
   along with systemd; If not, see <http://www.gnu.org/licenses/>.
 -->
 
-<refentry id="systemd">
+<refentry id="runlevel">
 
         <refentryinfo>
                 <title>runlevel</title>
@@ -146,6 +146,7 @@
         <refsect1>
                 <title>See Also</title>
                 <para>
+                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>
                 </para>
         </refsect1>
diff --git a/man/sd-daemon.xml b/man/sd-daemon.xml
index 2acc021..da1e5b3 100644
--- a/man/sd-daemon.xml
+++ b/man/sd-daemon.xml
@@ -147,12 +147,12 @@
         <refsect1>
                 <title>See Also</title>
                 <para>
+                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>sd_listen_fds</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>sd_notify</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>sd_booted</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>sd_is_fifo</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>daemon</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
-                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>systemd.service</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>systemd.socket</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>fprintf</refentrytitle><manvolnum>3</manvolnum></citerefentry>
diff --git a/man/sd_booted.xml b/man/sd_booted.xml
index 6129a77..8d5606d 100644
--- a/man/sd_booted.xml
+++ b/man/sd_booted.xml
@@ -114,8 +114,8 @@
         <refsect1>
                 <title>See Also</title>
                 <para>
-                        <citerefentry><refentrytitle>sd_daemon</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
-                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>8</manvolnum></citerefentry>
+                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>sd_daemon</refentrytitle><manvolnum>7</manvolnum></citerefentry>
                 </para>
         </refsect1>
 
diff --git a/man/sd_is_fifo.xml b/man/sd_is_fifo.xml
index 2389546..f1f6d37 100644
--- a/man/sd_is_fifo.xml
+++ b/man/sd_is_fifo.xml
@@ -188,9 +188,9 @@
         <refsect1>
                 <title>See Also</title>
                 <para>
-                        <citerefentry><refentrytitle>sd_daemon</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>sd-daemon</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>sd_listen_fds</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
-                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>systemd.service</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>systemd.socket</refentrytitle><manvolnum>5</manvolnum></citerefentry>
         </para>
diff --git a/man/sd_listen_fds.xml b/man/sd_listen_fds.xml
index 10ea57c..4164a99 100644
--- a/man/sd_listen_fds.xml
+++ b/man/sd_listen_fds.xml
@@ -163,13 +163,13 @@
                 <title>See Also</title>
 
                 <para>
-                        <citerefentry><refentrytitle>sd_daemon</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>sd-daemon</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>sd_is_fifo</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>sd_is_socket</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>sd_is_socket_inet</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>sd_is_socket_unix</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>daemon</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
-                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>systemd.service</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>systemd.socket</refentrytitle><manvolnum>5</manvolnum></citerefentry>
                 </para>
diff --git a/man/sd_notify.xml b/man/sd_notify.xml
index 140e795..9d55ca4 100644
--- a/man/sd_notify.xml
+++ b/man/sd_notify.xml
@@ -267,9 +267,9 @@
         <refsect1>
                 <title>See Also</title>
                 <para>
+                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>sd_daemon</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>daemon</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
-                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>systemd.service</refentrytitle><manvolnum>5</manvolnum></citerefentry>
                 </para>
         </refsect1>
diff --git a/man/shutdown.xml b/man/shutdown.xml
new file mode 100644
index 0000000..bff6821
--- /dev/null
+++ b/man/shutdown.xml
@@ -0,0 +1,155 @@
+<?xml version='1.0'?> <!--*-nxml-*-->
+<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
+        "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
+
+<!--
+  This file is part of systemd.
+
+  Copyright 2010 Lennart Poettering
+
+  systemd is free software; you can redistribute it and/or modify it
+  under the terms of the GNU General Public License as published by
+  the Free Software Foundation; either version 2 of the License, or
+  (at your option) any later version.
+
+  systemd is distributed in the hope that it will be useful, but
+  WITHOUT ANY WARRANTY; without even the implied warranty of
+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  General Public License for more details.
+
+  You should have received a copy of the GNU General Public License
+  along with systemd; If not, see <http://www.gnu.org/licenses/>.
+-->
+
+<refentry id="shutdown">
+
+        <refentryinfo>
+                <title>shutdown</title>
+                <productname>systemd</productname>
+
+                <authorgroup>
+                        <author>
+                                <contrib>Developer</contrib>
+                                <firstname>Lennart</firstname>
+                                <surname>Poettering</surname>
+                                <email>lennart at poettering.net</email>
+                        </author>
+                </authorgroup>
+        </refentryinfo>
+
+        <refmeta>
+                <refentrytitle>shutdown</refentrytitle>
+                <manvolnum>8</manvolnum>
+        </refmeta>
+
+        <refnamediv>
+                <refname>shutdown</refname>
+                <refpurpose>Halt, power-off or reboot the machine</refpurpose>
+        </refnamediv>
+
+        <refsynopsisdiv>
+                <cmdsynopsis>
+                        <command>shutdown <arg choice="opt" rep="repeat">OPTIONS</arg> <arg choice="opt">now</arg> <arg choice="opt" rep="repeat">WALL</arg></command>
+                </cmdsynopsis>
+        </refsynopsisdiv>
+
+        <refsect1>
+                <title>Description</title>
+
+                <para><command>shutdown</command> may be used to halt,
+                power-off or reboot the machine.</para>
+
+                <para>The first argument should be the string
+                <command>now</command> which however is ignored by
+                this implementation. Optionally, this may be followed
+                by a wall message to be sent to all logged-in users
+                before going down.</para>
+        </refsect1>
+
+        <refsect1>
+                <title>Options</title>
+
+                <para>The following options are understood:</para>
+
+                <variablelist>
+                        <varlistentry>
+                                <term><option>--help</option></term>
+
+                                <listitem><para>Prints a short help
+                                text and exits.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-H</option></term>
+                                <term><option>--halt</option></term>
+
+                                <listitem><para>Halt the machine.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-P</option></term>
+                                <term><option>--poweroff</option></term>
+
+                                <listitem><para>Power-off the
+                                machine (the default).</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-r</option></term>
+                                <term><option>--reboot</option></term>
+
+                                <listitem><para>Reboot the
+                                machine.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>-h</option></term>
+
+                                <listitem><para>Equivalent to
+                                <option>--poweroff</option>, unless
+                                <option>--halt</option> is
+                                specified.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>--k</option></term>
+
+                                <listitem><para>Don't halt, power-off,
+                                reboot, just write wall
+                                message.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>--no-wall</option></term>
+
+                                <listitem><para>Don't send wall
+                                message before
+                                halt, power-off, reboot.</para></listitem>
+                        </varlistentry>
+                </variablelist>
+        </refsect1>
+
+        <refsect1>
+                <title>Exit status</title>
+
+                <para>On success 0 is returned, a non-zero failure
+                code otherwise.</para>
+        </refsect1>
+
+        <refsect1>
+                <title>Notes</title>
+
+                <para>This is a legacy command available for
+                compatibility only.</para>
+        </refsect1>
+
+        <refsect1>
+                <title>See Also</title>
+                <para>
+                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>halt</refentrytitle><manvolnum>8</manvolnum></citerefentry>
+                </para>
+        </refsect1>
+
+</refentry>
diff --git a/man/systemd-install.xml b/man/systemd-install.xml
index 7cd23da..bb52230 100644
--- a/man/systemd-install.xml
+++ b/man/systemd-install.xml
@@ -50,13 +50,13 @@
 
         <refsynopsisdiv>
                 <cmdsynopsis>
-                        <command>systemd-install <arg choice="opt" rep="repeat">options</arg> <arg choice="plain">enable</arg> <arg choice="opt" rep="repeat">name</arg></command>
+                        <command>systemd-install <arg choice="opt" rep="repeat">OPTIONS</arg> <arg choice="plain">enable</arg> <arg choice="opt" rep="repeat">NAME</arg></command>
                 </cmdsynopsis>
                 <cmdsynopsis>
-                        <command>systemd-install <arg choice="opt" rep="repeat">options</arg> <arg choice="plain">disable</arg> <arg choice="opt" rep="repeat">name</arg></command>
+                        <command>systemd-install <arg choice="opt" rep="repeat">OPTIONS</arg> <arg choice="plain">disable</arg> <arg choice="opt" rep="repeat">NAME</arg></command>
                 </cmdsynopsis>
                 <cmdsynopsis>
-                        <command>systemd-install <arg choice="opt" rep="repeat">options</arg> <arg choice="plain">test</arg> <arg choice="opt" rep="repeat">name</arg></command>
+                        <command>systemd-install <arg choice="opt" rep="repeat">OPTIONS</arg> <arg choice="plain">test</arg> <arg choice="opt" rep="repeat">NAME</arg></command>
                 </cmdsynopsis>
         </refsynopsisdiv>
 
@@ -116,7 +116,7 @@
                         </varlistentry>
                 </variablelist>
 
-                <para>The following verbs are understood:</para>
+                <para>The following commands are understood:</para>
 
                 <variablelist>
                         <varlistentry>
@@ -161,6 +161,7 @@
         <refsect1>
                 <title>See Also</title>
                 <para>
+                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
                         <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>
                 </para>
diff --git a/man/systemd.unit.xml b/man/systemd.unit.xml
index 73dde5a..7c2320e 100644
--- a/man/systemd.unit.xml
+++ b/man/systemd.unit.xml
@@ -104,19 +104,19 @@
         </refsect1>
 
         <refsect1>
-                  <title>See Also</title>
-                  <para>
-                          <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
-                          <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>8</manvolnum></citerefentry>
-                          <citerefentry><refentrytitle>systemd.special</refentrytitle><manvolnum>7</manvolnum></citerefentry>
-                          <citerefentry><refentrytitle>systemd.service</refentrytitle><manvolnum>5</manvolnum></citerefentry>
-                          <citerefentry><refentrytitle>systemd.socket</refentrytitle><manvolnum>5</manvolnum></citerefentry>
-                          <citerefentry><refentrytitle>systemd.device</refentrytitle><manvolnum>5</manvolnum></citerefentry>
-                          <citerefentry><refentrytitle>systemd.mount</refentrytitle><manvolnum>5</manvolnum></citerefentry>
-                          <citerefentry><refentrytitle>systemd.automount</refentrytitle><manvolnum>5</manvolnum></citerefentry>
-                          <citerefentry><refentrytitle>systemd.swap</refentrytitle><manvolnum>5</manvolnum></citerefentry>
-                          <citerefentry><refentrytitle>systemd.target</refentrytitle><manvolnum>5</manvolnum></citerefentry>
-                  </para>
+                <title>See Also</title>
+                <para>
+                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>8</manvolnum></citerefentry>
+                        <citerefentry><refentrytitle>systemd.special</refentrytitle><manvolnum>7</manvolnum></citerefentry>
+                        <citerefentry><refentrytitle>systemd.service</refentrytitle><manvolnum>5</manvolnum></citerefentry>
+                        <citerefentry><refentrytitle>systemd.socket</refentrytitle><manvolnum>5</manvolnum></citerefentry>
+                        <citerefentry><refentrytitle>systemd.device</refentrytitle><manvolnum>5</manvolnum></citerefentry>
+                        <citerefentry><refentrytitle>systemd.mount</refentrytitle><manvolnum>5</manvolnum></citerefentry>
+                        <citerefentry><refentrytitle>systemd.automount</refentrytitle><manvolnum>5</manvolnum></citerefentry>
+                        <citerefentry><refentrytitle>systemd.swap</refentrytitle><manvolnum>5</manvolnum></citerefentry>
+                        <citerefentry><refentrytitle>systemd.target</refentrytitle><manvolnum>5</manvolnum></citerefentry>
+                </para>
         </refsect1>
 
 </refentry>
diff --git a/man/systemd.xml b/man/systemd.xml
index 8766f04..f754348 100644
--- a/man/systemd.xml
+++ b/man/systemd.xml
@@ -39,7 +39,7 @@
 
         <refmeta>
                 <refentrytitle>systemd</refentrytitle>
-                <manvolnum>8</manvolnum>
+                <manvolnum>1</manvolnum>
         </refmeta>
 
         <refnamediv>
@@ -49,10 +49,10 @@
 
         <refsynopsisdiv>
                 <cmdsynopsis>
-                        <command>systemd <arg choice="opt" rep="repeat">options</arg></command>
+                        <command>systemd <arg choice="opt" rep="repeat">OPTIONS</arg></command>
                 </cmdsynopsis>
                 <cmdsynopsis>
-                        <command>init <arg choice="opt" rep="repeat">options</arg></command>
+                        <command>init <arg choice="opt" rep="repeat">OPTIONS</arg> <arg choice="req">COMMAND</arg></command>
                 </cmdsynopsis>
         </refsynopsisdiv>
 
@@ -81,7 +81,8 @@
 
                 <variablelist>
                         <varlistentry>
-                                <term><option>-h</option> | <option>--help</option></term>
+                                <term><option>-h</option></term>
+                                <term><option>--help</option></term>
 
                                 <listitem><para>Prints a short help
                                 text and exits.</para></listitem>
@@ -197,6 +198,28 @@
         </refsect1>
 
         <refsect1>
+                <title>Directories</title>
+        </refsect1>
+
+        <refsect1>
+                <title>Signal</title>
+
+                <variablelist>
+                        <varlistentry>
+                                <term><filename>SIGTERM</filename></term>
+
+                                <listitem><para>systemd serializes its
+                                state, reexecutes itself and
+                                deserializes the saved state
+                                again. This is mostly equivalent to
+                                <command>systemctl
+                                daemon-reexec</command>.</para></listitem>
+                        </varlistentry>
+                </variablelist>
+        </refsect1>
+
+
+        <refsect1>
                 <title>Sockets and FIFOs</title>
 
                 <variablelist>
diff --git a/man/telinit.xml b/man/telinit.xml
new file mode 100644
index 0000000..9251879
--- /dev/null
+++ b/man/telinit.xml
@@ -0,0 +1,194 @@
+<?xml version='1.0'?> <!--*-nxml-*-->
+<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
+        "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
+
+<!--
+  This file is part of systemd.
+
+  Copyright 2010 Lennart Poettering
+
+  systemd is free software; you can redistribute it and/or modify it
+  under the terms of the GNU General Public License as published by
+  the Free Software Foundation; either version 2 of the License, or
+  (at your option) any later version.
+
+  systemd is distributed in the hope that it will be useful, but
+  WITHOUT ANY WARRANTY; without even the implied warranty of
+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  General Public License for more details.
+
+  You should have received a copy of the GNU General Public License
+  along with systemd; If not, see <http://www.gnu.org/licenses/>.
+-->
+
+<refentry id="telinit">
+
+        <refentryinfo>
+                <title>telinit</title>
+                <productname>systemd</productname>
+
+                <authorgroup>
+                        <author>
+                                <contrib>Developer</contrib>
+                                <firstname>Lennart</firstname>
+                                <surname>Poettering</surname>
+                                <email>lennart at poettering.net</email>
+                        </author>
+                </authorgroup>
+        </refentryinfo>
+
+        <refmeta>
+                <refentrytitle>telinit</refentrytitle>
+                <manvolnum>8</manvolnum>
+        </refmeta>
+
+        <refnamediv>
+                <refname>telinit</refname>
+                <refpurpose>Change SysV runlevel</refpurpose>
+        </refnamediv>
+
+        <refsynopsisdiv>
+                <cmdsynopsis>
+                        <command>telinit <arg choice="opt" rep="repeat">OPTIONS</arg> <arg choice="req">COMMAND</arg></command>
+                </cmdsynopsis>
+        </refsynopsisdiv>
+
+        <refsect1>
+                <title>Description</title>
+
+                <para><command>telinit</command> may be used to change
+                the SysV system runlevel. Since the concept of SysV
+                runlevels is obsolete the runlevel requests
+                will be transparently translated into systemd unit
+                activation requests.</para>
+
+        </refsect1>
+
+        <refsect1>
+                <title>Options</title>
+
+                <para>The following options are understood:</para>
+
+                <variablelist>
+                        <varlistentry>
+                                <term><option>--help</option></term>
+
+                                <listitem><para>Prints a short help
+                                text and exits.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><option>--no-wall</option></term>
+
+                                <listitem><para>Don't send wall
+                                message before
+                                reboot/halt/power-off.</para></listitem>
+                        </varlistentry>
+                </variablelist>
+
+                <para>The following commands are understood:</para>
+
+                <variablelist>
+                        <varlistentry>
+                                <term><command>0</command></term>
+
+                                <listitem><para>Power-off the
+                                machine. This is translated into an
+                                activation request for
+                                <filename>poweroff.target</filename>
+                                and is equivalent to
+                                <command>systemctl
+                                poweroff</command>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><command>6</command></term>
+
+                                <listitem><para>Reboot the
+                                machine. This is translated into an
+                                activation request for
+                                <filename>reboot.target</filename> and
+                                is equivalent to <command>systemctl
+                                reboot</command>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><command>2</command></term>
+                                <term><command>3</command></term>
+                                <term><command>4</command></term>
+                                <term><command>5</command></term>
+
+                                <listitem><para>Change the SysV
+                                runlevel. This is translated into an
+                                activation request for
+                                <filename>runlevel2.target</filename>,
+                                <filename>runlevel3.target</filename>,
+                                ... and is equivalent to
+                                <command>systemctl start
+                                runlevel2.target</command>,
+                                <command>systemctl start
+                                runlevel3.target</command>,
+                                ...</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><command>1</command></term>
+                                <term><command>s</command></term>
+                                <term><command>S</command></term>
+
+                                <listitem><para>Change into system
+                                rescue mode. This is translated into
+                                an activation request for
+                                <filename>rescue.target</filename> and
+                                is equivalent to <command>systemctl
+                                rescue</command>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><command>q</command></term>
+                                <term><command>Q</command></term>
+
+                                <listitem><para>Reload daemon
+                                configuration. This is equivalent to
+                                <command>systemctl
+                                daemon-reload</command>.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><command>u</command></term>
+                                <term><command>U</command></term>
+
+                                <listitem><para>Serialize state,
+                                reexecute daemon and deserialize state
+                                again. This is equivalent to
+                                <command>systemctl
+                                daemon-reexec</command>.</para></listitem>
+                        </varlistentry>
+
+                </variablelist>
+        </refsect1>
+
+        <refsect1>
+                <title>Exit status</title>
+
+                <para>On success 0 is returned, a non-zero failure
+                code otherwise.</para>
+        </refsect1>
+
+        <refsect1>
+                <title>Notes</title>
+
+                <para>This is a legacy command available for compatibility
+                only. It should not be used anymore, as the concept of
+                runlevels is obsolete.</para>
+        </refsect1>
+
+        <refsect1>
+                <title>See Also</title>
+                <para>
+                        <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+                        <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>
+                </para>
+        </refsect1>
+
+</refentry>
commit daaa7e5a6595c02359adfafb7e19cf1a2e17fbd9
Author: Lennart Poettering <lennart at poettering.net>
Date:   Thu Jun 24 00:10:03 2010 +0200

    sd-daemon: refer to the man pages

diff --git a/src/sd-daemon.h b/src/sd-daemon.h
index 7797047..fd6221f 100644
--- a/src/sd-daemon.h
+++ b/src/sd-daemon.h
@@ -63,6 +63,8 @@ extern "C" {
 
   This should compile on non-Linux systems, too, but with the
   exception of the sd_is_xxx() calls all functions will become NOPs.
+
+  See sd-daemon(7) for more information.
 */
 
 #if __GNUC__ >= 4
@@ -104,6 +106,8 @@ extern "C" {
   sure they are not passed on to child processes. If FD_CLOEXEC shall
   not be set, the caller needs to unset it after this call for all file
   descriptors that are used.
+
+  See sd_listen_fds(3) for more information.
 */
 int sd_listen_fds(int unset_environment) _sd_hidden_;
 
@@ -114,6 +118,8 @@ int sd_listen_fds(int unset_environment) _sd_hidden_;
   not be done and the call only verifies if the file descriptor
   refers to a FIFO. Returns a negative errno style error code on
   failure.
+
+  See sd_is_fifo(3) for more information.
 */
 int sd_is_fifo(int fd, const char *path) _sd_hidden_;
 
@@ -128,6 +134,8 @@ int sd_is_fifo(int fd, const char *path) _sd_hidden_;
   been called) If listening is == 0 it is verified that the socket is
   not in listening mode. If listening is < 0 no listening mode check
   is done. Returns a negative errno style error code on failure.
+
+  See sd_is_socket(3) for more information.
 */
 int sd_is_socket(int fd, int family, int type, int listening) _sd_hidden_;
 
@@ -140,6 +148,8 @@ int sd_is_socket(int fd, int family, int type, int listening) _sd_hidden_;
   done. If port is 0 a socket port check will not be done. The
   listening flag is used the same way as in sd_is_socket(). Returns a
   negative errno style error code on failure.
+
+  See sd_is_socket_inet(3) for more information.
 */
 int sd_is_socket_inet(int fd, int family, int type, int listening, uint16_t port) _sd_hidden_;
 
@@ -154,6 +164,8 @@ int sd_is_socket_inet(int fd, int family, int type, int listening, uint16_t port
   socket path in path (including the initial 0 byte). The listening
   flag is used the same way as in sd_is_socket(). Returns a negative
   errno style error code on failure.
+
+  See sd_is_socket_unix(3) for more information.
 */
 int sd_is_socket_unix(int fd, int type, int listening, const char *path, size_t length) _sd_hidden_;
 
@@ -198,6 +210,8 @@ int sd_is_socket_unix(int fd, int type, int listening, const char *path, size_t
      sd_notify(0, "READY=1");
 
   See sd_notifyf() for more complete examples.
+
+  See sd_notify(3) for more information.
 */
 int sd_notify(int unset_environment, const char *state) _sd_hidden_;
 
@@ -218,6 +232,8 @@ int sd_notify(int unset_environment, const char *state) _sd_hidden_;
                    "ERRNO=%i",
                    strerror(errno),
                    errno);
+
+  See sd_notifyf(3) for more information.
 */
 int sd_notifyf(int unset_environment, const char *format, ...) _sd_printf_attr_(2,3) _sd_hidden_;
 
@@ -229,6 +245,8 @@ int sd_notifyf(int unset_environment, const char *format, ...) _sd_printf_attr_(
   note that this function checks whether the system, not the user
   session is controlled by systemd. However the functions above work
   for both session and system services.
+
+  See sd_booted(3) for more information.
 */
 int sd_booted(void) _sd_hidden_;
 
commit 2e225d657a9dd78cf647b754efa515cfd8c4db00
Author: Lennart Poettering <lennart at poettering.net>
Date:   Thu Jun 24 00:09:45 2010 +0200

    pam: make sure we don't assign colliding session ids if we get our session ids from multiple sources

diff --git a/src/pam-module.c b/src/pam-module.c
index 08de006..1834dd9 100644
--- a/src/pam-module.c
+++ b/src/pam-module.c
@@ -97,16 +97,30 @@ static int open_file_and_lock(const char *fn) {
         if ((fd = open(fn, O_RDWR|O_CLOEXEC|O_NOCTTY|O_NOFOLLOW|O_CREAT, 0600)) < 0)
                 return -errno;
 
+        /* The BSD socket semantics are a lot nicer than those of
+         * POSIX locks. Which is why we use flock() here. BSD locking
+         * does not work across NFS which however is not needed here
+         * as the filesystems in question should be local, and only
+         * locally accessible, and most likely even tmpfs. */
+
         if (flock(fd, LOCK_EX) < 0)
                 return -errno;
 
         return fd;
 }
 
-static uint64_t get_session_id(void) {
+enum {
+        SESSION_ID_AUDIT = 'a',
+        SESSION_ID_COUNTER = 'c',
+        SESSION_ID_RANDOM = 'r'
+};
+
+static uint64_t get_session_id(int *mode) {
         char *s;
         int fd;
 
+        assert(mode);
+
         /* First attempt: let's use the session ID of the audit
          * system, if it is available. */
         if (read_one_line_file("/proc/self/sessionid", &s) >= 0) {
@@ -116,8 +130,10 @@ static uint64_t get_session_id(void) {
                 r = safe_atou32(s, &u);
                 free(s);
 
-                if (r >= 0 && u != (uint32_t) -1)
+                if (r >= 0 && u != (uint32_t) -1) {
+                        *mode = SESSION_ID_AUDIT;
                         return (uint64_t) u;
+                }
         }
 
         /* Second attempt, use our own counter. */
@@ -149,10 +165,14 @@ static uint64_t get_session_id(void) {
 
                 close_nointr_nofail(fd);
 
-                if (r >= 0)
+                if (r >= 0) {
+                        *mode = SESSION_ID_COUNTER;
                         return counter;
+                }
         }
 
+        *mode = SESSION_ID_RANDOM;
+
         /* Last attempt, pick a random value */
         return (uint64_t) random_ull();
 }
@@ -283,12 +303,21 @@ _public_ PAM_EXTERN int pam_sm_open_session(
 
                 /* Reuse or create XDG session ID */
                 if (!(id = pam_getenv(handle, "XDG_SESSION_ID"))) {
+                        int mode;
 
-                        if (asprintf(&buf, "%llu", (unsigned long long) get_session_id()) < 0) {
+                        if (asprintf(&buf, "%llux", (unsigned long long) get_session_id(&mode)) < 0) {
                                 r = PAM_BUF_ERR;
                                 goto finish;
                         }
 
+                        /* To avoid id clashes we add the session id
+                         * source to our session ids. Note that the
+                         * session id source might change during
+                         * runtime, because a filesystem became
+                         * writable or the system reconfigured. */
+                        buf[strlen(buf)-1] =
+                                mode != SESSION_ID_AUDIT ? (char) mode : 0;
+
                         if ((r = pam_misc_setenv(handle, "XDG_SESSION_ID", buf, 0)) != PAM_SUCCESS) {
                                 pam_syslog(handle, LOG_ERR, "Failed to set session id.");
                                 goto finish;
commit 2e33c4331f9f1169645e4b2e9c7c8861454f6b51
Author: Lennart Poettering <lennart at poettering.net>
Date:   Thu Jun 24 00:08:42 2010 +0200

    minor fixes to help texts

diff --git a/src/install.c b/src/install.c
index e59e108..0c9f086 100644
--- a/src/install.c
+++ b/src/install.c
@@ -59,13 +59,13 @@ Hashmap *will_install = NULL, *have_installed = NULL;
 
 static int help(void) {
 
-        printf("%s [options]\n\n"
+        printf("%s [OPTIONS...] {COMMAND} ...\n\n"
                "Install init system units.\n\n"
                "  -h --help        Show this help\n"
                "     --force       Override existing links\n"
                "     --system      Install into system\n"
                "     --session     Install into session\n"
-               "     --global      Install into all sessions\n"
+               "     --global      Install into all sessions\n\n"
                "Commands:\n"
                "  enable [NAME...]    Enable one or more units\n"
                "  disable [NAME...]   Disable one or more units\n"
diff --git a/src/main.c b/src/main.c
index a002e11..799184e 100644
--- a/src/main.c
+++ b/src/main.c
@@ -536,7 +536,7 @@ static int parse_argv(int argc, char *argv[]) {
 
 static int help(void) {
 
-        printf("%s [options]\n\n"
+        printf("%s [OPTIONS...]\n\n"
                "Starts up and maintains the system or a session.\n\n"
                "  -h --help                      Show this help\n"
                "     --unit=UNIT                 Set default unit\n"
diff --git a/src/notify.c b/src/notify.c
index 7797810..6dd708a 100644
--- a/src/notify.c
+++ b/src/notify.c
@@ -39,7 +39,7 @@ static bool arg_booted = false;
 
 static int help(void) {
 
-        printf("%s [options] [VARIABLE=VALUE...]\n\n"
+        printf("%s [OPTIONS...] [VARIABLE=VALUE...]\n\n"
                "Notify the init system about service status updates.\n\n"
                "  -h --help         Show this help\n"
                "     --ready        Inform the init system about service start-up completion\n"
diff --git a/src/systemctl.c b/src/systemctl.c
index 2efc856..321e269 100644
--- a/src/systemctl.c
+++ b/src/systemctl.c
@@ -1428,7 +1428,7 @@ finish:
 
 static int systemctl_help(void) {
 
-        printf("%s [options]\n\n"
+        printf("%s [OPTIONS...] {COMMAND} ...\n\n"
                "Send control commands to the init daemon.\n\n"
                "  -h --help      Show this help\n"
                "  -t --type=TYPE List only units of a particular type\n"
@@ -1437,7 +1437,7 @@ static int systemctl_help(void) {
                "     --system    Connect to system bus\n"
                "     --session   Connect to session bus\n"
                "     --block     Wait until operation finished\n"
-               "     --no-wall   Don't send wall message before reboot/halt/power-off\n\n"
+               "     --no-wall   Don't send wall message before halt/power-off/reboot\n\n"
                "Commands:\n"
                "  list-units                      List units\n"
                "  list-jobs                       List jobs\n"
@@ -1459,8 +1459,8 @@ static int systemctl_help(void) {
                "  set-environment [NAME=VALUE...] Set one or more environment variables\n"
                "  unset-environment [NAME...]     Unset one or more environment variables\n"
                "  halt                            Shut down and halt the system\n"
+               "  poweroff                        Shut down and power-off the system\n"
                "  reboot                          Shut down and reboot the system\n"
-               "  poweroff                        Shut down and power off the system\n"
                "  default                         Enter default mode\n"
                "  rescue                          Enter rescue mode\n"
                "  emergency                       Enter emergency mode\n",
@@ -1471,17 +1471,17 @@ static int systemctl_help(void) {
 
 static int halt_help(void) {
 
-        printf("%s [options]\n\n"
+        printf("%s [OPTIONS...]\n\n"
                "%s the system.\n\n"
                "     --help      Show this help\n"
                "     --halt      Halt the machine\n"
                "  -p --poweroff  Switch off the machine\n"
                "     --reboot    Reboot the machine\n"
-               "  -f --force     Force immediate reboot/halt/power-off\n"
-               "  -w --wtmp-only Don't reboot/halt/power-off, just write wtmp record\n"
+               "  -f --force     Force immediate halt/power-off/reboot\n"
+               "  -w --wtmp-only Don't halt/power-off/reboot, just write wtmp record\n"
                "  -d --no-wtmp   Don't write wtmp record\n"
-               "  -n --no-sync   Don't sync before reboot/halt/power-off\n"
-               "     --no-wall   Don't send wall message before reboot/halt/power-off\n",
+               "  -n --no-sync   Don't sync before halt/power-off/reboot\n"
+               "     --no-wall   Don't send wall message before halt/power-off/reboot\n",
                program_invocation_short_name,
                arg_action == ACTION_REBOOT   ? "Reboot" :
                arg_action == ACTION_POWEROFF ? "Power off" :
@@ -1492,15 +1492,15 @@ static int halt_help(void) {
 
 static int shutdown_help(void) {
 
-        printf("%s [options] [now] [WALL...]\n\n"
+        printf("%s [OPTIONS...] [now] [WALL...]\n\n"
                "Shut down the system.\n\n"
                "     --help      Show this help\n"
                "  -H --halt      Halt the machine\n"
                "  -P --poweroff  Power-off the machine\n"
                "  -r --reboot    Reboot the machine\n"
                "  -h             Equivalent to --poweroff, overriden by --halt\n"
-               "  -k             Don't reboot/halt/power-off, just send warnings\n"
-               "     --no-wall   Don't send wall message before reboot/halt/power-off\n",
+               "  -k             Don't halt/power-off/reboot, just send warnings\n"
+               "     --no-wall   Don't send wall message before halt/power-off/reboot\n",
                program_invocation_short_name);
 
         return 0;
@@ -1508,10 +1508,10 @@ static int shutdown_help(void) {
 
 static int telinit_help(void) {
 
-        printf("%s [options]\n\n"
+        printf("%s [OPTIONS...] {COMMAND}\n\n"
                "Send control commands to the init daemon.\n\n"
                "     --help      Show this help\n"
-               "     --no-wall   Don't send wall message before reboot/halt/power-off\n\n"
+               "     --no-wall   Don't send wall message before halt/power-off/reboot\n\n"
                "Commands:\n"
                "  0              Power-off the machine\n"
                "  6              Reboot the machine\n"
@@ -1526,7 +1526,7 @@ static int telinit_help(void) {
 
 static int runlevel_help(void) {
 
-        printf("%s [options]\n\n"
+        printf("%s [OPTIONS...]\n\n"
                "Prints the previous and current runlevel of the init system.\n\n"
                "     --help      Show this help\n",
                program_invocation_short_name);
commit 2218198b73ea3f73cee1238e0f6dfd313f182f48
Author: Lennart Poettering <lennart at poettering.net>
Date:   Wed Jun 23 20:34:25 2010 +0200

    man: start documenting systemd itself

diff --git a/man/runlevel.xml b/man/runlevel.xml
index 7daffbf..71b6e38 100644
--- a/man/runlevel.xml
+++ b/man/runlevel.xml
@@ -67,12 +67,16 @@
                 <para>Unless overriden in the environment this will
                 check the utmp database for recent runlevel
                 changes.</para>
+        </refsect1>
+
+        <refsect1>
+                <title>Options</title>
 
                 <para>The following option is understood:</para>
 
                 <variablelist>
                         <varlistentry>
-                                <term>--help</term>
+                                <term><option>--help</option></term>
 
                                 <listitem><para>Prints a short help
                                 text and exits.</para></listitem>
diff --git a/man/systemd-install.xml b/man/systemd-install.xml
index 9881e98..7cd23da 100644
--- a/man/systemd-install.xml
+++ b/man/systemd-install.xml
@@ -21,7 +21,7 @@
   along with systemd; If not, see <http://www.gnu.org/licenses/>.
 -->
 
-<refentry id="systemd">
+<refentry id="systemd-install">
 
         <refentryinfo>
                 <title>systemd-install</title>
@@ -50,13 +50,13 @@
 
         <refsynopsisdiv>
                 <cmdsynopsis>
-                        <command>systemd-install <arg choice="opt" rep="repeat">options</arg> <option>enable</option> <arg choice="opt" rep="repeat">name</arg></command>
+                        <command>systemd-install <arg choice="opt" rep="repeat">options</arg> <arg choice="plain">enable</arg> <arg choice="opt" rep="repeat">name</arg></command>
                 </cmdsynopsis>
                 <cmdsynopsis>
-                        <command>systemd-install <arg choice="opt" rep="repeat">options</arg> <option>disable</option> <arg choice="opt" rep="repeat">name</arg></command>
+                        <command>systemd-install <arg choice="opt" rep="repeat">options</arg> <arg choice="plain">disable</arg> <arg choice="opt" rep="repeat">name</arg></command>
                 </cmdsynopsis>
                 <cmdsynopsis>
-                        <command>systemd-install <arg choice="opt" rep="repeat">options</arg> <option>test</option> <arg choice="opt" rep="repeat">name</arg></command>
+                        <command>systemd-install <arg choice="opt" rep="repeat">options</arg> <arg choice="plain">test</arg> <arg choice="opt" rep="repeat">name</arg></command>
                 </cmdsynopsis>
         </refsynopsisdiv>
 
@@ -66,19 +66,23 @@
                 <para><command>systemd-install</command> enables or
                 disables systemd units, or checks whether they are
                 enabled.</para>
+        </refsect1>
+
+        <refsect1>
+                <title>Options</title>
 
                 <para>The following options are understood:</para>
 
                 <variablelist>
                         <varlistentry>
-                                <term>--help</term>
+                                <term><option>--help</option></term>
 
                                 <listitem><para>Prints a short help
                                 text and exits.</para></listitem>
                         </varlistentry>
 
                         <varlistentry>
-                                <term>--force</term>
+                                <term><option>--force</option></term>
 
                                 <listitem><para>Enable/disable a
                                 service even if it conflicts
@@ -89,14 +93,14 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term>--system</term>
+                                <term><option>--system</option></term>
 
                                 <listitem><para>Enable/disable a
                                 system service.</para></listitem>
                         </varlistentry>
 
                         <varlistentry>
-                                <term>--session</term>
+                                <term><option>--session</option></term>
 
                                 <listitem><para>Enable/disable a
                                 session service for the calling
@@ -104,7 +108,7 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term>--global</term>
+                                <term><option>--global</option></term>
 
                                 <listitem><para>Enable/disable a
                                 session service for all
@@ -116,7 +120,7 @@
 
                 <variablelist>
                         <varlistentry>
-                                <term>enable</term>
+                                <term><command>enable</command></term>
 
                                 <listitem><para>Enable a unit. This
                                 will create a number of symlinks as
@@ -125,7 +129,7 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term>disable</term>
+                                <term><command>disable</command></term>
 
                                 <listitem><para>Disable a unit. This
                                 will removed a number of symlinks as
@@ -134,7 +138,7 @@
                         </varlistentry>
 
                         <varlistentry>
-                                <term>test</term>
+                                <term><command>test</command></term>
 
                                 <listitem><para>Checks whether any of
                                 the units specified are
diff --git a/man/systemd.xml b/man/systemd.xml
index f49faca..8766f04 100644
--- a/man/systemd.xml
+++ b/man/systemd.xml
@@ -47,10 +47,212 @@
                 <refpurpose>systemd System and Session Manager</refpurpose>
         </refnamediv>
 
+        <refsynopsisdiv>
+                <cmdsynopsis>
+                        <command>systemd <arg choice="opt" rep="repeat">options</arg></command>
+                </cmdsynopsis>
+                <cmdsynopsis>
+                        <command>init <arg choice="opt" rep="repeat">options</arg></command>
+                </cmdsynopsis>
+        </refsynopsisdiv>
+
         <refsect1>
                 <title>Description</title>
 
-                <para>Systemd is awesome.</para>
+                <para>systemd is a system and session manager for
+                Linux operating systems. When run as first process on
+                boot (as PID 1) it may act as init system that brings
+                up and maintains userspace.</para>
+
+                <para>For compatibility with SysV if systemd is called
+                as <command>init</command> and a PID that is not
+                1 it will execute <command>telinit</command> and pass
+                all command line arguments unmodified. That means
+                <command>init</command> and <command>telinit</command>
+                are mostly equivalent when invoked from normal login sessions. See
+                <citerefentry><refentrytitle>telinit</refentrytitle><manvolnum>8</manvolnum></citerefentry>
+                for more information.</para>
+        </refsect1>
+
+        <refsect1>
+                <title>Options</title>
+
+                <para>The following options are understood:</para>
+
+                <variablelist>
+                        <varlistentry>
+                                <term><option>-h</option> | <option>--help</option></term>
+
+                                <listitem><para>Prints a short help
+                                text and exits.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><option>--unit=</option></term>
+
+                                <listitem><para>Set default unit to
+                                activate on startup. If not specified
+                                defaults to
+                                <filename>default.target</filename>.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><option>--running-as=</option></term>
+
+                                <listitem><para>Tell systemd to run in
+                                a particular mode. Argument is one of
+                                <option>system</option>,
+                                <option>session</option>. Normally it
+                                should not be necessary to pass this
+                                option, as systemd automatically
+                                detects the mode it is started
+                                in. This call is hence of little use
+                                except for
+                                debugging.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><option>--test</option></term>
+
+                                <listitem><para>Determine startup
+                                sequence, dump it and exit. This is an
+                                option useful for debugging
+                                only.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><option>--dump-configuration-items</option></term>
+
+                                <listitem><para>Dump understood unit
+                                configuration items. This outputs a
+                                terse list of configuration items
+                                understood in unit definition
+                                files.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><option>--confirm-spawn</option></term>
+
+                                <listitem><para>Ask for confirmation when spawning processes.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><option>--introspect=</option></term>
+
+                                <listitem><para>Extract D-Bus
+                                interface introspection data. This is
+                                mostly useful at build ot install time
+                                to generate data suitable for the
+                                D-Bus interfaces
+                                repository. Optionally the interface
+                                name for the introspection data may be
+                                specified. If omitted the
+                                introspection data for all interfaces
+                                is dumped.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><option>--log-level=</option></term>
+
+                                <listitem><para>Set log level. As
+                                argument this accepts a numerical log
+                                level or the well-known <citerefentry><refentrytitle>syslog</refentrytitle><manvolnum>3</manvolnum></citerefentry>
+                                symbolic names (lowercase):
+                                <option>emerg</option>,
+                                <option>alert</option>,
+                                <option>crit</option>,
+                                <option>err</option>,
+                                <option>warning</option>,
+                                <option>notice</option>,
+                                <option>info</option>,
+                                <option>debug</option>.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><option>--log-target=</option></term>
+
+                                <listitem><para>Set log
+                                target. Argument must be one of
+                                <option>console</option>,
+                                <option>syslog</option>,
+                                <option>kmsg</option>,
+                                <option>syslog-or-kmsg</option>,
+                                <option>null</option>.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><option>--log-color=</option></term>
+
+                                <listitem><para>Highlight important
+                                log messages. Argument is a boolean
+                                value. If the argument is omitted it
+                                defaults to
+                                <option>true</option>.</para></listitem>
+                        </varlistentry>
+                        <varlistentry>
+                                <term><option>--log-location=</option></term>
+
+                                <listitem><para>Include code location
+                                in log messages. This is mostly
+                                relevant for debugging
+                                purposes. Argument is a boolean
+                                value. If the argument is omitted
+                                it defaults to
+                                <option>true</option>.</para></listitem>
+                        </varlistentry>
+
+
+                </variablelist>
+        </refsect1>
+
+        <refsect1>
+                <title>Sockets and FIFOs</title>
+
+                <variablelist>
+                        <varlistentry>
+                                <term><filename>@/org/freedesktop/systemd1/notify</filename></term>
+
+                                <listitem><para>Daemon status
+                                notification socket. This is an AF_UNIX
+                                datagram socket in the Linux abstract
+                                namespace, and is used to implement
+                                the daemon notification logic as
+                                implemented by
+                                <citerefentry><refentrytitle>sd_notify</refentrytitle><manvolnum>3</manvolnum></citerefentry>.</para></listitem>
+
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><filename>@/org/freedesktop/systemd1/logger</filename></term>
+
+                                <listitem><para>Used internally by the
+                                <filename>systemd-logger.service</filename>
+                                unit to connect STDOUT and/or STDERR
+                                of spawned processes to
+                                <citerefentry><refentrytitle>syslog</refentrytitle><manvolnum>3</manvolnum></citerefentry>
+                                or the kernel log buffer. This is an
+                                AF_UNIX stream socket in the Linux
+                                abstract namespace.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><filename>@/org/freedesktop/systemd1/private</filename></term>
+
+                                <listitem><para>Used internally as
+                                communication channel between
+                                <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>
+                                and the systemd process. This is an
+                                AF_UNIX stream socket in the Linux
+                                abstract namespace. This interface is
+                                private to systemd and should not be
+                                used in external
+                                projects.</para></listitem>
+                        </varlistentry>
+
+                        <varlistentry>
+                                <term><filename>/dev/initctl</filename></term>
+
+                                <listitem><para>Limited compatibility
+                                support for the SysV client interface,
+                                as implemented by the
+                                <filename>systemd-initctl.service</filename>
+                                unit. This is a named pipe in the file
+                                system. This interface is obsolete and
+                                should not be used in new
+                                applications.</para></listitem>
+                        </varlistentry>
+                </variablelist>
         </refsect1>
 
 
diff --git a/src/main.c b/src/main.c
index db2a767..a002e11 100644
--- a/src/main.c
+++ b/src/main.c
@@ -547,7 +547,7 @@ static int help(void) {
                "     --introspect[=INTERFACE]    Extract D-Bus interface data\n"
                "     --log-level=LEVEL           Set log level\n"
                "     --log-target=TARGET         Set log target (console, syslog, kmsg, syslog-or-kmsg, null)\n"
-               "     --log-color[=0|1]           Highlight import log messages\n"
+               "     --log-color[=0|1]           Highlight important log messages\n"
                "     --log-location[=0|1]        Include code location in log messages\n",
                program_invocation_short_name);
 


More information about the systemd-commits mailing list