source: general/sysutils/systemd.xml@ 23e36d1

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts lazarus lxqt nosym perl-modules plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since 23e36d1 was 23e36d1, checked in by DJ Lucas <dj@…>, 7 years ago

Add lxml-3.6.4 (systemd).

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@18015 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 11.2 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 <!ENTITY systemd-download-http "http://anduin.linuxfromscratch.org/sources/other/systemd/systemd-&systemd-version;.tar.xz">
8 <!ENTITY systemd-download-ftp " ">
9 <!ENTITY systemd-md5sum "2647855c8f9cdf824953f1091db2d2b2">
10 <!ENTITY systemd-size "3,840 KB">
11 <!ENTITY systemd-buildsize "447 MB">
12 <!ENTITY systemd-time "6.4 SBU">
13
14]>
15
16<sect1 id="systemd" xreflabel="Systemd-&systemd-version;" revision="systemd">
17 <?dbhtml filename="systemd.html"?>
18
19 <sect1info>
20 <othername>$LastChangedBy$</othername>
21 <date>$Date$</date>
22 </sect1info>
23
24 <title>Systemd-&systemd-version;</title>
25
26 <indexterm zone="systemd">
27 <primary sortas="a-systemd">systemd</primary>
28 </indexterm>
29
30 <sect2 role="package">
31 <title>Introduction to systemd</title>
32
33 <para>
34 While <application>systemd</application> was installed when
35 building LFS, there are many features provided by the package that
36 were not included in the initial installation because
37 <application>Linux-PAM</application> was not yet installed.
38 The <application>systemd</application> package needs to be
39 rebuilt to provide a working <command>systemd-logind</command> service,
40 which provides many additional features for dependent packages.
41 </para>
42
43 &lfs7a_checked;
44
45 <bridgehead renderas="sect3">Package Information</bridgehead>
46 <itemizedlist spacing="compact">
47 <listitem>
48 <para>Download (HTTP): <ulink url="&systemd-download-http;"/></para>
49 </listitem>
50 <listitem>
51 <para>Download (FTP): <ulink url="&systemd-download-ftp;"/></para>
52 </listitem>
53 <listitem>
54 <para>Download MD5 sum: &systemd-md5sum;</para>
55 </listitem>
56 <listitem>
57 <para>Download size: &systemd-size;</para>
58 </listitem>
59 <listitem>
60 <para>Estimated disk space required: &systemd-buildsize;</para>
61 </listitem>
62 <listitem>
63 <para>Estimated build time: &systemd-time;</para>
64 </listitem>
65 </itemizedlist>
66
67 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
68 <itemizedlist spacing="compact">
69 <listitem>
70 <para>
71 Required patch:
72 <ulink url="&patch-root;/systemd-&systemd-version;-security_fix-1.patch"/>
73 </para>
74 </listitem>
75 </itemizedlist>
76
77 <bridgehead renderas="sect3">systemd Dependencies</bridgehead>
78
79 <bridgehead renderas="sect4">Required</bridgehead>
80 <para role="required">
81 <xref linkend="linux-pam"/>
82 </para>
83
84 <bridgehead renderas="sect4">Recommended Runtime Dependency</bridgehead>
85 <para role="recommended">
86 <xref linkend="polkit"/>
87 </para>
88
89 <bridgehead renderas="sect4">Optional</bridgehead>
90 <para role="optional">
91 <xref linkend="cacerts"/>,
92 <xref linkend="curl"/>,
93 <xref linkend="elfutils"/>,
94 <xref linkend="gnutls"/>,
95 <xref linkend="iptables"/>,
96 <xref linkend="libgcrypt"/>,
97 <xref linkend="libidn"/>,
98 <xref linkend="libxkbcommon"/>,
99 <xref linkend="lxml"/>,
100 <xref linkend="qemu"/>,
101 <xref linkend="valgrind"/>,
102 <xref linkend="zsh"/> (for the zsh completions),
103 <ulink url="https://www.kernel.org/pub/linux/utils/cryptsetup/">cryptsetup</ulink>,
104 <ulink url="http://sourceforge.net/projects/gnu-efi/">gnu-efi</ulink>,
105 <ulink url="https://www.kernel.org/pub/linux/utils/kernel/kexec/">kexec-tools</ulink>,
106 <ulink url="https://www.gnu.org/software/libmicrohttpd/">libmicrohttpd</ulink>,
107 <ulink url="http://sourceforge.net/projects/libseccomp/">libseccomp</ulink>,
108 <ulink url="https://github.com/Cyan4973/lz4">lz4</ulink>,
109 <ulink url="http://fukuchi.org/works/qrencode/">qrencode</ulink>,
110 <ulink url="http://sourceforge.net/projects/linuxquota/">quota-tools</ulink> and
111 <ulink url="https://pypi.python.org/pypi/Sphinx">Sphinx</ulink>
112 </para>
113
114 <note>
115 <para>
116 In order to build the <application>systemd</application>
117 <application>Python</application> module, the
118 <application>lxml</application> package
119 needs to be installed for the corresponding
120 <application>Python</application> version (2 or 3).
121 Note that <command>configure</command> defaults to
122 <application>Python 2</application>. In order to build
123 the module for <application>Python 3</application>,
124 make sure you pass the <envar>PYTHON=python3</envar>
125 environment variable to the <command>configure</command>
126 command below.
127 </para>
128 </note>
129
130 <bridgehead renderas="sect4">Optional (to rebuild the manual pages)</bridgehead>
131 <para role="optional">
132 <xref linkend="DocBook"/>,
133 <xref linkend="docbook-xsl"/> and
134 <xref linkend="libxslt"/>
135 </para>
136
137 <para condition="html" role="usernotes">User Notes:
138 <ulink url="&blfs-wiki;/systemd"/>
139 </para>
140 </sect2>
141
142 <sect2 role="installation">
143 <title>Installation of systemd</title>
144
145<!-- Not needed as of v231 -renodr
146 <para>First, fix a potential security issue with framebuffer
147 devices:</para>
148
149<screen><userinput>sed -e 's@DRI and frame buffer@DRI@' \
150 -e '/SUBSYSTEM==\"graphics\", KERNEL==\"fb\*\"/d' \
151 -i src/login/70-uaccess.rules</userinput></screen>
152-->
153
154 <para>
155 Apply a patch that fixes a security issue.
156 </para>
157
158<screen><userinput>patch -Np1 -i ../systemd-&systemd-version;-security_fix-1.patch</userinput></screen>
159
160 <para>
161 Disable two tests that always fail:
162 </para>
163
164<screen><userinput>sed -e 's:test/udev-test.pl ::g' \
165 -e 's:test-copy$(EXEEXT) ::g' \
166 -i Makefile.in</userinput></screen>
167
168 <para>
169 Rebuild <application>systemd</application> by running the
170 following commands:
171 </para>
172
173<screen><userinput>cc_cv_CFLAGS__flto=no \
174XSLTPROC="/usr/bin/xsltproc" \
175./configure --prefix=/usr \
176 --sysconfdir=/etc \
177 --localstatedir=/var \
178 --with-rootprefix= \
179 --with-rootlibdir=/lib \
180 --enable-split-usr \
181 --disable-firstboot \
182 --disable-ldconfig \
183 --disable-sysusers \
184 --without-python \
185 --with-default-dnssec=no \
186 --docdir=/usr/share/doc/systemd-&systemd-version; &amp;&amp;
187make</userinput></screen>
188
189 <note>
190 <para>
191 For the best results, make sure you run the testsuite from
192 a system that is booted by the same
193 <application>systemd</application> version you are rebuilding.
194 </para>
195 </note>
196
197 <para>
198 To test the results, issue: <command>make -k check</command>.
199 </para>
200
201 <warning>
202 <para>
203 Installing the package will overwrite all files installed by
204 <application>systemd</application> in LFS. It is critical that
205 nothing uses either <application>systemd</application> or
206 <application>Udev</application> libraries during the installation.
207 The best way to ensure that these libraries are not being used is to
208 run the installation in rescue mode. To switch to rescue mode,
209 run the following command as the
210 <systemitem class="username">root</systemitem> user (from a TTY):
211 </para>
212
213<screen role="root"><userinput>systemctl start rescue.target</userinput></screen>
214 </warning>
215
216 <para>
217 Now, as the <systemitem class="username">root</systemitem> user:
218 </para>
219
220<screen role="root"><userinput>make install</userinput></screen>
221
222 <para>
223 Move the NSS libraries to <filename class="directory">/lib</filename>
224 by running the following command as the <systemitem
225 class="username">root</systemitem> user:
226 </para>
227
228<screen role="root"><userinput>mv -v /usr/lib/libnss_{myhostname,mymachines,resolve}.so.2 /lib</userinput></screen>
229
230 <para>
231 Remove an unnecessary directory by running the following command
232 as the <systemitem class="username">root</systemitem> user:
233 </para>
234
235<screen role="root"><userinput>rm -rfv /usr/lib/rpm</userinput></screen>
236
237 </sect2>
238
239 <sect2 role="configuration">
240 <title>Configuring systemd</title>
241
242 <para>
243 The <filename>/etc/pam.d/system-sesion</filename> file needs to
244 be modified and a new file needs to be created in order for
245 <command>systemd-logind</command> to work correctly. Run the following
246 commands as the <systemitem class="username">root</systemitem> user:
247 </para>
248
249<screen role="root"><userinput>cat &gt;&gt; /etc/pam.d/system-session &lt;&lt; "EOF"
250<literal># Begin Systemd addition
251
252session required pam_loginuid.so
253session optional pam_systemd.so
254
255# End Systemd addition</literal>
256EOF
257
258cat &gt; /etc/pam.d/systemd-user &lt;&lt; "EOF"
259<literal># Begin /etc/pam.d/systemd-user
260
261account required pam_access.so
262account include system-account
263
264session required pam_env.so
265session required pam_limits.so
266session include system-session
267
268auth required pam_deny.so
269password required pam_deny.so
270
271# End /etc/pam.d/systemd-user</literal>
272EOF</userinput></screen>
273
274 <para>
275 At this point, you should reload the systemd daemon, and reenter
276 multi-user mode with the following commands (as the
277 <systemitem class="username">root</systemitem> user):
278 </para>
279
280<screen role="root"><userinput>systemctl daemon-reload
281systemctl start multi-user.target</userinput></screen>
282
283 <warning><para>If upgrading from a previous version of systemd and an
284 initrd is used for system boot, you should generate a new initrd before
285 rebooting the system.</para></warning>
286
287 </sect2>
288
289 <sect2 role="content">
290 <title>Contents</title>
291
292 <para>
293 A list of the installed files, along with their short
294 descriptions can be found at
295 <ulink url="&lfs-root;/chapter06/systemd.html#contents-systemd"/>.
296 </para>
297
298 <para>
299 Listed below are the newly installed libraries and directories
300 along with short descriptions.
301 </para>
302
303 <segmentedlist>
304 <segtitle>Installed Programs</segtitle>
305 <segtitle>Installed Libraries</segtitle>
306 <segtitle>Installed Directories</segtitle>
307
308 <seglistitem>
309 <seg>
310 None
311 </seg>
312 <seg>
313 pam_systemd.so
314 (in <filename class="directory">/lib/security</filename>)
315 </seg>
316 <seg>
317 None
318 </seg>
319 </seglistitem>
320 </segmentedlist>
321
322 <variablelist>
323 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
324 <?dbfo list-presentation="list"?>
325 <?dbhtml list-presentation="table"?>
326
327 <varlistentry id="pam_systemd">
328 <term><filename class="libraryfile">pam_systemd.so</filename></term>
329 <listitem>
330 <para>
331 is a PAM module used to register user sessions with the
332 <application>systemd</application> login manager,
333 <command>systemd-logind</command>.
334 </para>
335 <indexterm zone="systemd pam_systemd">
336 <primary sortas="c-pam_systemd">pam_systemd.so</primary>
337 </indexterm>
338 </listitem>
339 </varlistentry>
340
341 </variablelist>
342
343 </sect2>
344
345</sect1>
Note: See TracBrowser for help on using the repository browser.