source: chapter06/e2fsprogs.xml@ 4ae2e7a

10.0 10.0-rc1 10.1 10.1-rc1 11.0 11.0-rc1 11.0-rc2 11.0-rc3 11.1 11.1-rc1 11.2 11.2-rc1 11.3 11.3-rc1 12.0 12.0-rc1 12.1 12.1-rc1 7.6 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 arm bdubbs/gcc13 ml-11.0 multilib renodr/libudev-from-systemd s6-init trunk xry111/arm64 xry111/arm64-12.0 xry111/clfs-ng xry111/lfs-next xry111/loongarch xry111/loongarch-12.0 xry111/loongarch-12.1 xry111/mips64el xry111/pip3 xry111/rust-wip-20221008 xry111/update-glibc
Last change on this file since 4ae2e7a was 4ae2e7a, checked in by Bruce Dubbs <bdubbs@…>, 10 years ago

Update to iproute2-3.15.0.
Update to linux-3.15.
Gettext-0.19.1.
Fix test failure in e2fsprogs.

git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@10574 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689

  • Property mode set to 100644
File size: 21.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
8<sect1 id="ch-system-e2fsprogs" role="wrap">
9 <?dbhtml filename="e2fsprogs.html"?>
10
11 <sect1info condition="script">
12 <productname>e2fsprogs</productname>
13 <productnumber>&e2fsprogs-version;</productnumber>
14 <address>&e2fsprogs-url;</address>
15 </sect1info>
16
17 <title>E2fsprogs-&e2fsprogs-version;</title>
18
19 <indexterm zone="ch-system-e2fsprogs">
20 <primary sortas="a-E2fsprogs">E2fsprogs</primary>
21 </indexterm>
22
23 <sect2 role="package">
24 <title/>
25
26 <para>The E2fsprogs package contains the utilities for handling the
27 <systemitem class="filesystem">ext2</systemitem> file system. It also
28 supports the <systemitem class="filesystem">ext3</systemitem> and
29 <systemitem class="filesystem">ext4</systemitem> journaling
30 file systems.</para>
31
32 <segmentedlist>
33 <segtitle>&buildtime;</segtitle>
34 <segtitle>&diskspace;</segtitle>
35
36 <seglistitem>
37 <seg>&e2fsprogs-ch6-sbu;</seg>
38 <seg>&e2fsprogs-ch6-du;</seg>
39 </seglistitem>
40 </segmentedlist>
41
42 </sect2>
43
44 <sect2 role="installation">
45 <title>Installation of E2fsprogs</title>
46
47 <para>First fix some problems with running regression tests in the LFS chroot
48 environment:</para>
49
50<screen><userinput remap="pre">patch -Np1 -i ../&e2fsprogs-fix-test-patch;
51sed -i -e 's|^LD_LIBRARY_PATH.*|&amp;:/tools/lib|' tests/test_config</userinput></screen>
52
53 <para>The E2fsprogs documentation recommends that the package be built in
54 a subdirectory of the source tree: </para>
55
56<screen><userinput remap="pre">mkdir -v build
57cd build</userinput></screen>
58
59 <para>Prepare E2fsprogs for compilation:</para>
60
61<screen><userinput remap="configure">LIBS=-L/tools/lib \
62CFLAGS=-I/tools/include \
63PKG_CONFIG_PATH=/tools/lib/pkgconfig \
64../configure --prefix=/usr \
65 --bindir=/bin \
66 --with-root-prefix="" \
67 --enable-elf-shlibs \
68 --disable-libblkid \
69 --disable-libuuid \
70 --disable-uuidd \
71 --disable-fsck</userinput></screen>
72
73 <variablelist>
74 <title>The meaning of the environment variable and configure options:</title>
75
76 <varlistentry>
77 <term><parameter>PKG_CONFIG_PATH, LIBS, CFLAGS</parameter></term>
78 <listitem>
79 <para>These variables enable e2fsprogs to be built using the
80 <xref linkend="ch-tools-util-linux"/> package built earlier.</para>
81 </listitem>
82 </varlistentry>
83
84 <varlistentry>
85 <term><parameter>--with-root-prefix=""</parameter> and
86 <parameter>--bindir=/bin</parameter></term>
87 <listitem>
88 <para>Certain programs (such as the <command>e2fsck</command>
89 program) are considered essential programs. When, for example,
90 <filename class="directory">/usr</filename> is not mounted, these
91 programs still need to be available. They belong in directories
92 like <filename class="directory">/lib</filename> and <filename
93 class="directory">/sbin</filename>. If this option is not passed
94 to E2fsprogs' configure, the programs are installed into the
95 <filename class="directory">/usr</filename> directory.</para>
96 </listitem>
97 </varlistentry>
98
99 <varlistentry>
100 <term><parameter>--enable-elf-shlibs</parameter></term>
101 <listitem>
102 <para>This creates the shared libraries which some programs
103 in this package use.</para>
104 </listitem>
105 </varlistentry>
106
107 <varlistentry>
108 <term><parameter>--disable-*</parameter></term>
109 <listitem>
110 <para>This prevents E2fsprogs from building and installing the
111 <systemitem class="library">libuuid</systemitem> and
112 <systemitem class="library">libblkid</systemitem> libraries, the
113 <systemitem class="daemon">uuidd</systemitem> daemon, and the
114 <command>fsck</command> wrapper, as Util-Linux installed all of
115 them earlier.</para>
116 </listitem>
117 </varlistentry>
118
119 </variablelist>
120
121 <para>Compile the package:</para>
122
123<screen><userinput remap="make">make</userinput></screen>
124
125 <para>To set up the test suite we need to temporarily copy
126 a library from /tools/lib so the test programs can find it.
127 To run the tests, issue:</para>
128
129<screen><userinput remap="test">cp -v /tools/lib/libblkid.so.1 /lib
130make check
131rm -v /lib/libblkid.so.1</userinput></screen>
132
133 <para>One of the E2fsprogs tests will attempt to allocate 256 MB of memory.
134 If you do not have significantly more RAM than this, be sure to enable
135 sufficient swap space for the test. See <xref
136 linkend="space-creatingfilesystem"/> and <xref linkend="space-mounting"/>
137 for details on creating and enabling swap space.</para>
138
139 <para>Install the binaries, documentation, and shared libraries:</para>
140
141<screen><userinput remap="install">make install</userinput></screen>
142
143 <para>Install the static libraries and headers:</para>
144
145<screen><userinput remap="install">make install-libs</userinput></screen>
146
147 <para>Make the installed static libraries writable so debugging symbols can
148 be removed later:</para>
149
150<screen><userinput remap="install">chmod -v u+w /usr/lib/{libcom_err,libe2p,libext2fs,libss}.a</userinput></screen>
151
152 <para>This package installs a gzipped
153 <filename class="extension">.info</filename> file but doesn't update the
154 system-wide <filename>dir</filename> file. Unzip this file and then update
155 the system <filename>dir</filename> file using the following
156 commands.</para>
157
158<screen><userinput remap="install">gunzip -v /usr/share/info/libext2fs.info.gz
159install-info --dir-file=/usr/share/info/dir /usr/share/info/libext2fs.info</userinput></screen>
160
161 <para>If desired, create and install some additional documentation by
162 issuing the following commands:</para>
163
164<screen><userinput remap="install">makeinfo -o doc/com_err.info ../lib/et/com_err.texinfo
165install -v -m644 doc/com_err.info /usr/share/info
166install-info --dir-file=/usr/share/info/dir /usr/share/info/com_err.info</userinput></screen>
167 </sect2>
168
169 <sect2 id="contents-e2fsprogs" role="content">
170 <title>Contents of E2fsprogs</title>
171
172 <segmentedlist>
173 <segtitle>Installed programs</segtitle>
174 <segtitle>Installed libraries</segtitle>
175 <segtitle>Installed directory</segtitle>
176
177 <seglistitem>
178 <seg>badblocks, chattr, compile_et, debugfs, dumpe2fs,e2freefrag,
179 e2fsck, e2image, e2label, e2undo, e4defrag, filefrag, fsck.ext2,
180 fsck.ext3, fsck.ext4, fsck.ext4dev, logsave, lsattr, mk_cmds, mke2fs,
181 mkfs.ext2, mkfs.ext3, mkfs.ext4, mkfs.ext4dev,
182 resize2fs, and tune2fs</seg>
183 <seg>libcom_err.{a,so}, libe2p.{a,so}, libext2fs.{a,so},
184 libquota.a, and libss.{a,so}</seg>
185 <seg>/usr/include/e2p, /usr/include/et, /usr/include/ext2fs,
186 /usr/include/quota, /usr/include/ss, /usr/share/et, /usr/share/ss</seg>
187 </seglistitem>
188 </segmentedlist>
189
190 <variablelist>
191 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
192 <?dbfo list-presentation="list"?>
193 <?dbhtml list-presentation="table"?>
194
195 <varlistentry id="badblocks">
196 <term><command>badblocks</command></term>
197 <listitem>
198 <para>Searches a device (usually a disk partition) for bad
199 blocks</para>
200 <indexterm zone="ch-system-e2fsprogs badblocks">
201 <primary sortas="b-badblocks">badblocks</primary>
202 </indexterm>
203 </listitem>
204 </varlistentry>
205
206 <varlistentry id="chattr">
207 <term><command>chattr</command></term>
208 <listitem>
209 <para>Changes the attributes of files on an <systemitem
210 class="filesystem">ext2</systemitem> file system; it also
211 changes <systemitem class="filesystem">ext3</systemitem>
212 file systems, the journaling version of <systemitem
213 class="filesystem">ext2</systemitem> file systems</para>
214 <indexterm zone="ch-system-e2fsprogs chattr">
215 <primary sortas="b-chattr">chattr</primary>
216 </indexterm>
217 </listitem>
218 </varlistentry>
219
220 <varlistentry id="compile_et">
221 <term><command>compile_et</command></term>
222 <listitem>
223 <para>An error table compiler; it converts a table of error-code
224 names and messages into a C source file suitable for use with the
225 <filename class="libraryfile">com_err</filename> library</para>
226 <indexterm zone="ch-system-e2fsprogs compile_et">
227 <primary sortas="b-compile_et">compile_et</primary>
228 </indexterm>
229 </listitem>
230 </varlistentry>
231
232 <varlistentry id="debugfs">
233 <term><command>debugfs</command></term>
234 <listitem>
235 <para>A file system debugger; it can be used to examine and change
236 the state of an <systemitem class="filesystem">ext2</systemitem>
237 file system</para>
238 <indexterm zone="ch-system-e2fsprogs debugfs">
239 <primary sortas="b-debugfs">debugfs</primary>
240 </indexterm>
241 </listitem>
242 </varlistentry>
243
244 <varlistentry id="dumpe2fs">
245 <term><command>dumpe2fs</command></term>
246 <listitem>
247 <para>Prints the super block and blocks group information for the
248 file system present on a given device</para>
249 <indexterm zone="ch-system-e2fsprogs dumpe2fs">
250 <primary sortas="b-dumpe2fs">dumpe2fs</primary>
251 </indexterm>
252 </listitem>
253 </varlistentry>
254
255 <varlistentry id="e2freefrag">
256 <term><command>e2freefrag</command></term>
257 <listitem>
258 <para> Reports free space fragmentation information</para>
259 <indexterm zone="ch-system-e2fsprogs e2freefrag">
260 <primary sortas="b-e2freefrag">e2freefrag</primary>
261 </indexterm>
262 </listitem>
263 </varlistentry>
264
265 <varlistentry id="e2fsck">
266 <term><command>e2fsck</command></term>
267 <listitem>
268 <para>Is used to check, and optionally repair <systemitem
269 class="filesystem">ext2</systemitem> file systems and <systemitem
270 class="filesystem">ext3</systemitem> file systems</para>
271 <indexterm zone="ch-system-e2fsprogs e2fsck">
272 <primary sortas="b-e2fsck">e2fsck</primary>
273 </indexterm>
274 </listitem>
275 </varlistentry>
276
277 <varlistentry id="e2image">
278 <term><command>e2image</command></term>
279 <listitem>
280 <para>Is used to save critical <systemitem
281 class="filesystem">ext2</systemitem> file system data to a file</para>
282 <indexterm zone="ch-system-e2fsprogs e2image">
283 <primary sortas="b-e2image">e2image</primary>
284 </indexterm>
285 </listitem>
286 </varlistentry>
287
288 <varlistentry id="e2label">
289 <term><command>e2label</command></term>
290 <listitem>
291 <para>Displays or changes the file system label on the <systemitem
292 class="filesystem">ext2</systemitem> file system present on a given
293 device</para>
294 <indexterm zone="ch-system-e2fsprogs e2label">
295 <primary sortas="b-e2label">e2label</primary>
296 </indexterm>
297 </listitem>
298 </varlistentry>
299
300 <varlistentry id="e2undo">
301 <term><command>e2undo</command></term>
302 <listitem>
303 <para>Replays the undo log undo_log for an ext2/ext3/ext4 filesystem
304 found on a device. This can be used to undo a failed operation by an
305 e2fsprogs program.</para>
306 <indexterm zone="ch-system-e2fsprogs e2undo">
307 <primary sortas="b-e2undo">e2undo</primary>
308 </indexterm>
309 </listitem>
310 </varlistentry>
311
312 <varlistentry id="e4defrag">
313 <term><command>e4defrag</command></term>
314 <listitem>
315 <para>Online defragmenter for ext4 filesystems</para>
316 <indexterm zone="ch-system-e2fsprogs e4defrag">
317 <primary sortas="b-e4defrag">e4defrag</primary>
318 </indexterm>
319 </listitem>
320 </varlistentry>
321
322 <varlistentry id="filefrag">
323 <term><command>filefrag</command></term>
324 <listitem>
325 <para>Reports on how badly fragmented a particular file might be</para>
326 <indexterm zone="ch-system-e2fsprogs filefrag">
327 <primary sortas="b-filefrag">filefrag</primary>
328 </indexterm>
329 </listitem>
330 </varlistentry>
331
332 <varlistentry id="fsck.ext2">
333 <term><command>fsck.ext2</command></term>
334 <listitem>
335 <para>By default checks <systemitem class="filesystem">ext2</systemitem>
336 file systems. This is a hard link to <command>e2fsck</command>.</para>
337 <indexterm zone="ch-system-e2fsprogs fsck.ext2">
338 <primary sortas="b-fsck.ext2">fsck.ext2</primary>
339 </indexterm>
340 </listitem>
341 </varlistentry>
342
343 <varlistentry id="fsck.ext3">
344 <term><command>fsck.ext3</command></term>
345 <listitem>
346 <para>By default checks <systemitem class="filesystem">ext3</systemitem>
347 file systems. This is a hard link to <command>e2fsck</command>.</para>
348 <indexterm zone="ch-system-e2fsprogs fsck.ext3">
349 <primary sortas="b-fsck.ext3">fsck.ext3</primary>
350 </indexterm>
351 </listitem>
352 </varlistentry>
353
354 <varlistentry id="fsck.ext4">
355 <term><command>fsck.ext4</command></term>
356 <listitem>
357 <para>By default checks <systemitem class="filesystem">ext4</systemitem>
358 file systems. This is a hard link to <command>e2fsck</command>.</para>
359 <indexterm zone="ch-system-e2fsprogs fsck.ext4">
360 <primary sortas="b-fsck.ext4">fsck.ext4</primary>
361 </indexterm>
362 </listitem>
363 </varlistentry>
364
365 <varlistentry id="fsck.ext4dev">
366 <term><command>fsck.ext4dev</command></term>
367 <listitem>
368 <para>By default checks <systemitem class="filesystem">ext4</systemitem>
369 development file systems. This is a hard link to
370 <command>e2fsck</command>.</para>
371 <indexterm zone="ch-system-e2fsprogs fsck.ext4dev">
372 <primary sortas="b-fsck.ext4dev">fsck.ext4dev</primary>
373 </indexterm>
374 </listitem>
375 </varlistentry>
376
377 <varlistentry id="logsave">
378 <term><command>logsave</command></term>
379 <listitem>
380 <para>Saves the output of a command in a log file</para>
381 <indexterm zone="ch-system-e2fsprogs logsave">
382 <primary sortas="b-logsave">logsave</primary>
383 </indexterm>
384 </listitem>
385 </varlistentry>
386
387 <varlistentry id="lsattr">
388 <term><command>lsattr</command></term>
389 <listitem>
390 <para>Lists the attributes of files on a second extended file
391 system</para>
392 <indexterm zone="ch-system-e2fsprogs lsattr">
393 <primary sortas="b-lsattr">lsattr</primary>
394 </indexterm>
395 </listitem>
396 </varlistentry>
397
398 <varlistentry id="mk_cmds">
399 <term><command>mk_cmds</command></term>
400 <listitem>
401 <para>Converts a table of command names and help messages into a C
402 source file suitable for use with the <filename
403 class="libraryfile">libss</filename> subsystem library</para>
404 <indexterm zone="ch-system-e2fsprogs mk_cmds">
405 <primary sortas="b-mk_cmds">mk_cmds</primary>
406 </indexterm>
407 </listitem>
408 </varlistentry>
409
410 <varlistentry id="mke2fs">
411 <term><command>mke2fs</command></term>
412 <listitem>
413 <para>Creates an <systemitem class="filesystem">ext2</systemitem>
414 or <systemitem class="filesystem">ext3</systemitem> file system on
415 the given device</para>
416 <indexterm zone="ch-system-e2fsprogs mke2fs">
417 <primary sortas="b-mke2fs">mke2fs</primary>
418 </indexterm>
419 </listitem>
420 </varlistentry>
421
422 <varlistentry id="mkfs.ext2">
423 <term><command>mkfs.ext2</command></term>
424 <listitem>
425 <para>By default creates <systemitem class="filesystem">ext2</systemitem>
426 file systems. This is a hard link to <command>mke2fs</command>.</para>
427 <indexterm zone="ch-system-e2fsprogs mkfs.ext2">
428 <primary sortas="b-mkfs.ext2">mkfs.ext2</primary>
429 </indexterm>
430 </listitem>
431 </varlistentry>
432
433 <varlistentry id="mkfs.ext3">
434 <term><command>mkfs.ext3</command></term>
435 <listitem>
436 <para>By default creates <systemitem class="filesystem">ext3</systemitem>
437 file systems. This is a hard link to <command>mke2fs</command>.</para>
438 <indexterm zone="ch-system-e2fsprogs mkfs.ext3">
439 <primary sortas="b-mkfs.ext3">mkfs.ext3</primary>
440 </indexterm>
441 </listitem>
442 </varlistentry>
443
444 <varlistentry id="mkfs.ext4">
445 <term><command>mkfs.ext4</command></term>
446 <listitem>
447 <para>By default creates <systemitem class="filesystem">ext4</systemitem>
448 file systems. This is a hard link to <command>mke2fs</command>.</para>
449 <indexterm zone="ch-system-e2fsprogs mkfs.ext4">
450 <primary sortas="b-mkfs.ext4">mkfs.ext4</primary>
451 </indexterm>
452 </listitem>
453 </varlistentry>
454
455 <varlistentry id="mkfs.ext4dev">
456 <term><command>mkfs.ext4dev</command></term>
457 <listitem>
458 <para>By default creates <systemitem class="filesystem">ext4</systemitem>
459 development file systems. This is a hard link to <command>mke2fs</command>.</para>
460 <indexterm zone="ch-system-e2fsprogs mkfs.ext4dev">
461 <primary sortas="b-mkfs.ext4dev">mkfs.ext4dev</primary>
462 </indexterm>
463 </listitem>
464 </varlistentry>
465
466 <varlistentry id="mklost-found">
467 <term><command>mklost+found</command></term>
468 <listitem>
469 <para>Used to create a <filename class="directory">lost+found</filename>
470 directory on an <systemitem class="filesystem">ext2</systemitem> file
471 system; it pre-allocates disk blocks to this directory to lighten the
472 task of <command>e2fsck</command></para>
473 <indexterm zone="ch-system-e2fsprogs mklost-found">
474 <primary sortas="b-mklost+found">mklost+found</primary>
475 </indexterm>
476 </listitem>
477 </varlistentry>
478
479 <varlistentry id="resize2fs">
480 <term><command>resize2fs</command></term>
481 <listitem>
482 <para>Can be used to enlarge or shrink an <systemitem
483 class="filesystem">ext2</systemitem> file system</para>
484 <indexterm zone="ch-system-e2fsprogs resize2fs">
485 <primary sortas="b-resize2fs">resize2fs</primary>
486 </indexterm>
487 </listitem>
488 </varlistentry>
489
490 <varlistentry id="tune2fs">
491 <term><command>tune2fs</command></term>
492 <listitem>
493 <para>Adjusts tunable file system parameters on an <systemitem
494 class="filesystem">ext2</systemitem> file system</para>
495 <indexterm zone="ch-system-e2fsprogs tune2fs">
496 <primary sortas="b-tune2fs">tune2fs</primary>
497 </indexterm>
498 </listitem>
499 </varlistentry>
500
501 <varlistentry id="libcom_err">
502 <term><filename class="libraryfile">libcom_err</filename></term>
503 <listitem>
504 <para>The common error display routine</para>
505 <indexterm zone="ch-system-e2fsprogs libcom_err">
506 <primary sortas="c-libcom_err">libcom_err</primary>
507 </indexterm>
508 </listitem>
509 </varlistentry>
510
511 <varlistentry id="libe2p">
512 <term><filename class="libraryfile">libe2p</filename></term>
513 <listitem>
514 <para>Used by <command>dumpe2fs</command>, <command>chattr</command>,
515 and <command>lsattr</command></para>
516 <indexterm zone="ch-system-e2fsprogs libe2p">
517 <primary sortas="c-libe2p">libe2p</primary>
518 </indexterm>
519 </listitem>
520 </varlistentry>
521
522 <varlistentry id="libext2fs">
523 <term><filename class="libraryfile">libext2fs</filename></term>
524 <listitem>
525 <para>Contains routines to enable user-level programs to manipulate an
526 <systemitem class="filesystem">ext2</systemitem> file system</para>
527 <indexterm zone="ch-system-e2fsprogs libext2fs">
528 <primary sortas="c-libext2fs">libext2fs</primary>
529 </indexterm>
530 </listitem>
531 </varlistentry>
532
533 <varlistentry id="libquota">
534 <term><filename class="libraryfile">libquota</filename></term>
535 <listitem>
536 <para>Provides an interface for creating and updating quota files
537 and ext4 superblock fields</para>
538 <indexterm zone="ch-system-e2fsprogs libquota">
539 <primary sortas="c-libquota">libquota</primary>
540 </indexterm>
541 </listitem>
542 </varlistentry>
543
544 <varlistentry id="libss">
545 <term><filename class="libraryfile">libss</filename></term>
546 <listitem>
547 <para>Used by <command>debugfs</command></para>
548 <indexterm zone="ch-system-e2fsprogs libss">
549 <primary sortas="c-libss">libss</primary>
550 </indexterm>
551 </listitem>
552 </varlistentry>
553
554 </variablelist>
555
556 </sect2>
557
558</sect1>
Note: See TracBrowser for help on using the repository browser.