source: postlfs/filesystems/lvm2.xml@ a5bc3d2

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 9.1 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 a5bc3d2 was a5bc3d2, checked in by Bruce Dubbs <bdubbs@…>, 4 years ago

Update to nspr-4.24.
Update to PyYAML-5.2.
Update to tcsh-6.22.01.
Update to LVM2.2.03.07.

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

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