source: postlfs/filesystems/lvm2.xml@ 5d01724

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 8.4 9.0 9.1 bdubbs/svn elogind kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts lazarus lxqt 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 5d01724 was 5d01724, checked in by Bruce Dubbs <bdubbs@…>, 5 years ago

Update to xfsprogs-4.19.0.
Update to fuse-3.3.0.
Update to btrfs-progs-v4.19.
Update to LVM2.2.03.01.

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

  • Property mode set to 100644
File size: 14.7 KB
RevLine 
[8bc3edae]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
[e65320b]7 <!ENTITY lvm2-download-http "https://sourceware.org/pub/lvm2/LVM2.&lvm2-version;.tgz">
8 <!ENTITY lvm2-download-ftp "ftp://sourceware.org/pub/lvm2/LVM2.&lvm2-version;.tgz">
[5d01724]9 <!ENTITY lvm2-md5sum "800287d3521388dcc4a601d099b47bcd">
[8fef77a]10 <!ENTITY lvm2-size "2.3 MB">
[5d01724]11 <!ENTITY lvm2-buildsize "33 MB (add at least 252 MB for tests in the /tmp directory; additionally transient files can grow up to around 500 MB)">
[3964f59]12 <!ENTITY lvm2-time "0.2 SBU (using parallelism=4; add 12 SBU for tests)">
[8bc3edae]13]>
14
[c627795]15<sect1 id="lvm2" xreflabel="LVM2-&lvm2-version;">
[8bc3edae]16 <?dbhtml filename="lvm2.html"?>
17
18 <sect1info>
19 <othername>$LastChangedBy$</othername>
20 <date>$Date$</date>
21 </sect1info>
22
[c627795]23 <title>LVM2-&lvm2-version;</title>
[8bc3edae]24
25 <indexterm zone="lvm2">
[c627795]26 <primary sortas="a-LVM2">LVM2</primary>
[8bc3edae]27 </indexterm>
28
29 <sect2 role="package">
[c627795]30 <title>Introduction to LVM2</title>
[8bc3edae]31
[c627795]32 <para>
[99fcc47]33 The <application>LVM2</application> package is a set of tools that manage
[c627795]34 logical partitions. It allows spanning of file systems across multiple
35 physical disks and disk partitions and provides for dynamic growing or
[99fcc47]36 shrinking of logical partitions, mirroring and low storage footprint
37 snapshots.
[c627795]38 </para>
[8bc3edae]39
[82e1be5]40 &lfs83_checked;
[8bc3edae]41
42 <bridgehead renderas="sect3">Package Information</bridgehead>
43 <itemizedlist spacing="compact">
[f60cf4a]44 <listitem>
[c627795]45 <para>
46 Download (HTTP): <ulink url="&lvm2-download-http;"/>
47 </para>
[f60cf4a]48 </listitem>
[8bc3edae]49 <listitem>
[c627795]50 <para>
51 Download (FTP): <ulink url="&lvm2-download-ftp;"/>
52 </para>
[8bc3edae]53 </listitem>
54 <listitem>
[c627795]55 <para>
56 Download MD5 sum: &lvm2-md5sum;
57 </para>
[8bc3edae]58 </listitem>
59 <listitem>
[c627795]60 <para>
61 Download size: &lvm2-size;
62 </para>
[8bc3edae]63 </listitem>
64 <listitem>
[c627795]65 <para>
66 Estimated disk space required: &lvm2-buildsize;
67 </para>
[8bc3edae]68 </listitem>
69 <listitem>
[c627795]70 <para>
71 Estimated build time: &lvm2-time;
72 </para>
[8bc3edae]73 </listitem>
74 </itemizedlist>
75
[b5e8375]76 <bridgehead renderas="sect3">LVM2 Dependencies</bridgehead>
77
[3964f59]78 <bridgehead renderas="sect4">Required</bridgehead>
79 <para role="required">
80 <xref linkend='libaio'/>,
81 </para>
82
[b5e8375]83 <bridgehead renderas="sect4">Optional</bridgehead>
84 <para role="optional">
[99fcc47]85 <xref linkend='mdadm'/>,
86 <xref linkend='reiserfs'/>,
87 <xref linkend='valgrind'/>,
88 <xref linkend='which'/>,
89 <xref linkend='xfsprogs'/> (all five may be used, but are not required,
90 for tests), and
91 <ulink url='https://github.com/jthornber/thin-provisioning-tools'>
92 thin-provisioning-tools</ulink>
[b5e8375]93 </para>
94
[8bc3edae]95 <para condition="html" role="usernotes">User Notes:
[c627795]96 <ulink url="&blfs-wiki;/lvm2"/>
97 </para>
[09765cf]98
[5d01724]99<!-- This shouldn't be needed any more now that we are up to 4.19+
[e7670a4]100 <caution>
[09765cf]101 <para>
[e7670a4]102 Kernel versions between 4.1 and 4.4.1 have a broken RAID
103 implementation. If you want to use RAID type LV's, you should install
104 kernel version 4.4.2 or above. Note that several tests use RAID logical
105 volumes, and can generate a <quote>kernel oops</quote> with the faulty
106 kernel version, which usually renders the system unusable.
[09765cf]107 </para>
[5d01724]108 </caution> -->
[8bc3edae]109 </sect2>
110
[c627795]111 <sect2 role="kernel" id="lvm2-kernel">
[7e1df8f9]112 <title>Kernel Configuration</title>
113
[c627795]114 <para>
[421128a1]115 Enable the following options in the kernel configuration
[c627795]116 and recompile the kernel:
117 </para>
[7e1df8f9]118
[b5e8375]119 <note><para>
120 There are several other Device Mapper options in the kernel beyond those
121 listed below. In order to get reasonable results if running the
122 regression tests, all must be enabled either internally or as a module.
[302a619]123 The tests will all time out if Magic SysRq key is not enabled.
[b5e8375]124 </para></note>
125
[7e1df8f9]126<screen><literal>Device Drivers ---&gt;
[421128a1]127 [*] Multiple devices driver support (RAID and LVM) ---&gt; [CONFIG_MD]
128 &lt;*/M&gt; Device mapper support [CONFIG_BLK_DEV_DM]
129 &lt;*/M/ &gt; Crypt target support [CONFIG_DM_CRYPT]
130 &lt;*/M/ &gt; Snapshot target [CONFIG_DM_SNAPSHOT]
[99fcc47]131 &lt;*/M/ &gt; Thin provisioning target [CONFIG_DM_THIN_PROVISIONING]
[302a619]132 &lt;*/M/ &gt; Mirror target [CONFIG_DM_MIRROR]
133Kernel hacking ---&gt;
134 [*] Magic SysRq key [CONFIG_MAGIC_SYSRQ]</literal></screen>
[7e1df8f9]135
136 <indexterm zone="lvm2 lvm2-kernel">
137 <primary sortas="d-lvm2">lvm2</primary>
138 </indexterm>
139
140 </sect2>
141
[8bc3edae]142 <sect2 role="installation">
[c627795]143 <title>Installation of LVM2</title>
[8bc3edae]144
[c627795]145 <para>
146 Install <application>LVM2</application> by running the following
147 commands:
148 </para>
[8bc3edae]149
[422bd2c]150<screen revision="sysv"><userinput>SAVEPATH=$PATH &amp;&amp;
[41d504a]151PATH=$PATH:/sbin:/usr/sbin &amp;&amp;
[e94d178]152./configure --prefix=/usr \
[4591404]153 --exec-prefix= \
154 --enable-cmdlib \
155 --enable-pkgconfig \
[46a9711b]156 --enable-udev_sync &amp;&amp;
[e94d178]157make &amp;&amp;
158PATH=$SAVEPATH &amp;&amp;
[422bd2c]159unset SAVEPATH</userinput></screen>
160
161<screen revision="systemd"><userinput>SAVEPATH=$PATH &amp;&amp;
162PATH=$PATH:/sbin:/usr/sbin &amp;&amp;
163./configure --prefix=/usr \
164 --exec-prefix= \
165 --with-confdir=/etc \
166 --enable-cmdlib \
167 --enable-pkgconfig \
168 --enable-udev_sync &amp;&amp;
169make &amp;&amp;
170PATH=$SAVEPATH &amp;&amp;
[e94d178]171unset SAVEPATH</userinput></screen>
[8bc3edae]172
[c627795]173 <para>
[99fcc47]174 The tests use <application>udev</application> for logical volume
175 synchronization, so that the LVM udev rules and some utilities need to
176 be installed before running the tests. If you are installing
177 <application>LVM2</application> for the first time, and do not
178 want to install the full package before running the tests, the minimal
179 set of utilities can be installed by running the following instructions
180 as the <systemitem class="username">root</systemitem> user:
181 </para>
182
183<screen role="root"><userinput>make -C tools install_dmsetup_dynamic &amp;&amp;
184make -C udev install &amp;&amp;
185make -C libdm install</userinput></screen>
186
187 <para>
188 To test the results, issue: <command>make check_local</command> as the
189 <systemitem class="username">root</systemitem> user. Other targets are
190 available and can be listed with <command>make -C test help</command>.
191 The test timings are very dependent on the speed of the disk(s), and on
[f9431b6]192 the number of enabled kernel options.
193 </para>
[20c731a]194
[6c6f393]195 <!-- Results for LVM2.2.02.176:
196 ### 292 tests: 177 passed, 46 skipped, 0 timed out, 60 warned, 9 failed
[5d01724]197
198 Results for LVM2.2.03.01:
199 ### 302 tests: 182 passed, 43 skipped, 0 timed out, 62 warned, 15 failed
[20c731a]200 -->
201
[f9431b6]202 <para>
[af8a78d]203 The tests do not implement the <quote>expected fail</quote> possibility,
[e94d178]204 and a small number of test failures is expected by upstream. More
[f9431b6]205 failures may happen because some kernel options are missing. For example,
206 the lack of the <emphasis>dm-delay</emphasis> device mapper target may
[53375fc]207 explain some failures. Some tests are flagged
[e94d178]208 <quote>warned</quote> if
[f9431b6]209 <ulink url='https://github.com/jthornber/thin-provisioning-tools'>
210 thin-provisioning-tools</ulink> are not installed. A workaround is to
211 add the following flags to <command>configure</command>:
212 </para>
213
214<screen role="nodump"><userinput> --with-thin-check= \
215 --with-thin-dump= \
216 --with-thin-repair= \
217 --with-thin-restore= \
218 --with-cache-check= \
219 --with-cache-dump= \
220 --with-cache-repair= \
221 --with-cache-restore= \</userinput></screen>
222
223 <para>
[e94d178]224 Some tests may hang with kernel versions in the 4.1 and 4.2 series (see
225 above). They can be removed if necessary, for example: <command>rm
226 test/shell/lvcreate-large-raid.sh</command>. The tests generate a lot
[99fcc47]227 of kernel messages, which may clutter your terminal. You can disable them
228 by issuing <command>dmesg -D</command> before running the tests (do not
229 forget to issue <command>dmesg -E</command> when tests are done).
[fbcb3846]230
231 <note><simpara>The checks create device nodes in the /tmp directory. The
232 tests will fail if /tmp is mounted with the nodev
233 option.</simpara></note>
[c627795]234 </para>
[8bc3edae]235
[c627795]236 <para>
237 Now, as the <systemitem class="username">root</systemitem> user:
238 </para>
[8bc3edae]239
240<screen role="root"><userinput>make install</userinput></screen>
241
242 </sect2>
243
244 <sect2 role="commands">
245 <title>Command Explanations</title>
246
[e94d178]247 <para>
[41d504a]248 <command>PATH=$PATH:/sbin:/usr/sbin</command>: The path
[e94d178]249 must contain <filename class="directory">/sbin</filename> and
250 <filename class='directory'>/usr/sbin</filename> for proper system tool
[41d504a]251 detection by the <command>configure</command> script. This instruction
[41e2bf5]252 ensures that PATH is properly set even if you build as an unprivileged user.
[e94d178]253 </para>
254
[c627795]255 <para>
[2800af7]256 <parameter>--enable-cmdlib</parameter>: This switch enables
[c627795]257 building of the shared command library. It is required
258 when building the event daemon.
259 </para>
260
261 <para>
[2800af7]262 <parameter>--enable-pkgconfig</parameter>: This switch enables
[c627795]263 installation of <command>pkg-config</command> support files.
264 </para>
265
266 <para>
[2800af7]267 <parameter>--enable-udev_sync</parameter>: This switch enables
[c627795]268 synchronisation with <application>Udev</application> processing.
269 </para>
270
271 <para>
272 <option>--enable-dmeventd</option>: This switch enables
273 building of the <application>Device Mapper</application>
274 event daemon.
275 </para>
[8bc3edae]276
277 </sect2>
278
279 <sect2 role="content">
280 <title>Contents</title>
281
282 <segmentedlist>
283 <segtitle>Installed Programs</segtitle>
284 <segtitle>Installed Libraries</segtitle>
[c3c56b2]285 <segtitle>Installed Directories</segtitle>
[8bc3edae]286
287 <seglistitem>
[c627795]288 <seg>
[8ed30d52]289 blkdeactivate, dmeventd (optional), dmsetup, fsadm, lvm, lvmconf,
[a4c24de]290 and lvmdump. There are also
[09765cf]291 numerous symbolic links to lvm that implement specific
292 functionalities
[c627795]293 </seg>
294 <seg>
[422bd2c]295 libdevmapper.so, liblvm2app.so, and liblvm2cmd.so; optional:
[a037dab]296 libdevmapper-event.so, libdevmapper-event-lvm2.so,
297 libdevmapper-event-lvm2mirror.so, libdevmapper-event-lvm2snapshot.so,
[80454f5]298 libdevmapper-event-lvm2raid.so, and libdevmapper-event-lvm2thin.so
[c627795]299 </seg>
[c3c56b2]300 <seg>
[a037dab]301 /etc/lvm and
302 /lib/device-mapper (optional)
[c3c56b2]303 </seg>
[8bc3edae]304 </seglistitem>
305 </segmentedlist>
306
307 <variablelist>
308 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
309 <?dbfo list-presentation="list"?>
[61b95ac4]310
311 <?dbhtml list-presentation="table"?>
[8bc3edae]312
[8ed30d52]313 <varlistentry id="blkdeactivate">
314 <term><command>blkdeactivate</command></term>
315 <listitem>
316 <para>
[422bd2c]317 is a utility to deactivate block device.
[8ed30d52]318 </para>
319 <indexterm zone="lvm2 blkdeactivate">
320 <primary sortas="b-blkdeactivate">blkdeactivate</primary>
321 </indexterm>
322 </listitem>
323 </varlistentry>
324
[a037dab]325 <varlistentry id="dmeventd">
326 <term><command>dmeventd</command></term>
327 <listitem>
328 <para>
329 (optional) is the Device Mapper event daemon.
330 </para>
331 <indexterm zone="lvm2 dmeventd">
332 <primary sortas="b-dmeventd">dmeventd</primary>
333 </indexterm>
334 </listitem>
335 </varlistentry>
336
[8bc3edae]337 <varlistentry id="dmsetup">
338 <term><command>dmsetup</command></term>
339 <listitem>
[c627795]340 <para>
341 is a low level logical volume management tool.
342 </para>
[8bc3edae]343 <indexterm zone="lvm2 dmsetup">
344 <primary sortas="b-dmsetup">dmsetup</primary>
345 </indexterm>
346 </listitem>
347 </varlistentry>
348
349 <varlistentry id="fsadm">
350 <term><command>fsadm</command></term>
351 <listitem>
[c627795]352 <para>
[73fe507]353 is a utility used to resize or check filesystem on a device.
[c627795]354 </para>
[8bc3edae]355 <indexterm zone="lvm2 fsadm">
356 <primary sortas="b-fsadm">fsadm</primary>
357 </indexterm>
358 </listitem>
359 </varlistentry>
360
361 <varlistentry id="lvm">
362 <term><command>lvm</command></term>
363 <listitem>
[c627795]364 <para>
365 provides the command-line tools for <application>LVM2</application>.
366 Commands are implemented via sympolic links to this program to
367 manage physical devices (pv*), volume groups (vg*) and logical
368 volumes (lv*).
369 </para>
[8bc3edae]370 <indexterm zone="lvm2 lvm">
371 <primary sortas="b-lvm">lvm</primary>
372 </indexterm>
373 </listitem>
374 </varlistentry>
375
376 <varlistentry id="lvmconf">
377 <term><command>lvmconf</command></term>
378 <listitem>
[c627795]379 <para>
[0d7900a]380 is a script that modifies the locking configuration in
[c627795]381 the <application>LVM2</application> configuration file.
382 </para>
[8bc3edae]383 <indexterm zone="lvm2 lvmconf">
384 <primary sortas="b-lvmconf">lvmconf</primary>
385 </indexterm>
386 </listitem>
387 </varlistentry>
388
389 <varlistentry id="lvmdump">
390 <term><command>lvmdump</command></term>
391 <listitem>
[c627795]392 <para>
393 is a tool used to dump various information concerning
394 <application>LVM2</application>.
395 </para>
[8bc3edae]396 <indexterm zone="lvm2 lvmdump">
397 <primary sortas="b-lvmdump">lvmdump</primary>
398 </indexterm>
399 </listitem>
400 </varlistentry>
401
402 <varlistentry id="vgimportclone">
403 <term><command>vgimportclone</command></term>
404 <listitem>
[c627795]405 <para>
406 is used to import a duplicated VG (e.g. hardware snapshot).
407 </para>
[8bc3edae]408 <indexterm zone="lvm2 vgimportclone">
409 <primary sortas="b-vgimportclone">vgimportclone</primary>
410 </indexterm>
411 </listitem>
412 </varlistentry>
413
414 <varlistentry id="libdevmapper">
415 <term><filename class='libraryfile'>libdevmapper.so</filename></term>
416 <listitem>
[c627795]417 <para>
418 contains the <application>Device Mapper</application> API
419 functions.
420 </para>
[8bc3edae]421 <indexterm zone="lvm2 libdevmapper">
422 <primary sortas="c-libdevmapper">libdevmapper.so</primary>
423 </indexterm>
424 </listitem>
425 </varlistentry>
426
427 </variablelist>
428
429 </sect2>
430
431</sect1>
Note: See TracBrowser for help on using the repository browser.