source: BOOK/final-system/common/systemd.xml @ 8f94b08

clfs-3.0.0-systemdclfs-3.0.0-sysvinitsystemdsysvinit
Last change on this file since 8f94b08 was c8a83d8, checked in by Chris Staub <chris@…>, 10 years ago

More installed files updates

  • Property mode set to 100644
File size: 11.5 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3  "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4  <!ENTITY % general-entities SYSTEM "../../general.ent">
5  %general-entities;
6]>
7<sect1 id="ch-system-systemd" role="wrap">
8  <?dbhtml filename="systemd.html"?>
9
10  <title>Systemd-&systemd-version;</title>
11
12  <indexterm zone="ch-system-systemd">
13    <primary sortas="a-systemd">Systemd</primary>
14  </indexterm>
15
16  <sect2 role="package">
17    <title/>
18
19    <para>The Systemd package is a system and service manager for Linux
20    operating systems.</para>
21
22  </sect2>
23
24  <sect2 role="installation">
25    <title>Installation of systemd</title>
26
27    <para os="p1">Apply a patch so that compat <command>pkg-config</command>
28    files get installed without installing compat libraries:</para>
29
30<screen os="p2"><userinput>patch -Np1 -i ../&systemd-compat-patch;</userinput></screen>
31
32    <para os="a">Prepare Systemd for compilation:</para>
33
34<screen os="b"><userinput>./configure --prefix=/usr \
35    --sysconfdir=/etc --localstatedir=/var \
36    --libexecdir=/usr/lib --docdir=/usr/share/doc/systemd-&systemd-version; \
37    --with-rootprefix="" --with-rootlibdir=/lib \
38    --enable-split-usr --disable-gudev --with-kbd-loadkeys=/bin/loadkeys \
39    --with-kbd-setfont=/bin/setfont --with-dbuspolicydir=/etc/dbus-1/system.d \
40    --with-dbusinterfacedir=/usr/share/dbus-1/interfaces \
41    --with-dbussessionservicedir=/usr/share/dbus-1/services \
42    --with-dbussystemservicedir=/usr/share/dbus-1/system-services</userinput></screen>
43
44    <variablelist os="c">
45      <title>The meaning of the configure options:</title>
46
47      <varlistentry>
48        <term><parameter>--with-root*</parameter></term>
49        <listitem>
50          <para>These switches ensure that core programs and
51          shared libraries are installed in the subdirectories
52          of the root partition.</para>
53        </listitem>
54      </varlistentry>
55
56      <varlistentry>
57        <term><parameter>--enable-split-usr</parameter></term>
58        <listitem>
59          <para>This switch ensures that Systemd will work on
60          systems where /bin, /lib and /sbin directories are not
61          symlinks to their /usr counterparts.</para>
62        </listitem>
63      </varlistentry>
64
65      <varlistentry>
66        <term><parameter>--disable-gudev --without-python</parameter></term>
67        <listitem>
68          <para>These switches disable optional features because
69          LFS does not provide their dependencies.</para>
70        </listitem>
71      </varlistentry>
72
73      <varlistentry>
74        <term><parameter>--with-dbus*</parameter></term>
75        <listitem>
76          <para>These switches ensure that D-Bus configuration files get
77          installed to the correct locations.</para>
78        </listitem>
79      </varlistentry>
80    </variablelist>
81
82    <para os="d">Compile the package:</para>
83
84<screen os="e"><userinput>make</userinput></screen>
85
86    <para os="f">Prevent a broken test case from running:</para>
87
88<screen os="g"><userinput remap="test">
89sed -e "s:test/udev-test.pl::g" \
90    -e "s:test-bus-cleanup\$(EXEEXT) ::g" \
91    -e "s:test-bus-gvariant\$(EXEEXT) ::g" \
92    -i Makefile</userinput></screen>
93
94    <para os="h">Test the results, issue:</para>
95
96<screen os="i"><userinput remap="test">make check</userinput></screen>
97
98    <para os="j">Install the package:</para>
99
100<screen os="k"><userinput>make install</userinput></screen>
101
102    <para os="l">Install man pages and documentation files that are not
103    installed by default:</para>
104
105<screen os="m"><userinput>for section in 1 3 5 7 8
106do
107  install -v -m644 man/*.${section} /usr/share/man/man${section}
108done
109install -v -m644 man/*.html /usr/share/doc/systemd-&systemd-version;</userinput></screen>
110
111    <para os="n">Move NSS myhostname library to <filename class="directory">/lib
112</filename>:</para>
113
114<screen os="o"><userinput>mv -v /usr/lib/libnss_myhostname.so.2 /lib</userinput></screen>
115
116    <para os="p">Remove an unnecessary directory:</para>
117
118<screen os="q"><userinput>rm -rfv /usr/lib/rpm</userinput></screen>
119
120    <para os="r">Create symlinks for backwards-compatibility with Sysvinit:</para>
121
122<screen os="s"><userinput>for tool in runlevel reboot shutdown poweroff halt telinit; do
123  ln -sfv ../bin/systemctl /sbin/$tool
124done
125ln -sfv ../lib/systemd/systemd /sbin/init</userinput></screen>
126
127    <para os="t">Modify a configuration file which references a group that
128    doesn't exist:</para>
129
130<screen os="u"><userinput>sed -i "s@root lock@root root@g" /usr/lib/tmpfiles.d/legacy.conf</userinput></screen>
131
132  </sect2>
133
134  <sect2 id="conf-systemd" role="configuration">
135    <title>Configuring Systemd</title>
136
137    <indexterm zone="conf-systemd">
138      <primary sortas="a-systemd">systemd</primary>
139    <secondary>configuring</secondary></indexterm>
140
141    <indexterm zone="conf-systemd">
142      <primary sortas="e-/etc/os-release">/etc/os-release</primary>
143    </indexterm>
144
145    <para>Create <filename>/etc/machine-id</filename> which is needed
146    by Journald:</para>
147
148<screen><userinput>systemd-machine-id-setup</userinput></screen>
149
150    <para>Create a file to identify the operating system.
151    <command>systemd</command> will use this file on boot to put information
152    on the screen.</para>
153
154<screen><userinput>cat &gt; /etc/os-release &lt;&lt; "EOF"
155# Begin /etc/os-release
156
157NAME=Cross-LFS
158ID=clfs
159
160PRETTY_NAME=Cross Linux From Scratch
161ANSI_COLOR=0;33
162
163VERSION=&version;
164VERSION_ID=&versionid;
165
166# End /etc/os-release
167EOF</userinput></screen>
168
169  </sect2>
170
171  <sect2 id="contents-systemd" role="content">
172    <title>Contents of Systemd</title>
173
174    <segmentedlist>
175      <segtitle>Installed programs</segtitle>
176      <segtitle>Installed libraries</segtitle>
177      <segtitle>Installed directories</segtitle>
178
179      <seglistitem>
180        <seg>bootctl, busctl, halt (link to systemctl), hostnamectl,
181        init (link to systemd), journalctl, kernel-install, localectl, loginctl,
182        machinectl, poweroff (link to systemctl), reboot (link to systemctl),
183        runlevel (link to systemctl), shutdown (link to systemctl),
184        systemctl, system-analyze, systemd-ask-password, systemd-cat,
185        systemd-cgls, systemd-cgtop, systemd-coredumpctl, systemd-delta,
186        systemd-detect-virt, systemd-inhibit, systemd-machine-id-setup,
187        systemd-notify, systemd-nspawn, systemd-run, systemd-stdio-bridge
188        (link to systemd-bus-proxyd), systemd-tmpfiles,
189        systemd-tty-ask-password-agent, telinit (link to systemctl),
190        timedatectl, udevadm</seg>
191        <seg>libnss_myhostname.so, libsystemd.so, libudev.so</seg>
192        <seg>/etc/binfmt.d, /etc/init.d, /etc/kernel, /etc/modules-load.d,
193        /etc/sysctl.d, /etc/systemd, /etc/tmpfiles.d, /etc/udev,
194        /etc/xdg/systemd, /lib/systemd, /lib/udev, /usr/include/systemd,
195        /usr/lib/binfmt.d, /usr/lib/kernel, /usr/lib/modules-load.d,
196        /usr/lib/sysctl.d, /usr/lib/systemd,
197        /usr/share/doc-systemd-&systemd-version;, /usr/share/systemd,
198        /var/lib/systemd</seg>
199      </seglistitem>
200    </segmentedlist>
201
202    <variablelist>
203      <bridgehead renderas="sect3">Short Descriptions</bridgehead>
204      <?dbfo list-presentation="list"?>
205      <?dbhtml list-presentation="table"?>
206
207      <varlistentry id="systemctl">
208        <term><command>systemctl</command></term>
209        <listitem>
210          <para>Control the Systemd system and service manager</para>
211          <indexterm zone="ch-system-systemd systemctl">
212            <primary sortas="b-systemctl">systemctl</primary>
213          </indexterm>
214        </listitem>
215      </varlistentry>
216
217      <varlistentry id="systemd">
218        <term><command>systemd</command></term>
219        <listitem>
220          <para>System and service manager for Linux</para>
221          <indexterm zone="ch-system-systemd systemd">
222            <primary sortas="b-systemd">systemd</primary>
223          </indexterm>
224        </listitem>
225      </varlistentry>
226
227      <varlistentry id="systemd-ask-password">
228        <term><command>systemd-ask-password</command></term>
229        <listitem>
230          <para>Queries the user for a system passphrase, via the
231          TTY or an UI agent.</para>
232          <indexterm zone="ch-system-systemd systemd-ask-password">
233            <primary sortas="b-systemd-ask-password">systemd-ask-password</primary>
234          </indexterm>
235        </listitem>
236      </varlistentry>
237
238      <varlistentry id="systemd-cgls">
239        <term><command>systemd-cgls</command></term>
240        <listitem>
241          <para>Recursively shows control group contents</para>
242          <indexterm zone="ch-system-systemd systemd-cgls">
243            <primary sortas="b-systemd-cgls">systemd-cgls</primary>
244          </indexterm>
245        </listitem>
246      </varlistentry>
247
248      <varlistentry id="systemd-notify">
249        <term><command>systemd-notify</command></term>
250        <listitem>
251          <para>Notify init system about start-up completion and other daemon
252          status changes</para>
253          <indexterm zone="ch-system-systemd systemd-notify">
254            <primary sortas="b-systemd-notify">systemd-notify</primary>
255          </indexterm>
256        </listitem>
257      </varlistentry>
258
259      <varlistentry id="systemd-tty-ask-password-agent">
260        <term><command>systemd-tty-ask-password-agent</command></term>
261        <listitem>
262          <para>Process system password requests</para>
263          <indexterm zone="ch-system-systemd systemd-tty-ask-password-agent">
264            <primary sortas="b-systemd-tty-ask-password-agent">systemd-tty-ask-password-agent</primary>
265          </indexterm>
266        </listitem>
267      </varlistentry>
268
269      <varlistentry id="pam_systemd">
270        <term><filename class="libraryfile">pam_systemd</filename></term>
271        <listitem>
272          <para>Register user sessions in the Systemd control group
273          hierarchy</para>
274          <indexterm zone="ch-system-systemd pam_systemd">
275            <primary sortas="c-pam_systemd">pam_systemd</primary>
276          </indexterm>
277        </listitem>
278      </varlistentry>
279
280      <varlistentry id="lib-systemd">
281        <term><filename class="directory">/lib/systemd</filename></term>
282        <listitem>
283          <para>Location of system units and configurations</para>
284          <indexterm zone="ch-system-systemd lib-systemd">
285            <primary sortas="e-/lib/systemd">/lib/systemd</primary>
286          </indexterm>
287        </listitem>
288      </varlistentry>
289
290      <varlistentry id="etc-systemd">
291        <term><filename class="directory">/etc/systemd</filename></term>
292        <listitem>
293          <para>Location of user units and configurations</para>
294          <indexterm zone="ch-system-systemd etc-systemd">
295            <primary sortas="e-/etc/systemd">/etc/systemd</primary>
296          </indexterm>
297        </listitem>
298      </varlistentry>
299
300      <varlistentry id="etc-tmpfilesd">
301        <term><filename class="directory">/etc/tmpfiles.d</filename></term>
302        <listitem>
303          <para>Configuration for creation, deletion and cleaning of temporary
304          and volatile files</para>
305          <indexterm zone="ch-system-systemd etc-tmpfilesd">
306            <primary sortas="e-/etc/tmpfiles.d">/etc/tmpfiles.d</primary>
307          </indexterm>
308        </listitem>
309      </varlistentry>
310
311      <varlistentry id="usr-share-systemd">
312        <term><filename class="directory">/usr/share/systemd</filename></term>
313        <listitem>
314          <para>Location of session unit files</para>
315          <indexterm zone="ch-system-systemd usr-share-systemd">
316            <primary sortas="e-/usr/share/systemd">/usr/share/systemd</primary>
317          </indexterm>
318        </listitem>
319      </varlistentry>
320
321    </variablelist>
322
323  </sect2>
324
325</sect1>
Note: See TracBrowser for help on using the repository browser.