coreutils.xml 43 KB

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