source: BOOK/final-system/common/systemd.xml@ 6757ca46

clfs-3.0.0-systemd systemd
Last change on this file since 6757ca46 was e167dd9, checked in by Chris Staub <chris@…>, 11 years ago

Slight grammar fix

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