e2fsprogs.xml 21 KB

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