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

systemd
Last change on this file since a27fd74 was 8274832, checked in by William Harrington <kb0iic@…>, 8 years ago

It is DNSSEC, not DNNSEC.

  • Property mode set to 100644
File size: 23.3 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="s1">Prevent the <filename>Makefile</filename> from trying to run
28 <command>setcap</command> on <command>systemd-detect-virt</command>,
29 which will fail if the kernel or file system does not support extended
30 capabilities:</para>
31
32<screen os="s2"><userinput>sed -i '/virt-install-hook /d' Makefile.in</userinput></screen>
33
34 <para os="s3">The <filename>timesyncd.conf</filename> file contains a
35 reference to a non-existent <filename>timesyncd.conf(5)</filename> man
36 page. Remove that reference to avoid possible confusion:</para>
37
38<screen os="s4"><userinput>sed -i '/timesyncd.conf/d' src/timesync/timesyncd.conf.in</userinput></screen>
39
40 <para os="cc1">Create a file to declare some variables</para>
41
42 <screen os="cc2"><userinput>cat &gt; config.cache &lt;&lt; "EOF"
43 KILL="/bin/kill"
44 MOUNT_PATH="/bin/mount"
45 UMOUNT_PATH="/bin/umount"
46 SULOGIN="/sbin/sulogin"
47 XSLTPROC="/usr/bin/xsltproc"
48 EOF</userinput></screen>
49
50
51 <para os="a">Prepare systemd for compilation:</para>
52
53<screen os="b"><userinput>./configure \
54 --prefix=/usr \
55 --sysconfdir=/etc \
56 --localstatedir=/var \
57 --libexecdir=/usr/lib \
58 --docdir=/usr/share/doc/systemd-&systemd-version; \
59 --with-rootprefix="" \
60 --with-rootlibdir=/lib \
61 --enable-split-usr \
62 --disable-firstboot \
63 --disable-ldconfig \
64 --disable-lto \
65 --disable-sysusers \
66 --with-default-dnssec=no \
67 --with-kbd-loadkeys=/bin/loadkeys \
68 --with-kbd-setfont=/bin/setfont \
69 --with-dbuspolicydir=/etc/dbus-1/system.d \
70 --with-dbussessionservicedir=/usr/share/dbus-1/services \
71 --with-dbussystemservicedir=/usr/share/dbus-1/system-services \
72 --config-cache</userinput></screen>
73
74 <variablelist os="c">
75 <title>The meaning of the configure options:</title>
76
77 <varlistentry>
78 <term><parameter>--config-cache</parameter></term>
79 <listitem>
80 <para>Use the created <filename>config.cache</filename>.</para>
81 </listitem>
82 </varlistentry>
83
84 <varlistentry>
85 <term><parameter>--with-root*</parameter></term>
86 <listitem>
87 <para>These switches ensure that core programs and
88 shared libraries are installed in the subdirectories
89 of the root partition.</para>
90 </listitem>
91 </varlistentry>
92
93 <varlistentry>
94 <term><parameter>--enable-split-usr</parameter></term>
95 <listitem>
96 <para>This switch ensures that systemd will work on
97 systems where /bin, /lib and /sbin directories are not
98 symlinks to their /usr counterparts.</para>
99 </listitem>
100 </varlistentry>
101
102 <varlistentry>
103 <term><parameter>--disable-firstboot</parameter></term>
104 <listitem>
105 <para>This switch prevents installation of systemd services
106 responsible for setting up the system for the first time.
107 They are not useful for CLFS as everything is done manually.
108 </para>
109 </listitem>
110 </varlistentry>
111
112 <varlistentry>
113 <term><parameter>--disable-ldconfig</parameter></term>
114 <listitem>
115 <para>This switch prevents installation of a systemd unit that runs
116 <command>ldconfig</command> at boot, and increases boot time.
117 While it may be not useful for source distributions like CLFS,
118 this option may be removed.</para>
119 </listitem>
120 </varlistentry>
121
122 <varlistentry>
123 <term><parameter>--disable-lto</parameter></term>
124 <listitem>
125 <para>This prevents the build system from using GCC's Link-time
126 optimization (LTO), to ensure that systemd's binaries will not try
127 to link to <filename class="libraryfile">libgcc_s</filename></para>
128 </listitem>
129 </varlistentry>
130
131 <varlistentry>
132 <term><parameter>--disable-sysusers</parameter></term>
133 <listitem>
134 <para>This switch prevents install of systemd services which setup
135 the previously created <filename>/etc/group</filename> and
136 <filename>/etc/passwd</filename> files.</para>
137 </listitem>
138 </varlistentry>
139
140 <varlistentry>
141 <term><parameter>--with-dbus*</parameter></term>
142 <listitem>
143 <para>These switches ensure that D-Bus configuration files get
144 installed to the correct locations.</para>
145 </listitem>
146 </varlistentry>
147
148 <varlistentry>
149 <term><parameter>--with-default-dnssec=no</parameter></term>
150 <listitem>
151 <para>This switch turns off the experimental DNSSEC support.</para>
152 </listitem>
153 </varlistentry>
154
155 </variablelist>
156
157 <para os="d">Compile the package:</para>
158
159<screen os="e"><userinput>make</userinput></screen>
160
161 <para os="f">Prevent a broken test case from running:</para>
162
163<screen os="g"><userinput remap="test">sed -e 's@test/udev-test.pl @@' \
164 -e 's@test-copy$(EXEEXT) @@' \
165 -i Makefile.in
166</userinput></screen>
167
168 <para os="h">To test the results, issue:</para>
169
170 <screen os="i"><userinput remap="test">
171 sed -i "s:minix:ext4:g" src/test/test-path-util.c
172 make check</userinput></screen>
173
174 <para os="j">Install the package:</para>
175
176<screen os="k"><userinput>make install</userinput></screen>
177
178 <para os="l">Install documentation files that are not installed by default:</para>
179
180<screen os="m"><userinput>install -v -m644 man/*.html /usr/share/doc/systemd-&systemd-version;</userinput></screen>
181
182 <para os="p">Remove an unnecessary directory:</para>
183
184<screen os="q"><userinput>rm -rfv /usr/lib/rpm</userinput></screen>
185
186 <para os="r">Create symlinks for backwards-compatibility with Sysvinit:</para>
187
188<screen os="s"><userinput>for tool in runlevel reboot shutdown poweroff halt telinit; do
189 ln -sfv ../bin/systemctl /sbin/$tool
190done
191ln -sfv ../lib/systemd/systemd /sbin/init</userinput></screen>
192
193 </sect2>
194
195 <sect2 id="conf-systemd" role="configuration">
196 <title>Configuring Systemd</title>
197
198 <indexterm zone="conf-systemd">
199 <primary sortas="a-systemd">systemd</primary>
200 <secondary>configuring</secondary></indexterm>
201
202 <indexterm zone="conf-systemd">
203 <primary sortas="e-/etc/os-release">/etc/os-release</primary>
204 </indexterm>
205
206 <para>Create <filename>/etc/machine-id</filename> which is needed
207 by Journald:</para>
208
209<screen><userinput>systemd-machine-id-setup</userinput></screen>
210
211 <para>Create a file to identify the operating system.
212 <command>systemd</command> will use this file on boot to put information
213 on the screen.</para>
214
215<screen><userinput>cat &gt; /etc/os-release &lt;&lt; "EOF"
216# Begin /etc/os-release
217
218NAME=Cross-LFS
219ID=clfs
220
221PRETTY_NAME=Cross Linux From Scratch
222ANSI_COLOR=0;33
223
224VERSION=&version;
225VERSION_ID=&versionid;
226
227# End /etc/os-release
228EOF</userinput></screen>
229
230 </sect2>
231
232 <sect2 id="contents-systemd" role="content">
233 <title>Contents of Systemd</title>
234
235 <segmentedlist>
236 <segtitle>Installed programs</segtitle>
237 <segtitle>Installed libraries</segtitle>
238 <segtitle>Installed directories</segtitle>
239
240 <seglistitem>
241 <seg>bootctl, busctl, halt (link to systemctl), hostnamectl,
242 init (link to systemd), journalctl, kernel-install, localectl, loginctl,
243 machinectl, poweroff (link to systemctl), reboot (link to systemctl),
244 runlevel (link to systemctl), shutdown (link to systemctl),
245 systemctl, systemd, system-analyze, systemd-ask-password, systemd-cat,
246 systemd-cgls, systemd-cgtop, systemd-coredumpctl, systemd-delta,
247 systemd-detect-virt, systemd-inhibit, systemd-machine-id-setup,
248 systemd-notify, systemd-nspawn, systemd-run, systemd-stdio-bridge
249 (link to systemd-bus-proxyd), systemd-tmpfiles,
250 systemd-tty-ask-password-agent, telinit (link to systemctl),
251 timedatectl, udevadm</seg>
252 <seg>libnss_myhostname.so, libsystemd.so, libudev.so</seg>
253 <seg>/etc/binfmt.d, /etc/init.d, /etc/kernel, /etc/modules-load.d,
254 /etc/sysctl.d, /etc/systemd, /etc/tmpfiles.d, /etc/udev,
255 /etc/xdg/systemd, /lib/systemd, /lib/udev, /usr/include/systemd,
256 /usr/lib/binfmt.d, /usr/lib/kernel, /usr/lib/modules-load.d,
257 /usr/lib/sysctl.d, /usr/lib/systemd,
258 /usr/share/doc-systemd-&systemd-version;, /usr/share/systemd,
259 /usr/share/zsh, /var/lib/systemd</seg>
260 </seglistitem>
261 </segmentedlist>
262
263 <variablelist>
264 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
265 <?dbfo list-presentation="list"?>
266 <?dbhtml list-presentation="table"?>
267
268 <varlistentry id="bootctl">
269 <term><command>bootctl</command></term>
270 <listitem>
271 <para>Controls the firmware and boot manager settings</para>
272 <indexterm zone="ch-system-systemd bootctl">
273 <primary sortas="b-bootctl">bootctl</primary>
274 </indexterm>
275 </listitem>
276 </varlistentry>
277
278 <varlistentry id="busctl">
279 <term><command>busctl</command></term>
280 <listitem>
281 <para>Introspects and monitors the D-Bus bus</para>
282 <indexterm zone="ch-system-systemd busctl">
283 <primary sortas="b-busctl">busctl</primary>
284 </indexterm>
285 </listitem>
286 </varlistentry>
287
288 <varlistentry id="halt">
289 <term><command>halt</command></term>
290 <listitem>
291 <para>Halts, powers off, or reboots the machine</para>
292 <indexterm zone="ch-system-systemd halt">
293 <primary sortas="b-halt">halt</primary>
294 </indexterm>
295 </listitem>
296 </varlistentry>
297
298 <varlistentry id="hostnamectl">
299 <term><command>hostnamectl</command></term>
300 <listitem>
301 <para>Controls the system hostname</para>
302 <indexterm zone="ch-system-systemd hostnamectl">
303 <primary sortas="b-hostnamectl">hostnamectl</primary>
304 </indexterm>
305 </listitem>
306 </varlistentry>
307
308 <varlistentry id="init">
309 <term><command>init</command></term>
310 <listitem>
311 <para>systemd system and service manager</para>
312 <indexterm zone="ch-system-systemd init">
313 <primary sortas="b-init">init</primary>
314 </indexterm>
315 </listitem>
316 </varlistentry>
317
318 <varlistentry id="journalctl">
319 <term><command>journalctl</command></term>
320 <listitem>
321 <para>Queries the systemd journal</para>
322 <indexterm zone="ch-system-systemd journalctl">
323 <primary sortas="b-journalctl">journalctl</primary>
324 </indexterm>
325 </listitem>
326 </varlistentry>
327
328 <varlistentry id="kernel-install">
329 <term><command>kernel-install</command></term>
330 <listitem>
331 <para>Adds and removes kernel and initramfs images to and from
332 <filename class="directory">/boot</filename></para>
333 <indexterm zone="ch-system-systemd kernel-install">
334 <primary sortas="b-kernel-install">kernel-install</primary>
335 </indexterm>
336 </listitem>
337 </varlistentry>
338
339 <varlistentry id="localectl">
340 <term><command>localectl</command></term>
341 <listitem>
342 <para>Controls the system locale and keyboard layout settings</para>
343 <indexterm zone="ch-system-systemd localectl">
344 <primary sortas="b-localectl">localectl</primary>
345 </indexterm>
346 </listitem>
347 </varlistentry>
348
349 <varlistentry id="loginctl">
350 <term><command>loginctl</command></term>
351 <listitem>
352 <para>Controls the systemd login manager</para>
353 <indexterm zone="ch-system-systemd loginctl">
354 <primary sortas="b-loginctl">loginctl</primary>
355 </indexterm>
356 </listitem>
357 </varlistentry>
358
359 <varlistentry id="machinectl">
360 <term><command>machinectl</command></term>
361 <listitem>
362 <para>Controls the systemd machine manager</para>
363 <indexterm zone="ch-system-systemd machinectl">
364 <primary sortas="b-machinectl">machinectl</primary>
365 </indexterm>
366 </listitem>
367 </varlistentry>
368
369 <varlistentry id="poweroff">
370 <term><command>poweroff</command></term>
371 <listitem>
372 <para>Halts, powers off, or reboots the machine</para>
373 <indexterm zone="ch-system-systemd poweroff">
374 <primary sortas="b-poweroff">poweroff</primary>
375 </indexterm>
376 </listitem>
377 </varlistentry>
378
379 <varlistentry id="reboot">
380 <term><command>reboot</command></term>
381 <listitem>
382 <para>Halts, powers off, or reboots the machine</para>
383 <indexterm zone="ch-system-systemd reboot">
384 <primary sortas="b-reboot">reboot</primary>
385 </indexterm>
386 </listitem>
387 </varlistentry>
388
389 <varlistentry id="runlevel">
390 <term><command>runlevel</command></term>
391 <listitem>
392 <para>Prints previous and current SysV runlevel</para>
393 <indexterm zone="ch-system-systemd runlevel">
394 <primary sortas="b-runlevel">runlevel</primary>
395 </indexterm>
396 </listitem>
397 </varlistentry>
398
399 <varlistentry id="shutdown">
400 <term><command>shutdown</command></term>
401 <listitem>
402 <para>Halts, powers off, or reboots the machine</para>
403 <indexterm zone="ch-system-systemd shutdown">
404 <primary sortas="b-shutdown">shutdown</primary>
405 </indexterm>
406 </listitem>
407 </varlistentry>
408
409 <varlistentry id="systemctl">
410 <term><command>systemctl</command></term>
411 <listitem>
412 <para>Control the systemd system and service manager</para>
413 <indexterm zone="ch-system-systemd systemctl">
414 <primary sortas="b-systemctl">systemctl</primary>
415 </indexterm>
416 </listitem>
417 </varlistentry>
418
419 <varlistentry id="systemd">
420 <term><command>systemd</command></term>
421 <listitem>
422 <para>System and service manager for Linux</para>
423 <indexterm zone="ch-system-systemd systemd">
424 <primary sortas="b-systemd">systemd</primary>
425 </indexterm>
426 </listitem>
427 </varlistentry>
428
429 <varlistentry id="systemd-analyze">
430 <term><command>systemd-analyze</command></term>
431 <listitem>
432 <para>Analyzes system boot-up permformance</para>
433 <indexterm zone="ch-system-systemd systemd-analyze">
434 <primary sortas="b-systemd-analyze">systemd-analyze</primary>
435 </indexterm>
436 </listitem>
437 </varlistentry>
438
439 <varlistentry id="systemd-ask-password">
440 <term><command>systemd-ask-password</command></term>
441 <listitem>
442 <para>Queries the user for a system passphrase, via the
443 TTY or an UI agent.</para>
444 <indexterm zone="ch-system-systemd systemd-ask-password">
445 <primary sortas="b-systemd-ask-password">systemd-ask-password</primary>
446 </indexterm>
447 </listitem>
448 </varlistentry>
449
450 <varlistentry id="systemd-cat">
451 <term><command>systemd-cat</command></term>
452 <listitem>
453 <para>Connects a pipeline or program's output with the journal</para>
454 <indexterm zone="ch-system-systemd systemd-cat">
455 <primary sortas="b-systemd-cat">systemd-cat</primary>
456 </indexterm>
457 </listitem>
458 </varlistentry>
459
460 <varlistentry id="systemd-cgls">
461 <term><command>systemd-cgls</command></term>
462 <listitem>
463 <para>Recursively shows control group contents</para>
464 <indexterm zone="ch-system-systemd systemd-cgls">
465 <primary sortas="b-systemd-cgls">systemd-cgls</primary>
466 </indexterm>
467 </listitem>
468 </varlistentry>
469
470 <varlistentry id="systemd-cgtop">
471 <term><command>systemd-cgtop</command></term>
472 <listitem>
473 <para>Shows top control groups by resource usage</para>
474 <indexterm zone="ch-system-systemd systemd-cgtop">
475 <primary sortas="b-systemd-cgtop">systemd-cgtop</primary>
476 </indexterm>
477 </listitem>
478 </varlistentry>
479
480 <varlistentry id="systemd-coredumpctl">
481 <term><command>systemd-coredumpctl</command></term>
482 <listitem>
483 <para>Retrieves coredumps from the journal</para>
484 <indexterm zone="ch-system-systemd systemd-coredumpctl">
485 <primary sortas="b-systemd-coredumpctl">systemd-coredumpctl</primary>
486 </indexterm>
487 </listitem>
488 </varlistentry>
489
490 <varlistentry id="systemd-delta">
491 <term><command>systemd-delta</command></term>
492 <listitem>
493 <para>Finds overridden configuration files</para>
494 <indexterm zone="ch-system-systemd systemd-delta">
495 <primary sortas="b-systemd-delta">systemd-delta</primary>
496 </indexterm>
497 </listitem>
498 </varlistentry>
499
500 <varlistentry id="systemd-detect-virt">
501 <term><command>systemd-detect-virt</command></term>
502 <listitem>
503 <para>Detects execution in a virtual environment</para>
504 <indexterm zone="ch-system-systemd systemd-detect-virt">
505 <primary sortas="b-systemd-detect-virt">systemd-detect-virt</primary>
506 </indexterm>
507 </listitem>
508 </varlistentry>
509
510 <varlistentry id="systemd-inhibit">
511 <term><command>systemd-inhibit</command></term>
512 <listitem>
513 <para>Executes a program with an inhibition lock taken</para>
514 <indexterm zone="ch-system-systemd systemd-inhibit">
515 <primary sortas="b-systemd-inhibit">systemd-inhibit</primary>
516 </indexterm>
517 </listitem>
518 </varlistentry>
519
520 <varlistentry id="systemd-machine-id-setup">
521 <term><command>systemd-machine-id-setup</command></term>
522 <listitem>
523 <para>Initializes the machine ID in
524 <filename>/etc/machine-id</filename></para>
525 <indexterm zone="ch-system-systemd systemd-machine-id-setup">
526 <primary sortas="b-systemd-machine-id-setup">systemd-machine-id-setup</primary>
527 </indexterm>
528 </listitem>
529 </varlistentry>
530
531 <varlistentry id="systemd-notify">
532 <term><command>systemd-notify</command></term>
533 <listitem>
534 <para>Notifies init system about start-up completion and other daemon
535 status changes</para>
536 <indexterm zone="ch-system-systemd systemd-notify">
537 <primary sortas="b-systemd-notify">systemd-notify</primary>
538 </indexterm>
539 </listitem>
540 </varlistentry>
541
542 <varlistentry id="systemd-nspawn">
543 <term><command>systemd-nspawn</command></term>
544 <listitem>
545 <para>Spawns a namespace container for debugging, testing, and
546 building</para>
547 <indexterm zone="ch-system-systemd systemd-nspawn">
548 <primary sortas="b-systemd-nspawn">systemd-nspawn</primary>
549 </indexterm>
550 </listitem>
551 </varlistentry>
552
553 <varlistentry id="systemd-run">
554 <term><command>systemd-run</command></term>
555 <listitem>
556 <para>Runs programs in transient scope or service units</para>
557 <indexterm zone="ch-system-systemd systemd-run">
558 <primary sortas="b-systemd-run">systemd-run</primary>
559 </indexterm>
560 </listitem>
561 </varlistentry>
562
563 <varlistentry id="systemd-stdio-bridge">
564 <term><command>systemd-stdio-bridge</command></term>
565 <listitem>
566 <para>Connects stdio or a socket to a given bus address</para>
567 <indexterm zone="ch-system-systemd systemd-stdio-bridge">
568 <primary sortas="b-systemd-stdio-bridge">systemd-stdio-bridge</primary>
569 </indexterm>
570 </listitem>
571 </varlistentry>
572
573 <varlistentry id="systemd-tmpfiles">
574 <term><command>systemd-tmpfiles</command></term>
575 <listitem>
576 <para>Creates, deletes, and cleans up volatile and temporary files</para>
577 <indexterm zone="ch-system-systemd systemd-tmpfiles">
578 <primary sortas="b-systemd-tmpfiles">systemd-tmpfiles</primary>
579 </indexterm>
580 </listitem>
581 </varlistentry>
582
583 <varlistentry id="systemd-tty-ask-password-agent">
584 <term><command>systemd-tty-ask-password-agent</command></term>
585 <listitem>
586 <para>Process system password requests</para>
587 <indexterm zone="ch-system-systemd systemd-tty-ask-password-agent">
588 <primary sortas="b-systemd-tty-ask-password-agent">systemd-tty-ask-password-agent</primary>
589 </indexterm>
590 </listitem>
591 </varlistentry>
592
593 <varlistentry id="telinit">
594 <term><command>telinit</command></term>
595 <listitem>
596 <para>Tells <command>init</command> which run-level to change to</para>
597 <indexterm zone="ch-system-systemd telinit">
598 <primary sortas="b-telinit">telinit</primary>
599 </indexterm>
600 </listitem>
601 </varlistentry>
602
603 <varlistentry id="timedatectl">
604 <term><command>timedatectl</command></term>
605 <listitem>
606 <para>Controls the system time and date</para>
607 <indexterm zone="ch-system-systemd timedatectl">
608 <primary sortas="b-timedatectl">timedatectl</primary>
609 </indexterm>
610 </listitem>
611 </varlistentry>
612
613 <varlistentry id="udevadm">
614 <term><command>udevadm</command></term>
615 <listitem>
616 <para>Udev management tool</para>
617 <indexterm zone="ch-system-systemd udevadm">
618 <primary sortas="b-udevadm">udevadm</primary>
619 </indexterm>
620 </listitem>
621 </varlistentry>
622
623 <varlistentry id="libnss_myhostname">
624 <term><filename class="libraryfile">libnss_myhostname</filename></term>
625 <listitem>
626 <para>Plugin for the GNU Name Service Switch (NSS) functionality
627 of Glibc, provding hostname resolution for the locally configured
628 system hostname</para>
629 <indexterm zone="ch-system-systemd libnss_myhostname">
630 <primary sortas="c-libnss_myhostname">libnss_myhostname</primary>
631 </indexterm>
632 </listitem>
633 </varlistentry>
634
635 <varlistentry id="libsystemd">
636 <term><filename class="libraryfile">libsystemd</filename></term>
637 <listitem>
638 <para>Support library for systemd</para>
639 <indexterm zone="ch-system-systemd libsystemd">
640 <primary sortas="c-libsystemd">libsystemd</primary>
641 </indexterm>
642 </listitem>
643 </varlistentry>
644
645 <varlistentry id="libudev">
646 <term><filename class="libraryfile">libudev</filename></term>
647 <listitem>
648 <para>A library interface to Udev device information.</para>
649 <indexterm zone="ch-system-systemd libudev">
650 <primary sortas="c-libudev">libudev</primary>
651 </indexterm>
652 </listitem>
653 </varlistentry>
654
655 </variablelist>
656
657 </sect2>
658
659</sect1>
Note: See TracBrowser for help on using the repository browser.