source: chapter06/util-linux.xml@ c863747

6.0
Last change on this file since c863747 was 69993f4, checked in by Gerard Beekmans <gerard@…>, 20 years ago

Second round of edits for final release

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

  • Property mode set to 100644
File size: 20.4 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN" "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
3 <!ENTITY % general-entities SYSTEM "../general.ent">
4 %general-entities;
5]>
6<sect1 id="ch-system-util-linux" xreflabel="Util-linux" role="wrap">
7<title>Util-linux-&util-linux-version;</title>
8<?dbhtml filename="util-linux.html"?>
9
10<indexterm zone="ch-system-util-linux"><primary sortas="a-Util-linux">Util-linux</primary></indexterm>
11
12<sect2 role="package"><title/>
13<para>The Util-linux package contains miscellaneous utility programs. Among
14them are utilities for handling file systems, consoles, partitions, and
15messages.</para>
16
17<segmentedlist>
18<segtitle>&buildtime;</segtitle>
19<segtitle>&diskspace;</segtitle>
20<seglistitem><seg>0.2 SBU</seg><seg>16 MB</seg></seglistitem>
21</segmentedlist>
22
23<segmentedlist>
24<segtitle>Util-linux installation depends on</segtitle>
25<seglistitem><seg>Bash, Binutils, Coreutils,
26Diffutils, GCC, Gettext, Glibc, Grep, Make, Ncurses, Sed, and Zlib</seg></seglistitem>
27</segmentedlist>
28</sect2>
29
30<sect2 role="installation">
31<title>FHS compliance notes</title>
32
33<para>The FHS recommends using the <filename
34class="directory">/var/lib/hwclock</filename> directory instead of the
35usual <filename class="directory">/etc</filename> directory as the
36location for the <filename>adjtime</filename> file. To make the
37<command>hwclock</command> program FHS-compliant, run the
38following:</para>
39
40<screen><userinput>sed -i 's@etc/adjtime@var/lib/hwclock/adjtime@g' hwclock/hwclock.c
41mkdir -p /var/lib/hwclock</userinput></screen>
42
43</sect2>
44
45<sect2 role="installation">
46<title>Installation of Util-linux</title>
47
48<para>Util-linux has issues with the Linux 2.6 kernel series. Fix
49these issues by applying the following patch:</para>
50
51<screen><userinput>patch -Np1 -i ../util-linux-&util-linux-version;-kernel_headers-1.patch</userinput></screen>
52
53<para>Prepare Util-linux for compilation:</para>
54
55<screen><userinput>./configure</userinput></screen>
56
57<para>Compile the package:</para>
58
59<screen><userinput>make HAVE_KILL=yes HAVE_SLN=yes</userinput></screen>
60
61<para>The meaning of the make parameters:</para>
62
63<variablelist>
64<varlistentry>
65<term><parameter>HAVE_KILL=yes</parameter></term>
66<listitem><para>This prevents the
67<command>kill</command> program (already installed by Procps) from being
68built and installed again.</para></listitem>
69</varlistentry>
70
71<varlistentry>
72<term><parameter>HAVE_SLN=yes</parameter></term>
73<listitem><para>This prevents the <command>sln</command> program (a
74statically linked version of <command>ln</command> already installed
75by Glibc) from being built and installed again.</para></listitem>
76</varlistentry>
77</variablelist>
78
79<para>This package does not come with a test suite.</para>
80
81<para>Install the package:</para>
82
83<screen><userinput>make HAVE_KILL=yes HAVE_SLN=yes install</userinput></screen>
84
85</sect2>
86
87<sect2 id="contents-utillinux" role="content"><title>Contents of Util-linux</title>
88
89<segmentedlist>
90<segtitle>Installed programs</segtitle>
91<seglistitem><seg>agetty, arch, blockdev, cal, cfdisk, chkdupexe, col, colcrt,
92colrm, column, ctrlaltdel, cytune, ddate, dmesg, elvtune, fdformat, fdisk,
93fsck.cramfs, fsck.minix, getopt, hexdump, hwclock, ipcrm, ipcs, isosize, line,
94logger, look, losetup, mcookie, mkfs, mkfs.bfs, mkfs.cramfs, mkfs.minix, mkswap,
95more, mount, namei, pg, pivot_root, ramsize (link to rdev), raw, rdev, readprofile,
96rename, renice, rev, rootflags (link to rdev), script, setfdprm, setsid, setterm,
97sfdisk, swapdev, swapoff (link to swapon), swapon, tunelp, ul, umount, vidmode (link to rdev),
98whereis, and write</seg></seglistitem>
99</segmentedlist>
100
101<variablelist><bridgehead renderas="sect3">Short descriptions</bridgehead>
102<?dbfo list-presentation="list"?>
103
104<varlistentry id="agetty">
105<term><command>agetty</command></term>
106<listitem>
107<para>opens a tty port, prompts for a login name,
108and then invokes the <command>login</command> program.</para>
109<indexterm zone="ch-system-util-linux agetty"><primary sortas="b-agetty">agetty</primary></indexterm>
110</listitem>
111</varlistentry>
112
113<varlistentry id="arch">
114<term><command>arch</command></term>
115<listitem>
116<para>reports the machine's architecture.</para>
117<indexterm zone="ch-system-util-linux arch"><primary sortas="b-arch">arch</primary></indexterm>
118</listitem>
119</varlistentry>
120
121<varlistentry id="blockdev">
122<term><command>blockdev</command></term>
123<listitem>
124<para>allows users to call block device ioctls from the command line.</para>
125<indexterm zone="ch-system-util-linux blockdev"><primary sortas="b-blockdev">blockdev</primary></indexterm>
126</listitem>
127</varlistentry>
128
129<varlistentry id="cal">
130<term><command>cal</command></term>
131<listitem>
132<para>displays a simple calendar.</para>
133<indexterm zone="ch-system-util-linux cal"><primary sortas="b-cal">cal</primary></indexterm>
134</listitem>
135</varlistentry>
136
137<varlistentry id="cfdisk">
138<term><command>cfdisk</command></term>
139<listitem>
140<para>manipulates the partition table of the given device.</para>
141<indexterm zone="ch-system-util-linux cfdisk"><primary sortas="b-cfdisk">cfdisk</primary></indexterm>
142</listitem>
143</varlistentry>
144
145<varlistentry id="chkdupexe">
146<term><command>chkdupexe</command></term>
147<listitem>
148<para>finds duplicate executables.</para>
149<indexterm zone="ch-system-util-linux chkdupexe"><primary sortas="b-chkdupexe">chkdupexe</primary></indexterm>
150</listitem>
151</varlistentry>
152
153<varlistentry id="col">
154<term><command>col</command></term>
155<listitem>
156<para>filters out reverse line feeds.</para>
157<indexterm zone="ch-system-util-linux col"><primary sortas="b-col">col</primary></indexterm>
158</listitem>
159</varlistentry>
160
161<varlistentry id="colcrt">
162<term><command>colcrt</command></term>
163<listitem>
164<para>filters <command>nroff</command> output for terminals
165that lack some capabilities, such as overstriking and half-lines.</para>
166<indexterm zone="ch-system-util-linux colcrt"><primary sortas="b-colcrt">colcrt</primary></indexterm>
167</listitem>
168</varlistentry>
169
170<varlistentry id="colrm">
171<term><command>colrm</command></term>
172<listitem>
173<para>filters out the given columns.</para>
174<indexterm zone="ch-system-util-linux colrm"><primary sortas="b-colrm">colrm</primary></indexterm>
175</listitem>
176</varlistentry>
177
178<varlistentry id="column">
179<term><command>column</command></term>
180<listitem>
181<para>formats a given file into multiple columns.</para>
182<indexterm zone="ch-system-util-linux column"><primary sortas="b-column">column</primary></indexterm>
183</listitem>
184</varlistentry>
185
186<varlistentry id="ctrlaltdel">
187<term><command>ctrlaltdel</command></term>
188<listitem>
189<para>sets the function of the Ctrl+Alt+Del key combination to a hard or a
190soft reset.</para>
191<indexterm zone="ch-system-util-linux ctrlaltdel"><primary sortas="b-ctrlaltdel">ctrlaltdel</primary></indexterm>
192</listitem>
193</varlistentry>
194
195<varlistentry id="cytune">
196<term><command>cytune</command></term>
197<listitem>
198<para>tunes the parameters of the serial line drivers for
199Cyclades cards.</para>
200<indexterm zone="ch-system-util-linux cytune"><primary sortas="b-cytune">cytune</primary></indexterm>
201</listitem>
202</varlistentry>
203
204<varlistentry id="ddate">
205<term><command>ddate</command></term>
206<listitem>
207<para>gives the Discordian date or converts the given Gregorian date
208to a Discordian one.</para>
209<indexterm zone="ch-system-util-linux ddate"><primary sortas="b-ddate">ddate</primary></indexterm>
210</listitem>
211</varlistentry>
212
213<varlistentry id="dmesg">
214<term><command>dmesg</command></term>
215<listitem>
216<para>dumps the kernel boot messages.</para>
217<indexterm zone="ch-system-util-linux dmesg"><primary sortas="b-dmesg">dmesg</primary></indexterm>
218</listitem>
219</varlistentry>
220
221<varlistentry id="elvtune">
222<term><command>elvtune</command></term>
223<listitem>
224<para>tunes the performance and interactivity of a block
225device.</para>
226<indexterm zone="ch-system-util-linux elvtune"><primary sortas="b-elvtune">elvtune</primary></indexterm>
227</listitem>
228</varlistentry>
229
230<varlistentry id="fdformat">
231<term><command>fdformat</command></term>
232<listitem>
233<para>low-level formats a floppy disk.</para>
234<indexterm zone="ch-system-util-linux fdformat"><primary sortas="b-fdformat">fdformat</primary></indexterm>
235</listitem>
236</varlistentry>
237
238<varlistentry id="fdisk">
239<term><command>fdisk</command></term>
240<listitem>
241<para>manipulates the partition table of the given device.</para>
242<indexterm zone="ch-system-util-linux fdisk"><primary sortas="b-fdisk">fdisk</primary></indexterm>
243</listitem>
244</varlistentry>
245
246<varlistentry id="fsck.cramfs">
247<term><command>fsck.cramfs</command></term>
248<listitem>
249<para>performs a consistency check on the Cramfs file system on the
250given device.</para>
251<indexterm zone="ch-system-util-linux fsck.cramfs"><primary sortas="b-fsck.cramfs">fsck.cramfs</primary></indexterm>
252</listitem>
253</varlistentry>
254
255<varlistentry id="fsck.minix">
256<term><command>fsck.minix</command></term>
257<listitem>
258<para>performs a consistency check on the Minix file system on the
259given device.</para>
260<indexterm zone="ch-system-util-linux fsck.minix"><primary sortas="b-fsck.minix">fsck.minix</primary></indexterm>
261</listitem>
262</varlistentry>
263
264<varlistentry id="getopt">
265<term><command>getopt</command></term>
266<listitem>
267<para>parses options in the given command line.</para>
268<indexterm zone="ch-system-util-linux getopt"><primary sortas="b-getopt">getopt</primary></indexterm>
269</listitem>
270</varlistentry>
271
272<varlistentry id="hexdump">
273<term><command>hexdump</command></term>
274<listitem>
275<para>dumps the given file in hexadecimal or in another given format.</para>
276<indexterm zone="ch-system-util-linux hexdump"><primary sortas="b-hexdump">hexdump</primary></indexterm>
277</listitem>
278</varlistentry>
279
280<varlistentry id="hwclock">
281<term><command>hwclock</command></term>
282<listitem>
283<para>reads or sets the system's hardware clock, also called
284the Real-Time Clock (RTC)) or Basic Input-Output System (BIOS)
285clock.</para>
286<indexterm zone="ch-system-util-linux hwclock"><primary sortas="b-hwclock">hwclock</primary></indexterm>
287</listitem>
288</varlistentry>
289
290<varlistentry id="ipcrm">
291<term><command>ipcrm</command></term>
292<listitem>
293<para>removes the given Inter-Process Communication (IPC) resource.</para>
294<indexterm zone="ch-system-util-linux ipcrm"><primary sortas="b-ipcrm">ipcrm</primary></indexterm>
295</listitem>
296</varlistentry>
297
298<varlistentry id="ipcs">
299<term><command>ipcs</command></term>
300<listitem>
301<para>provides IPC status information.</para>
302<indexterm zone="ch-system-util-linux ipcs"><primary sortas="b-ipcs">ipcs</primary></indexterm>
303</listitem>
304</varlistentry>
305
306<varlistentry id="isosize">
307<term><command>isosize</command></term>
308<listitem>
309<para>reports the size of an iso9660 file system.</para>
310<indexterm zone="ch-system-util-linux isosize"><primary sortas="b-isosize">isosize</primary></indexterm>
311</listitem>
312</varlistentry>
313
314<varlistentry id="line">
315<term><command>line</command></term>
316<listitem>
317<para>copies a single line.</para>
318<indexterm zone="ch-system-util-linux line"><primary sortas="b-line">line</primary></indexterm>
319</listitem>
320</varlistentry>
321
322<varlistentry id="logger">
323<term><command>logger</command></term>
324<listitem>
325<para>enters the given message into the system log.</para>
326<indexterm zone="ch-system-util-linux logger"><primary sortas="b-logger">logger</primary></indexterm>
327</listitem>
328</varlistentry>
329
330<varlistentry id="look">
331<term><command>look</command></term>
332<listitem>
333<para>displays lines that begin with the given string.</para>
334<indexterm zone="ch-system-util-linux look"><primary sortas="b-look">look</primary></indexterm>
335</listitem>
336</varlistentry>
337
338<varlistentry id="losetup">
339<term><command>losetup</command></term>
340<listitem>
341<para>sets up and controls loop devices.</para>
342<indexterm zone="ch-system-util-linux losetup"><primary sortas="b-losetup">losetup</primary></indexterm>
343</listitem>
344</varlistentry>
345
346<varlistentry id="mcookie">
347<term><command>mcookie</command></term>
348<listitem>
349<para>generates magic cookies (128-bit random hexadecimal numbers) for
350<command>xauth</command>.</para>
351<indexterm zone="ch-system-util-linux mcookie"><primary sortas="b-mcookie">mcookie</primary></indexterm>
352</listitem>
353</varlistentry>
354
355<varlistentry id="mkfs">
356<term><command>mkfs</command></term>
357<listitem>
358<para>builds a file system on a device (usually a hard disk
359partition).</para>
360<indexterm zone="ch-system-util-linux mkfs"><primary sortas="b-mkfs">mkfs</primary></indexterm>
361</listitem>
362</varlistentry>
363
364<varlistentry id="mkfs.bfs">
365<term><command>mkfs.bfs</command></term>
366<listitem>
367<para>creates an Santa Cruz Operations (SCO) bfs file system.</para>
368<indexterm zone="ch-system-util-linux mkfs.bfs"><primary sortas="b-mkfs.bfs">mkfs.bfs</primary></indexterm>
369</listitem>
370</varlistentry>
371
372<varlistentry id="mkfs.cramfs">
373<term><command>mkfs.cramfs</command></term>
374<listitem>
375<para>creates a cramfs file system.</para>
376<indexterm zone="ch-system-util-linux mkfs.cramfs"><primary sortas="b-mkfs.cramfs">mkfs.cramfs</primary></indexterm>
377</listitem>
378</varlistentry>
379
380<varlistentry id="mkfs.minix">
381<term><command>mkfs.minix</command></term>
382<listitem>
383<para>creates a Minix file system.</para>
384<indexterm zone="ch-system-util-linux mkfs.minix"><primary sortas="b-mkfs.minix">mkfs.minix</primary></indexterm>
385</listitem>
386</varlistentry>
387
388<varlistentry id="mkswap">
389<term><command>mkswap</command></term>
390<listitem>
391<para>initializes the given device or file to be used as a swap area.</para>
392<indexterm zone="ch-system-util-linux mkswap"><primary sortas="b-mkswap">mkswap</primary></indexterm>
393</listitem>
394</varlistentry>
395
396<varlistentry id="more">
397<term><command>more</command></term>
398<listitem>
399<para>a filter for paging through text one screen at a time.</para>
400<indexterm zone="ch-system-util-linux more"><primary sortas="b-more">more</primary></indexterm>
401</listitem>
402</varlistentry>
403
404<varlistentry id="mount">
405<term><command>mount</command></term>
406<listitem>
407<para>attaches the file system on the given device to a specified
408directory in the file-system tree.</para>
409<indexterm zone="ch-system-util-linux mount"><primary sortas="b-mount">mount</primary></indexterm>
410</listitem>
411</varlistentry>
412
413<varlistentry id="namei">
414<term><command>namei</command></term>
415<listitem>
416<para>shows the symbolic links in the given pathnames.</para>
417<indexterm zone="ch-system-util-linux namei"><primary sortas="b-namei">namei</primary></indexterm>
418</listitem>
419</varlistentry>
420
421<varlistentry id="pg">
422<term><command>pg</command></term>
423<listitem>
424<para>displays a text file one screen full at a time.</para>
425<indexterm zone="ch-system-util-linux pg"><primary sortas="b-pg">pg</primary></indexterm>
426</listitem>
427</varlistentry>
428
429<varlistentry id="pivot_root">
430<term><command>pivot_root</command></term>
431<listitem>
432<para>makes the given file system the new root file system of the
433current process.</para>
434<indexterm zone="ch-system-util-linux pivot_root"><primary sortas="b-pivot_root">pivot_root</primary></indexterm>
435</listitem>
436</varlistentry>
437
438<varlistentry id="ramsize">
439<term><command>ramsize</command></term>
440<listitem>
441<para>sets the size of the RAM disk in a bootable image.</para>
442<indexterm zone="ch-system-util-linux ramsize"><primary sortas="b-ramsize">ramsize</primary></indexterm>
443</listitem>
444</varlistentry>
445
446<varlistentry id="rdev">
447<term><command>rdev</command></term>
448<listitem>
449<para>queries and sets the root device, among other things, in a
450bootable image.</para>
451<indexterm zone="ch-system-util-linux rdev"><primary sortas="b-rdev">rdev</primary></indexterm>
452</listitem>
453</varlistentry>
454
455<varlistentry id="readprofile">
456<term><command>readprofile</command></term>
457<listitem>
458<para>reads kernel profiling information.</para>
459<indexterm zone="ch-system-util-linux readprofile"><primary sortas="b-readprofile">readprofile</primary></indexterm>
460</listitem>
461</varlistentry>
462
463<varlistentry id="rename">
464<term><command>rename</command></term>
465<listitem>
466<para>renames the given files, replacing a given string with another.</para>
467<indexterm zone="ch-system-util-linux rename"><primary sortas="b-rename">rename</primary></indexterm>
468</listitem>
469</varlistentry>
470
471<varlistentry id="renice">
472<term><command>renice</command></term>
473<listitem>
474<para>alters the priority of running processes.</para>
475<indexterm zone="ch-system-util-linux renice"><primary sortas="b-renice">renice</primary></indexterm>
476</listitem>
477</varlistentry>
478
479<varlistentry id="rev">
480<term><command>rev</command></term>
481<listitem>
482<para>reverses the lines of a given file.</para>
483<indexterm zone="ch-system-util-linux rev"><primary sortas="b-rev">rev</primary></indexterm>
484</listitem>
485</varlistentry>
486
487<varlistentry id="rootflags">
488<term><command>rootflags</command></term>
489<listitem>
490<para>sets the rootflags in a bootable image.</para>
491<indexterm zone="ch-system-util-linux rootflags"><primary sortas="b-rootflags">rootflags</primary></indexterm>
492</listitem>
493</varlistentry>
494
495<varlistentry id="script">
496<term><command>script</command></term>
497<listitem>
498<para>makes a typescript of a terminal session (everything printed to
499the terminal.</para>
500<indexterm zone="ch-system-util-linux script"><primary sortas="b-script">script</primary></indexterm>
501</listitem>
502</varlistentry>
503
504<varlistentry id="setfdprm">
505<term><command>setfdprm</command></term>
506<listitem>
507<para>sets user-provided floppy disk parameters.</para>
508<indexterm zone="ch-system-util-linux setfdprm"><primary sortas="b-setfdprm">setfdprm</primary></indexterm>
509</listitem>
510</varlistentry>
511
512<varlistentry id="setsid">
513<term><command>setsid</command></term>
514<listitem>
515<para>runs the given program in a new session.</para>
516<indexterm zone="ch-system-util-linux setsid"><primary sortas="b-setsid">setsid</primary></indexterm>
517</listitem>
518</varlistentry>
519
520<varlistentry id="setterm">
521<term><command>setterm</command></term>
522<listitem>
523<para>sets terminal attributes.</para>
524<indexterm zone="ch-system-util-linux setterm"><primary sortas="b-setterm">setterm</primary></indexterm>
525</listitem>
526</varlistentry>
527
528<varlistentry id="sfdisk">
529<term><command>sfdisk</command></term>
530<listitem>
531<para>a disk partition table manipulator.</para>
532<indexterm zone="ch-system-util-linux sfdisk"><primary sortas="b-sfdisk">sfdisk</primary></indexterm>
533</listitem>
534</varlistentry>
535
536<varlistentry id="swapdev">
537<term><command>swapdev</command></term>
538<listitem>
539<para>sets the swap device in a bootable image.</para>
540<indexterm zone="ch-system-util-linux swapdev"><primary sortas="b-swapdev">swapdev</primary></indexterm>
541</listitem>
542</varlistentry>
543
544<varlistentry id="swapoff">
545<term><command>swapoff</command></term>
546<listitem>
547<para>disables devices and files for paging and swapping.</para>
548<indexterm zone="ch-system-util-linux swapoff"><primary sortas="b-swapoff">swapoff</primary></indexterm>
549</listitem>
550</varlistentry>
551
552<varlistentry id="swapon">
553<term><command>swapon</command></term>
554<listitem>
555<para>enables devices and files for paging and swapping.</para>
556<indexterm zone="ch-system-util-linux swapon"><primary sortas="b-swapon">swapon</primary></indexterm>
557</listitem>
558</varlistentry>
559
560<varlistentry id="tunelp">
561<term><command>tunelp</command></term>
562<listitem>
563<para>tunes the parameters of the line printer.</para>
564<indexterm zone="ch-system-util-linux tunelp"><primary sortas="b-tunelp">tunelp</primary></indexterm>
565</listitem>
566</varlistentry>
567
568<varlistentry id="ul">
569<term><command>ul</command></term>
570<listitem>
571<para>a filter for translating underscores into
572escape sequences indicating underlining for the terminal in use.</para>
573<indexterm zone="ch-system-util-linux ul"><primary sortas="b-ul">ul</primary></indexterm>
574</listitem>
575</varlistentry>
576
577<varlistentry id="umount">
578<term><command>umount</command></term>
579<listitem>
580<para>disconnects a file system from the system's file tree.</para>
581<indexterm zone="ch-system-util-linux umount"><primary sortas="b-umount">umount</primary></indexterm>
582</listitem>
583</varlistentry>
584
585<varlistentry id="vidmode">
586<term><command>vidmode</command></term>
587<listitem>
588<para>sets the video mode in a bootable image.</para>
589<indexterm zone="ch-system-util-linux vidmode"><primary sortas="b-vidmode">vidmode</primary></indexterm>
590</listitem>
591</varlistentry>
592
593<varlistentry id="whereis">
594<term><command>whereis</command></term>
595<listitem>
596<para>reports the location of binary, the source, and the manual page
597for the given command.</para>
598<indexterm zone="ch-system-util-linux whereis"><primary sortas="b-whereis">whereis</primary></indexterm>
599</listitem>
600</varlistentry>
601
602<varlistentry id="write">
603<term><command>write</command></term>
604<listitem>
605<para>sends a message to the given user
606<emphasis>if</emphasis> that user has not disabled receipt of such messages.</para>
607<indexterm zone="ch-system-util-linux write"><primary sortas="b-write">write</primary></indexterm>
608</listitem>
609</varlistentry>
610</variablelist>
611
612</sect2>
613
614</sect1>
615
Note: See TracBrowser for help on using the repository browser.