coreutils.xml 42 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240
  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-coreutils" role="wrap">
  8. <?dbhtml filename="coreutils.html"?>
  9. <sect1info condition="script">
  10. <productname>coreutils</productname>
  11. <productnumber>&coreutils-version;</productnumber>
  12. <address>&coreutils-url;</address>
  13. </sect1info>
  14. <title>Coreutils-&coreutils-version;</title>
  15. <indexterm zone="ch-system-coreutils">
  16. <primary sortas="a-Coreutils">Coreutils</primary>
  17. </indexterm>
  18. <sect2 role="package">
  19. <title/>
  20. <para>The Coreutils package contains utilities for showing and setting the
  21. basic system characteristics.</para>
  22. <segmentedlist>
  23. <segtitle>&buildtime;</segtitle>
  24. <segtitle>&diskspace;</segtitle>
  25. <seglistitem>
  26. <seg>&coreutils-ch6-sbu;</seg>
  27. <seg>&coreutils-ch6-du;</seg>
  28. </seglistitem>
  29. </segmentedlist>
  30. </sect2>
  31. <sect2 role="installation">
  32. <title>Installation of Coreutils</title>
  33. <!--
  34. <para>First, fix a segfault in <command>shuf</command> program:</para>
  35. <screen><userinput remap="pre">patch -Np1 -i ../&coreutils-shuf-segfault-patch;</userinput></screen>
  36. -->
  37. <para>POSIX requires that programs from Coreutils recognize character
  38. boundaries correctly even in multibyte locales. The following patch fixes
  39. this non-compliance and other internationalization-related bugs.</para>
  40. <screen><userinput remap="pre">patch -Np1 -i ../&coreutils-i18n-patch;</userinput></screen>
  41. <note>
  42. <para>In the past, many bugs were found in this patch. When reporting new
  43. bugs to Coreutils maintainers, please check first if they are reproducible
  44. without this patch.</para>
  45. </note>
  46. <para>Now prepare Coreutils for compilation:</para>
  47. <screen><userinput remap="configure">FORCE_UNSAFE_CONFIGURE=1 ./configure \
  48. --prefix=/usr \
  49. --enable-no-install-program=kill,uptime</userinput></screen>
  50. <variablelist>
  51. <title>The meaning of the configure options:</title>
  52. <varlistentry>
  53. <term><envar>FORCE_UNSAFE_CONFIGURE=1</envar></term>
  54. <listitem>
  55. <para>This environment variable allows the package to be
  56. built as the root user.
  57. </para>
  58. </listitem>
  59. </varlistentry>
  60. <varlistentry>
  61. <term><parameter>--enable-no-install-program=kill,uptime</parameter></term>
  62. <listitem>
  63. <para>The purpose of this switch is to prevent Coreutils from
  64. installing binaries that will be installed by other packages later.
  65. </para>
  66. </listitem>
  67. </varlistentry>
  68. </variablelist>
  69. <para>Compile the package:</para>
  70. <screen><userinput remap="make">FORCE_UNSAFE_CONFIGURE=1 make</userinput></screen>
  71. <para>Skip down to <quote>Install the
  72. package</quote> if not running the test suite.</para>
  73. <para>Now the test suite is ready to be run. First, run the tests that are
  74. meant to be run as user <systemitem class="username">root</systemitem>:</para>
  75. <screen><userinput remap="test">make NON_ROOT_USERNAME=nobody check-root</userinput></screen>
  76. <para>We're going to run the remainder of the tests as the
  77. <systemitem class="username">nobody</systemitem> user. Certain tests,
  78. however, require that the user be a member of more than one group. So that
  79. these tests are not skipped we'll add a temporary group and make the
  80. user <systemitem class="username">nobody</systemitem> a part of it:</para>
  81. <screen><userinput remap="test">echo "dummy:x:1000:nobody" &gt;&gt; /etc/group</userinput></screen>
  82. <para>Fix some of the permissions so that the non-root user can compile and
  83. run the tests:</para>
  84. <screen><userinput remap="test">chown -Rv nobody . </userinput></screen>
  85. <para>Now run the tests. Make sure the PATH in the <userinput>su</userinput>
  86. environment includes /tools/bin.</para>
  87. <screen><userinput remap="test">su nobody -s /bin/bash \
  88. -c "PATH=$PATH make RUN_EXPENSIVE_TESTS=yes check"</userinput></screen>
  89. <para>The stty-pairs test is known to fail on a virtual console, but
  90. passes if run in a X terminal.</para>
  91. <para>Remove the temporary group:</para>
  92. <screen><userinput remap="test">sed -i '/dummy/d' /etc/group</userinput></screen>
  93. <para>Install the package:</para>
  94. <screen><userinput remap="install">make install</userinput></screen>
  95. <para>Move programs to the locations specified by the FHS:</para>
  96. <screen><userinput remap="install">mv -v /usr/bin/{cat,chgrp,chmod,chown,cp,date,dd,df,echo} /bin
  97. mv -v /usr/bin/{false,ln,ls,mkdir,mknod,mv,pwd,rm} /bin
  98. mv -v /usr/bin/{rmdir,stty,sync,true,uname} /bin
  99. mv -v /usr/bin/chroot /usr/sbin
  100. mv -v /usr/share/man/man1/chroot.1 /usr/share/man/man8/chroot.8
  101. sed -i s/\"1\"/\"8\"/1 /usr/share/man/man8/chroot.8</userinput></screen>
  102. <para>Some packages in BLFS and beyond expect the following
  103. programs in <filename class="directory">/bin</filename>, so
  104. make sure they are placed there:</para>
  105. <screen><userinput remap="install">mv -v /usr/bin/{head,sleep,nice,test,[} /bin</userinput></screen>
  106. </sect2>
  107. <sect2 id="contents-coreutils" role="content">
  108. <title>Contents of Coreutils</title>
  109. <segmentedlist>
  110. <segtitle>Installed programs</segtitle>
  111. <segtitle>Installed library</segtitle>
  112. <segtitle>Installed directory</segtitle>
  113. <seglistitem>
  114. <seg>[, base64, basename, cat, chcon, chgrp, chmod, chown, chroot, cksum,
  115. comm, cp, csplit, cut, date, dd, df, dir, dircolors, dirname, du, echo,
  116. env, expand, expr, factor, false, fmt, fold, groups, head, hostid,
  117. id, install, join, link, ln, logname, ls, md5sum, mkdir, mkfifo, mknod,
  118. mktemp, mv, nice, nl, nohup, nproc, numfmt, od, paste, pathchk, pinky, pr,
  119. printenv, printf, ptx, pwd, readlink, realpath, rm, rmdir, runcon, seq,
  120. sha1sum, sha224sum, sha256sum, sha384sum, sha512sum, shred, shuf, sleep,
  121. sort, split, stat, stdbuf, stty, sum, sync, tac, tail, tee, test,
  122. timeout, touch, tr, true, truncate, tsort, tty, uname, unexpand, uniq,
  123. unlink, users, vdir, wc, who, whoami, and yes</seg>
  124. <seg>libstdbuf.so</seg>
  125. <seg>/usr/libexec/coreutils</seg>
  126. </seglistitem>
  127. </segmentedlist>
  128. <variablelist>
  129. <bridgehead renderas="sect3">Short Descriptions</bridgehead>
  130. <?dbfo list-presentation="list"?>
  131. <?dbhtml list-presentation="table"?>
  132. <varlistentry id="base64">
  133. <term><command>base64</command></term>
  134. <listitem>
  135. <para>Encodes and decodes data according to the base64 (RFC 3548)
  136. specification</para>
  137. <indexterm zone="ch-system-coreutils base64">
  138. <primary sortas="b-base64">base64</primary>
  139. </indexterm>
  140. </listitem>
  141. </varlistentry>
  142. <varlistentry id="basename">
  143. <term><command>basename</command></term>
  144. <listitem>
  145. <para>Strips any path and a given suffix from a file name</para>
  146. <indexterm zone="ch-system-coreutils basename">
  147. <primary sortas="b-basename">basename</primary>
  148. </indexterm>
  149. </listitem>
  150. </varlistentry>
  151. <varlistentry id="cat">
  152. <term><command>cat</command></term>
  153. <listitem>
  154. <para>Concatenates files to standard output</para>
  155. <indexterm zone="ch-system-coreutils cat">
  156. <primary sortas="b-cat">cat</primary>
  157. </indexterm>
  158. </listitem>
  159. </varlistentry>
  160. <varlistentry id="chcon">
  161. <term><command>chcon</command></term>
  162. <listitem>
  163. <para>Changes security context for files and directories</para>
  164. <indexterm zone="ch-system-coreutils chcon">
  165. <primary sortas="b-chcon">chcon</primary>
  166. </indexterm>
  167. </listitem>
  168. </varlistentry>
  169. <varlistentry id="chgrp">
  170. <term><command>chgrp</command></term>
  171. <listitem>
  172. <para>Changes the group ownership of files and directories</para>
  173. <indexterm zone="ch-system-coreutils chgrp">
  174. <primary sortas="b-chgrp">chgrp</primary>
  175. </indexterm>
  176. </listitem>
  177. </varlistentry>
  178. <varlistentry id="chmod">
  179. <term><command>chmod</command></term>
  180. <listitem>
  181. <para>Changes the permissions of each file to the given mode; the mode
  182. can be either a symbolic representation of the changes to make or an
  183. octal number representing the new permissions</para>
  184. <indexterm zone="ch-system-coreutils chmod">
  185. <primary sortas="b-chmod">chmod</primary>
  186. </indexterm>
  187. </listitem>
  188. </varlistentry>
  189. <varlistentry id="chown">
  190. <term><command>chown</command></term>
  191. <listitem>
  192. <para>Changes the user and/or group ownership of files and
  193. directories</para>
  194. <indexterm zone="ch-system-coreutils chown">
  195. <primary sortas="b-chown">chown</primary>
  196. </indexterm>
  197. </listitem>
  198. </varlistentry>
  199. <varlistentry id="chroot">
  200. <term><command>chroot</command></term>
  201. <listitem>
  202. <para>Runs a command with the specified directory as the
  203. <filename class="directory">/</filename> directory</para>
  204. <indexterm zone="ch-system-coreutils chroot">
  205. <primary sortas="b-chroot">chroot</primary>
  206. </indexterm>
  207. </listitem>
  208. </varlistentry>
  209. <varlistentry id="cksum">
  210. <term><command>cksum</command></term>
  211. <listitem>
  212. <para>Prints the Cyclic Redundancy Check (CRC) checksum and the byte
  213. counts of each specified file</para>
  214. <indexterm zone="ch-system-coreutils cksum">
  215. <primary sortas="b-cksum">cksum</primary>
  216. </indexterm>
  217. </listitem>
  218. </varlistentry>
  219. <varlistentry id="comm">
  220. <term><command>comm</command></term>
  221. <listitem>
  222. <para>Compares two sorted files, outputting in three columns the lines
  223. that are unique and the lines that are common</para>
  224. <indexterm zone="ch-system-coreutils comm">
  225. <primary sortas="b-comm">comm</primary>
  226. </indexterm>
  227. </listitem>
  228. </varlistentry>
  229. <varlistentry id="cp">
  230. <term><command>cp</command></term>
  231. <listitem>
  232. <para>Copies files</para>
  233. <indexterm zone="ch-system-coreutils cp">
  234. <primary sortas="b-cp">cp</primary>
  235. </indexterm>
  236. </listitem>
  237. </varlistentry>
  238. <varlistentry id="csplit">
  239. <term><command>csplit</command></term>
  240. <listitem>
  241. <para>Splits a given file into several new files, separating them
  242. according to given patterns or line numbers and outputting the byte
  243. count of each new file</para>
  244. <indexterm zone="ch-system-coreutils csplit">
  245. <primary sortas="b-csplit">csplit</primary>
  246. </indexterm>
  247. </listitem>
  248. </varlistentry>
  249. <varlistentry id="cut">
  250. <term><command>cut</command></term>
  251. <listitem>
  252. <para>Prints sections of lines, selecting the parts according to given
  253. fields or positions</para>
  254. <indexterm zone="ch-system-coreutils cut">
  255. <primary sortas="b-cut">cut</primary>
  256. </indexterm>
  257. </listitem>
  258. </varlistentry>
  259. <varlistentry id="date">
  260. <term><command>date</command></term>
  261. <listitem>
  262. <para>Displays the current time in the given format, or sets the
  263. system date</para>
  264. <indexterm zone="ch-system-coreutils date">
  265. <primary sortas="b-date">date</primary>
  266. </indexterm>
  267. </listitem>
  268. </varlistentry>
  269. <varlistentry id="dd">
  270. <term><command>dd</command> </term>
  271. <listitem>
  272. <para>Copies a file using the given block size and count, while
  273. optionally performing conversions on it</para>
  274. <indexterm zone="ch-system-coreutils dd">
  275. <primary sortas="b-dd">dd</primary>
  276. </indexterm>
  277. </listitem>
  278. </varlistentry>
  279. <varlistentry id="df">
  280. <term><command>df</command></term>
  281. <listitem>
  282. <para>Reports the amount of disk space available (and used) on all
  283. mounted file systems, or only on the file systems holding the selected
  284. files</para>
  285. <indexterm zone="ch-system-coreutils df">
  286. <primary sortas="b-df">df</primary>
  287. </indexterm>
  288. </listitem>
  289. </varlistentry>
  290. <varlistentry id="dir">
  291. <term><command>dir</command></term>
  292. <listitem>
  293. <para>Lists the contents of each given directory (the same as
  294. the <command>ls</command> command)</para>
  295. <indexterm zone="ch-system-coreutils dir">
  296. <primary sortas="b-dir">dir</primary>
  297. </indexterm>
  298. </listitem>
  299. </varlistentry>
  300. <varlistentry id="dircolors">
  301. <term><command>dircolors</command></term>
  302. <listitem>
  303. <para>Outputs commands to set the <envar>LS_COLOR</envar>
  304. environment variable to change the color scheme used by
  305. <command>ls</command></para>
  306. <indexterm zone="ch-system-coreutils dircolors">
  307. <primary sortas="b-dircolors">dircolors</primary>
  308. </indexterm>
  309. </listitem>
  310. </varlistentry>
  311. <varlistentry id="dirname">
  312. <term><command>dirname</command></term>
  313. <listitem>
  314. <para>Strips the non-directory suffix from a file name</para>
  315. <indexterm zone="ch-system-coreutils dirname">
  316. <primary sortas="b-dirname">dirname</primary>
  317. </indexterm>
  318. </listitem>
  319. </varlistentry>
  320. <varlistentry id="du">
  321. <term><command>du</command></term>
  322. <listitem>
  323. <para>Reports the amount of disk space used by the current directory,
  324. by each of the given directories (including all subdirectories) or by
  325. each of the given files</para>
  326. <indexterm zone="ch-system-coreutils du">
  327. <primary sortas="b-du">du</primary>
  328. </indexterm>
  329. </listitem>
  330. </varlistentry>
  331. <varlistentry id="echo">
  332. <term><command>echo</command></term>
  333. <listitem>
  334. <para>Displays the given strings</para>
  335. <indexterm zone="ch-system-coreutils echo">
  336. <primary sortas="b-echo">echo</primary>
  337. </indexterm>
  338. </listitem>
  339. </varlistentry>
  340. <varlistentry id="env">
  341. <term><command>env</command></term>
  342. <listitem>
  343. <para>Runs a command in a modified environment</para>
  344. <indexterm zone="ch-system-coreutils env">
  345. <primary sortas="b-env">env</primary>
  346. </indexterm>
  347. </listitem>
  348. </varlistentry>
  349. <varlistentry id="expand">
  350. <term><command>expand</command></term>
  351. <listitem>
  352. <para>Converts tabs to spaces</para>
  353. <indexterm zone="ch-system-coreutils expand">
  354. <primary sortas="b-expand">expand</primary>
  355. </indexterm>
  356. </listitem>
  357. </varlistentry>
  358. <varlistentry id="expr">
  359. <term><command>expr</command></term>
  360. <listitem>
  361. <para>Evaluates expressions</para>
  362. <indexterm zone="ch-system-coreutils expr">
  363. <primary sortas="b-expr">expr</primary>
  364. </indexterm>
  365. </listitem>
  366. </varlistentry>
  367. <varlistentry id="factor">
  368. <term><command>factor</command></term>
  369. <listitem>
  370. <para>Prints the prime factors of all specified integer numbers</para>
  371. <indexterm zone="ch-system-coreutils factor">
  372. <primary sortas="b-factor">factor</primary>
  373. </indexterm>
  374. </listitem>
  375. </varlistentry>
  376. <varlistentry id="false">
  377. <term><command>false</command></term>
  378. <listitem>
  379. <para>Does nothing, unsuccessfully; it always exits with a status code
  380. indicating failure</para>
  381. <indexterm zone="ch-system-coreutils false">
  382. <primary sortas="b-false">false</primary>
  383. </indexterm>
  384. </listitem>
  385. </varlistentry>
  386. <varlistentry id="fmt">
  387. <term><command>fmt</command></term>
  388. <listitem>
  389. <para>Reformats the paragraphs in the given files</para>
  390. <indexterm zone="ch-system-coreutils fmt">
  391. <primary sortas="b-fmt">fmt</primary>
  392. </indexterm>
  393. </listitem>
  394. </varlistentry>
  395. <varlistentry id="fold">
  396. <term><command>fold</command></term>
  397. <listitem>
  398. <para>Wraps the lines in the given files</para>
  399. <indexterm zone="ch-system-coreutils fold">
  400. <primary sortas="b-fold">fold</primary>
  401. </indexterm>
  402. </listitem>
  403. </varlistentry>
  404. <varlistentry id="groups">
  405. <term><command>groups</command></term>
  406. <listitem>
  407. <para>Reports a user's group memberships</para>
  408. <indexterm zone="ch-system-coreutils groups">
  409. <primary sortas="b-groups">groups</primary>
  410. </indexterm>
  411. </listitem>
  412. </varlistentry>
  413. <varlistentry id="head">
  414. <term><command>head</command></term>
  415. <listitem>
  416. <para>Prints the first ten lines (or the given number of lines)
  417. of each given file</para>
  418. <indexterm zone="ch-system-coreutils head">
  419. <primary sortas="b-head">head</primary>
  420. </indexterm>
  421. </listitem>
  422. </varlistentry>
  423. <varlistentry id="hostid">
  424. <term><command>hostid</command></term>
  425. <listitem>
  426. <para>Reports the numeric identifier (in hexadecimal) of the host</para>
  427. <indexterm zone="ch-system-coreutils hostid">
  428. <primary sortas="b-hostid">hostid</primary>
  429. </indexterm>
  430. </listitem>
  431. </varlistentry>
  432. <varlistentry id="id">
  433. <term><command>id</command></term>
  434. <listitem>
  435. <para>Reports the effective user ID, group ID, and group memberships
  436. of the current user or specified user</para>
  437. <indexterm zone="ch-system-coreutils id">
  438. <primary sortas="b-id">id</primary>
  439. </indexterm>
  440. </listitem>
  441. </varlistentry>
  442. <varlistentry id="install">
  443. <term><command>install</command> </term>
  444. <listitem>
  445. <para>Copies files while setting their permission modes and, if
  446. possible, their owner and group</para>
  447. <indexterm zone="ch-system-coreutils install">
  448. <primary sortas="b-install">install</primary>
  449. </indexterm>
  450. </listitem>
  451. </varlistentry>
  452. <varlistentry id="join">
  453. <term><command>join</command></term>
  454. <listitem>
  455. <para>Joins the lines that have identical join fields from two
  456. separate files</para>
  457. <indexterm zone="ch-system-coreutils join">
  458. <primary sortas="b-join">join</primary>
  459. </indexterm>
  460. </listitem>
  461. </varlistentry>
  462. <varlistentry id="link">
  463. <term><command>link</command></term>
  464. <listitem>
  465. <para>Creates a hard link with the given name to a file</para>
  466. <indexterm zone="ch-system-coreutils link">
  467. <primary sortas="b-link">link</primary>
  468. </indexterm>
  469. </listitem>
  470. </varlistentry>
  471. <varlistentry id="ln">
  472. <term><command>ln</command></term>
  473. <listitem>
  474. <para>Makes hard links or soft (symbolic) links between files</para>
  475. <indexterm zone="ch-system-coreutils ln">
  476. <primary sortas="b-ln">ln</primary>
  477. </indexterm>
  478. </listitem>
  479. </varlistentry>
  480. <varlistentry id="logname">
  481. <term><command>logname</command></term>
  482. <listitem>
  483. <para>Reports the current user's login name</para>
  484. <indexterm zone="ch-system-coreutils logname">
  485. <primary sortas="b-logname">logname</primary>
  486. </indexterm>
  487. </listitem>
  488. </varlistentry>
  489. <varlistentry id="ls">
  490. <term><command>ls</command></term>
  491. <listitem>
  492. <para>Lists the contents of each given directory</para>
  493. <indexterm zone="ch-system-coreutils ls">
  494. <primary sortas="b-ls">ls</primary>
  495. </indexterm>
  496. </listitem>
  497. </varlistentry>
  498. <varlistentry id="md5sum">
  499. <term><command>md5sum</command></term>
  500. <listitem>
  501. <para>Reports or checks Message Digest 5 (MD5) checksums</para>
  502. <indexterm zone="ch-system-coreutils md5sum">
  503. <primary sortas="b-md5sum">md5sum</primary>
  504. </indexterm>
  505. </listitem>
  506. </varlistentry>
  507. <varlistentry id="mkdir">
  508. <term><command>mkdir</command></term>
  509. <listitem>
  510. <para>Creates directories with the given names</para>
  511. <indexterm zone="ch-system-coreutils mkdir">
  512. <primary sortas="b-mkdir">mkdir</primary>
  513. </indexterm>
  514. </listitem>
  515. </varlistentry>
  516. <varlistentry id="mkfifo">
  517. <term><command>mkfifo</command></term>
  518. <listitem>
  519. <para>Creates First-In, First-Outs (FIFOs), a "named
  520. pipe" in UNIX parlance, with the given names</para>
  521. <indexterm zone="ch-system-coreutils mkfifo">
  522. <primary sortas="b-mkfifo">mkfifo</primary>
  523. </indexterm>
  524. </listitem>
  525. </varlistentry>
  526. <varlistentry id="mknod">
  527. <term><command>mknod</command></term>
  528. <listitem>
  529. <para>Creates device nodes with the given names; a device node is a
  530. character special file, a block special file, or a FIFO</para>
  531. <indexterm zone="ch-system-coreutils mknod">
  532. <primary sortas="b-mknod">mknod</primary>
  533. </indexterm>
  534. </listitem>
  535. </varlistentry>
  536. <varlistentry id="mktemp">
  537. <term><command>mktemp</command></term>
  538. <listitem>
  539. <para>Creates temporary files in a secure manner; it is used in scripts</para>
  540. <indexterm zone="ch-system-coreutils mktemp">
  541. <primary sortas="b-mktemp">mktemp</primary>
  542. </indexterm>
  543. </listitem>
  544. </varlistentry>
  545. <varlistentry id="mv">
  546. <term><command>mv</command></term>
  547. <listitem>
  548. <para>Moves or renames files or directories</para>
  549. <indexterm zone="ch-system-coreutils mv">
  550. <primary sortas="b-mv">mv</primary>
  551. </indexterm>
  552. </listitem>
  553. </varlistentry>
  554. <varlistentry id="nice">
  555. <term><command>nice</command></term>
  556. <listitem>
  557. <para>Runs a program with modified scheduling priority</para>
  558. <indexterm zone="ch-system-coreutils nice">
  559. <primary sortas="b-nice">nice</primary>
  560. </indexterm>
  561. </listitem>
  562. </varlistentry>
  563. <varlistentry id="nl">
  564. <term><command>nl</command></term>
  565. <listitem>
  566. <para>Numbers the lines from the given files</para>
  567. <indexterm zone="ch-system-coreutils nl">
  568. <primary sortas="b-nl">nl</primary>
  569. </indexterm>
  570. </listitem>
  571. </varlistentry>
  572. <varlistentry id="nohup">
  573. <term><command>nohup</command></term>
  574. <listitem>
  575. <para>Runs a command immune to hangups, with its output redirected to
  576. a log file</para>
  577. <indexterm zone="ch-system-coreutils nohup">
  578. <primary sortas="b-nohup">nohup</primary>
  579. </indexterm>
  580. </listitem>
  581. </varlistentry>
  582. <varlistentry id="nproc">
  583. <term><command>nproc</command></term>
  584. <listitem>
  585. <para>Prints the number of processing units available to a
  586. process</para>
  587. <indexterm zone="ch-system-coreutils nproc">
  588. <primary sortas="b-nproc">nproc</primary>
  589. </indexterm>
  590. </listitem>
  591. </varlistentry>
  592. <varlistentry id="numfmt">
  593. <term><command>numfmt</command></term>
  594. <listitem>
  595. <para>Converts numbers to or from human-readable strings</para>
  596. <indexterm zone="ch-system-coreutils numfmt">
  597. <primary sortas="b-numfmt">numfmt</primary>
  598. </indexterm>
  599. </listitem>
  600. </varlistentry>
  601. <varlistentry id="od">
  602. <term><command>od</command></term>
  603. <listitem>
  604. <para>Dumps files in octal and other formats</para>
  605. <indexterm zone="ch-system-coreutils od">
  606. <primary sortas="b-od">od</primary>
  607. </indexterm>
  608. </listitem>
  609. </varlistentry>
  610. <varlistentry id="paste">
  611. <term><command>paste</command></term>
  612. <listitem>
  613. <para>Merges the given files, joining sequentially corresponding lines
  614. side by side, separated by tab characters</para>
  615. <indexterm zone="ch-system-coreutils paste">
  616. <primary sortas="b-paste">paste</primary>
  617. </indexterm>
  618. </listitem>
  619. </varlistentry>
  620. <varlistentry id="pathchk">
  621. <term><command>pathchk</command></term>
  622. <listitem>
  623. <para>Checks if file names are valid or portable</para>
  624. <indexterm zone="ch-system-coreutils pathchk">
  625. <primary sortas="b-pathchk">pathchk</primary>
  626. </indexterm>
  627. </listitem>
  628. </varlistentry>
  629. <varlistentry id="pinky">
  630. <term><command>pinky</command></term>
  631. <listitem>
  632. <para>Is a lightweight finger client; it reports some information
  633. about the given users</para>
  634. <indexterm zone="ch-system-coreutils pinky">
  635. <primary sortas="b-pinky">pinky</primary>
  636. </indexterm>
  637. </listitem>
  638. </varlistentry>
  639. <varlistentry id="pr">
  640. <term><command>pr</command></term>
  641. <listitem>
  642. <para>Paginates and columnates files for printing</para>
  643. <indexterm zone="ch-system-coreutils pr">
  644. <primary sortas="b-pr">pr</primary>
  645. </indexterm>
  646. </listitem>
  647. </varlistentry>
  648. <varlistentry id="printenv">
  649. <term><command>printenv</command></term>
  650. <listitem>
  651. <para>Prints the environment</para>
  652. <indexterm zone="ch-system-coreutils printenv">
  653. <primary sortas="b-printenv">printenv</primary>
  654. </indexterm>
  655. </listitem>
  656. </varlistentry>
  657. <varlistentry id="printf">
  658. <term><command>printf</command></term>
  659. <listitem>
  660. <para>Prints the given arguments according to the given format, much
  661. like the C printf function</para>
  662. <indexterm zone="ch-system-coreutils printf">
  663. <primary sortas="b-printf">printf</primary>
  664. </indexterm>
  665. </listitem>
  666. </varlistentry>
  667. <varlistentry id="ptx">
  668. <term><command>ptx</command></term>
  669. <listitem>
  670. <para>Produces a permuted index from the contents of the given files,
  671. with each keyword in its context</para>
  672. <indexterm zone="ch-system-coreutils ptx">
  673. <primary sortas="b-ptx">ptx</primary>
  674. </indexterm>
  675. </listitem>
  676. </varlistentry>
  677. <varlistentry id="pwd">
  678. <term><command>pwd</command></term>
  679. <listitem>
  680. <para>Reports the name of the current working directory</para>
  681. <indexterm zone="ch-system-coreutils pwd">
  682. <primary sortas="b-pwd">pwd</primary>
  683. </indexterm>
  684. </listitem>
  685. </varlistentry>
  686. <varlistentry id="readlink">
  687. <term><command>readlink</command></term>
  688. <listitem>
  689. <para>Reports the value of the given symbolic link</para>
  690. <indexterm zone="ch-system-coreutils readlink">
  691. <primary sortas="b-readlink">readlink</primary>
  692. </indexterm>
  693. </listitem>
  694. </varlistentry>
  695. <varlistentry id="realpath">
  696. <term><command>realpath</command></term>
  697. <listitem>
  698. <para>Prints the resolved path</para>
  699. <indexterm zone="ch-system-coreutils realpath">
  700. <primary sortas="b-realpath">realpath</primary>
  701. </indexterm>
  702. </listitem>
  703. </varlistentry>
  704. <varlistentry id="rm">
  705. <term><command>rm</command></term>
  706. <listitem>
  707. <para>Removes files or directories</para>
  708. <indexterm zone="ch-system-coreutils rm">
  709. <primary sortas="b-rm">rm</primary>
  710. </indexterm>
  711. </listitem>
  712. </varlistentry>
  713. <varlistentry id="rmdir">
  714. <term><command>rmdir</command></term>
  715. <listitem>
  716. <para>Removes directories if they are empty</para>
  717. <indexterm zone="ch-system-coreutils rmdir">
  718. <primary sortas="b-rmdir">rmdir</primary>
  719. </indexterm>
  720. </listitem>
  721. </varlistentry>
  722. <varlistentry id="runcon">
  723. <term><command>runcon</command></term>
  724. <listitem>
  725. <para>Runs a command with specified security context</para>
  726. <indexterm zone="ch-system-coreutils runcon">
  727. <primary sortas="b-runcon">runcon</primary>
  728. </indexterm>
  729. </listitem>
  730. </varlistentry>
  731. <varlistentry id="seq">
  732. <term><command>seq</command></term>
  733. <listitem>
  734. <para>Prints a sequence of numbers within a given range and with a
  735. given increment</para>
  736. <indexterm zone="ch-system-coreutils seq">
  737. <primary sortas="b-seq">seq</primary>
  738. </indexterm>
  739. </listitem>
  740. </varlistentry>
  741. <varlistentry id="sha1sum">
  742. <term><command>sha1sum</command></term>
  743. <listitem>
  744. <para>Prints or checks 160-bit Secure Hash Algorithm 1 (SHA1)
  745. checksums</para>
  746. <indexterm zone="ch-system-coreutils sha1sum">
  747. <primary sortas="b-sha1sum">sha1sum</primary>
  748. </indexterm>
  749. </listitem>
  750. </varlistentry>
  751. <varlistentry id="sha224sum">
  752. <term><command>sha224sum</command></term>
  753. <listitem>
  754. <para>Prints or checks 224-bit Secure Hash Algorithm checksums</para>
  755. <indexterm zone="ch-system-coreutils sha224sum">
  756. <primary sortas="b-sha224sum">sha224sum</primary>
  757. </indexterm>
  758. </listitem>
  759. </varlistentry>
  760. <varlistentry id="sha256sum">
  761. <term><command>sha256sum</command></term>
  762. <listitem>
  763. <para>Prints or checks 256-bit Secure Hash Algorithm checksums</para>
  764. <indexterm zone="ch-system-coreutils sha256sum">
  765. <primary sortas="b-sha256sum">sha256sum</primary>
  766. </indexterm>
  767. </listitem>
  768. </varlistentry>
  769. <varlistentry id="sha384sum">
  770. <term><command>sha384sum</command></term>
  771. <listitem>
  772. <para>Prints or checks 384-bit Secure Hash Algorithm checksums</para>
  773. <indexterm zone="ch-system-coreutils sha384sum">
  774. <primary sortas="b-sha384sum">sha384sum</primary>
  775. </indexterm>
  776. </listitem>
  777. </varlistentry>
  778. <varlistentry id="sha512sum">
  779. <term><command>sha512sum</command></term>
  780. <listitem>
  781. <para>Prints or checks 512-bit Secure Hash Algorithm checksums</para>
  782. <indexterm zone="ch-system-coreutils sha512sum">
  783. <primary sortas="b-sha512sum">sha512sum</primary>
  784. </indexterm>
  785. </listitem>
  786. </varlistentry>
  787. <varlistentry id="shred">
  788. <term><command>shred</command></term>
  789. <listitem>
  790. <para>Overwrites the given files repeatedly with complex patterns,
  791. making it difficult to recover the data</para>
  792. <indexterm zone="ch-system-coreutils shred">
  793. <primary sortas="b-shred">shred</primary>
  794. </indexterm>
  795. </listitem>
  796. </varlistentry>
  797. <varlistentry id="shuf">
  798. <term><command>shuf</command></term>
  799. <listitem>
  800. <para>Shuffles lines of text</para>
  801. <indexterm zone="ch-system-coreutils shuf">
  802. <primary sortas="b-shuf">shuf</primary>
  803. </indexterm>
  804. </listitem>
  805. </varlistentry>
  806. <varlistentry id="sleep">
  807. <term><command>sleep</command></term>
  808. <listitem>
  809. <para>Pauses for the given amount of time</para>
  810. <indexterm zone="ch-system-coreutils sleep">
  811. <primary sortas="b-sleep">sleep</primary>
  812. </indexterm>
  813. </listitem>
  814. </varlistentry>
  815. <varlistentry id="sort">
  816. <term><command>sort</command></term>
  817. <listitem>
  818. <para>Sorts the lines from the given files</para>
  819. <indexterm zone="ch-system-coreutils sort">
  820. <primary sortas="b-sort">sort</primary>
  821. </indexterm>
  822. </listitem>
  823. </varlistentry>
  824. <varlistentry id="split">
  825. <term><command>split</command></term>
  826. <listitem>
  827. <para>Splits the given file into pieces, by size or by number of
  828. lines</para>
  829. <indexterm zone="ch-system-coreutils split">
  830. <primary sortas="b-split">split</primary>
  831. </indexterm>
  832. </listitem>
  833. </varlistentry>
  834. <varlistentry id="stat">
  835. <term><command>stat</command></term>
  836. <listitem>
  837. <para>Displays file or filesystem status</para>
  838. <indexterm zone="ch-system-coreutils stat">
  839. <primary sortas="b-stat">stat</primary>
  840. </indexterm>
  841. </listitem>
  842. </varlistentry>
  843. <varlistentry id="stdbuf">
  844. <term><command>stdbuf</command></term>
  845. <listitem>
  846. <para>Runs commands with altered buffering operations for its standard
  847. streams</para>
  848. <indexterm zone="ch-system-coreutils stdbuf">
  849. <primary sortas="b-stdbuf">stdbuf</primary>
  850. </indexterm>
  851. </listitem>
  852. </varlistentry>
  853. <varlistentry id="stty">
  854. <term><command>stty</command></term>
  855. <listitem>
  856. <para>Sets or reports terminal line settings</para>
  857. <indexterm zone="ch-system-coreutils stty">
  858. <primary sortas="b-stty">stty</primary>
  859. </indexterm>
  860. </listitem>
  861. </varlistentry>
  862. <varlistentry id="sum">
  863. <term><command>sum</command></term>
  864. <listitem>
  865. <para>Prints checksum and block counts for each given file</para>
  866. <indexterm zone="ch-system-coreutils sum">
  867. <primary sortas="b-sum">sum</primary>
  868. </indexterm>
  869. </listitem>
  870. </varlistentry>
  871. <varlistentry id="sync">
  872. <term><command>sync</command></term>
  873. <listitem>
  874. <para>Flushes file system buffers; it forces changed blocks to disk
  875. and updates the super block</para>
  876. <indexterm zone="ch-system-coreutils sync">
  877. <primary sortas="b-sync">sync</primary>
  878. </indexterm>
  879. </listitem>
  880. </varlistentry>
  881. <varlistentry id="tac">
  882. <term><command>tac</command></term>
  883. <listitem>
  884. <para>Concatenates the given files in reverse</para>
  885. <indexterm zone="ch-system-coreutils tac">
  886. <primary sortas="b-tac">tac</primary>
  887. </indexterm>
  888. </listitem>
  889. </varlistentry>
  890. <varlistentry id="tail">
  891. <term><command>tail</command></term>
  892. <listitem>
  893. <para>Prints the last ten lines (or the given number of lines) of each
  894. given file</para>
  895. <indexterm zone="ch-system-coreutils tail">
  896. <primary sortas="b-tail">tail</primary>
  897. </indexterm>
  898. </listitem>
  899. </varlistentry>
  900. <varlistentry id="tee">
  901. <term><command>tee</command></term>
  902. <listitem>
  903. <para>Reads from standard input while writing both to standard output
  904. and to the given files</para>
  905. <indexterm zone="ch-system-coreutils tee">
  906. <primary sortas="b-tee">tee</primary>
  907. </indexterm>
  908. </listitem>
  909. </varlistentry>
  910. <varlistentry id="test">
  911. <term><command>test</command></term>
  912. <listitem>
  913. <para>Compares values and checks file types</para>
  914. <indexterm zone="ch-system-coreutils test">
  915. <primary sortas="b-test">test</primary>
  916. </indexterm>
  917. </listitem>
  918. </varlistentry>
  919. <varlistentry id="timeout">
  920. <term><command>timeout</command></term>
  921. <listitem>
  922. <para>Runs a command with a time limit</para>
  923. <indexterm zone="ch-system-coreutils timeout">
  924. <primary sortas="b-timeout">timeout</primary>
  925. </indexterm>
  926. </listitem>
  927. </varlistentry>
  928. <varlistentry id="touch">
  929. <term><command>touch</command></term>
  930. <listitem>
  931. <para>Changes file timestamps, setting the access and modification
  932. times of the given files to the current time; files that do not exist
  933. are created with zero length</para>
  934. <indexterm zone="ch-system-coreutils touch">
  935. <primary sortas="b-touch">touch</primary>
  936. </indexterm>
  937. </listitem>
  938. </varlistentry>
  939. <varlistentry id="tr">
  940. <term><command>tr</command></term>
  941. <listitem>
  942. <para>Translates, squeezes, and deletes the given characters from
  943. standard input</para>
  944. <indexterm zone="ch-system-coreutils tr">
  945. <primary sortas="b-tr">tr</primary>
  946. </indexterm>
  947. </listitem>
  948. </varlistentry>
  949. <varlistentry id="true">
  950. <term><command>true</command></term>
  951. <listitem>
  952. <para>Does nothing, successfully; it always exits with a status code
  953. indicating success</para>
  954. <indexterm zone="ch-system-coreutils true">
  955. <primary sortas="b-true">true</primary>
  956. </indexterm>
  957. </listitem>
  958. </varlistentry>
  959. <varlistentry id="truncate">
  960. <term><command>truncate</command></term>
  961. <listitem>
  962. <para>Shrinks or expands a file to the specified size</para>
  963. <indexterm zone="ch-system-coreutils truncate">
  964. <primary sortas="b-truncate">truncate</primary>
  965. </indexterm>
  966. </listitem>
  967. </varlistentry>
  968. <varlistentry id="tsort">
  969. <term><command>tsort</command></term>
  970. <listitem>
  971. <para>Performs a topological sort; it writes a completely ordered list
  972. according to the partial ordering in a given file</para>
  973. <indexterm zone="ch-system-coreutils tsort">
  974. <primary sortas="b-tsort">tsort</primary>
  975. </indexterm>
  976. </listitem>
  977. </varlistentry>
  978. <varlistentry id="tty">
  979. <term><command>tty</command></term>
  980. <listitem>
  981. <para>Reports the file name of the terminal connected to standard
  982. input</para>
  983. <indexterm zone="ch-system-coreutils tty">
  984. <primary sortas="b-tty">tty</primary>
  985. </indexterm>
  986. </listitem>
  987. </varlistentry>
  988. <varlistentry id="uname">
  989. <term><command>uname</command></term>
  990. <listitem>
  991. <para>Reports system information</para>
  992. <indexterm zone="ch-system-coreutils uname">
  993. <primary sortas="b-uname">uname</primary>
  994. </indexterm>
  995. </listitem>
  996. </varlistentry>
  997. <varlistentry id="unexpand">
  998. <term><command>unexpand</command></term>
  999. <listitem>
  1000. <para>Converts spaces to tabs</para>
  1001. <indexterm zone="ch-system-coreutils unexpand">
  1002. <primary sortas="b-unexpand">unexpand</primary>
  1003. </indexterm>
  1004. </listitem>
  1005. </varlistentry>
  1006. <varlistentry id="uniq">
  1007. <term><command>uniq</command></term>
  1008. <listitem>
  1009. <para>Discards all but one of successive identical lines</para>
  1010. <indexterm zone="ch-system-coreutils uniq">
  1011. <primary sortas="b-uniq">uniq</primary>
  1012. </indexterm>
  1013. </listitem>
  1014. </varlistentry>
  1015. <varlistentry id="unlink">
  1016. <term><command>unlink</command></term>
  1017. <listitem>
  1018. <para>Removes the given file</para>
  1019. <indexterm zone="ch-system-coreutils unlink">
  1020. <primary sortas="b-unlink">unlink</primary>
  1021. </indexterm>
  1022. </listitem>
  1023. </varlistentry>
  1024. <varlistentry id="users">
  1025. <term><command>users</command></term>
  1026. <listitem>
  1027. <para>Reports the names of the users currently logged on</para>
  1028. <indexterm zone="ch-system-coreutils users">
  1029. <primary sortas="b-users">users</primary>
  1030. </indexterm>
  1031. </listitem>
  1032. </varlistentry>
  1033. <varlistentry id="vdir">
  1034. <term><command>vdir</command></term>
  1035. <listitem>
  1036. <para>Is the same as <command>ls -l</command></para>
  1037. <indexterm zone="ch-system-coreutils vdir">
  1038. <primary sortas="b-vdir">vdir</primary>
  1039. </indexterm>
  1040. </listitem>
  1041. </varlistentry>
  1042. <varlistentry id="wc">
  1043. <term><command>wc</command></term>
  1044. <listitem>
  1045. <para>Reports the number of lines, words, and bytes for each given
  1046. file, as well as a total line when more than one file is given</para>
  1047. <indexterm zone="ch-system-coreutils wc">
  1048. <primary sortas="b-wc">wc</primary>
  1049. </indexterm>
  1050. </listitem>
  1051. </varlistentry>
  1052. <varlistentry id="who">
  1053. <term><command>who</command></term>
  1054. <listitem>
  1055. <para>Reports who is logged on</para>
  1056. <indexterm zone="ch-system-coreutils who">
  1057. <primary sortas="b-who">who</primary>
  1058. </indexterm>
  1059. </listitem>
  1060. </varlistentry>
  1061. <varlistentry id="whoami">
  1062. <term><command>whoami</command></term>
  1063. <listitem>
  1064. <para>Reports the user name associated with the current effective
  1065. user ID</para>
  1066. <indexterm zone="ch-system-coreutils whoami">
  1067. <primary sortas="b-whoami">whoami</primary>
  1068. </indexterm>
  1069. </listitem>
  1070. </varlistentry>
  1071. <varlistentry id="yes">
  1072. <term><command>yes</command></term>
  1073. <listitem>
  1074. <para>Repeatedly outputs <quote>y</quote> or a given string until
  1075. killed</para>
  1076. <indexterm zone="ch-system-coreutils yes">
  1077. <primary sortas="b-yes">yes</primary>
  1078. </indexterm>
  1079. </listitem>
  1080. </varlistentry>
  1081. <varlistentry id="libstdbuf">
  1082. <term><filename class="libraryfile">libstdbuf</filename></term>
  1083. <listitem>
  1084. <para>Library used by <command>stdbuf</command></para>
  1085. <indexterm zone="ch-system-coreutils libstdbuf">
  1086. <primary sortas="c-libstdbuf">libstdbuf</primary>
  1087. </indexterm>
  1088. </listitem>
  1089. </varlistentry>
  1090. </variablelist>
  1091. </sect2>
  1092. </sect1>