[673b0d8] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
[b06ca36] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
[673b0d8] | 4 | <!ENTITY % general-entities SYSTEM "../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 | ]>
|
---|
[3f3931b0] | 7 |
|
---|
[81fd230] | 8 | <sect1 id="ch-system-procps" role="wrap">
|
---|
[ec9f9d4] | 9 | <?dbhtml filename="procps-ng.html"?>
|
---|
[3f3931b0] | 10 |
|
---|
[e747759] | 11 | <sect1info condition="script">
|
---|
[ec9f9d4] | 12 | <productname>procps-ng</productname>
|
---|
| 13 | <productnumber>&procps-ng-version;</productnumber>
|
---|
| 14 | <address>&procps-ng-url;</address>
|
---|
[e747759] | 15 | </sect1info>
|
---|
| 16 |
|
---|
[63d6655] | 17 | <title>Procps-ng-&procps-ng-version;</title>
|
---|
[3f3931b0] | 18 |
|
---|
| 19 | <indexterm zone="ch-system-procps">
|
---|
[ec9f9d4] | 20 | <primary sortas="a-Procps">Procps-ng</primary>
|
---|
[3f3931b0] | 21 | </indexterm>
|
---|
| 22 |
|
---|
| 23 | <sect2 role="package">
|
---|
| 24 | <title/>
|
---|
[673b0d8] | 25 |
|
---|
[ec9f9d4] | 26 | <para>The Procps-ng package contains programs for monitoring processes.</para>
|
---|
[6370fa6] | 27 |
|
---|
[3f3931b0] | 28 | <segmentedlist>
|
---|
| 29 | <segtitle>&buildtime;</segtitle>
|
---|
| 30 | <segtitle>&diskspace;</segtitle>
|
---|
[5888299] | 31 |
|
---|
[3f3931b0] | 32 | <seglistitem>
|
---|
[ec9f9d4] | 33 | <seg>&procps-ng-ch6-sbu;</seg>
|
---|
| 34 | <seg>&procps-ng-ch6-du;</seg>
|
---|
[3f3931b0] | 35 | </seglistitem>
|
---|
| 36 | </segmentedlist>
|
---|
[673b0d8] | 37 |
|
---|
[3f3931b0] | 38 | </sect2>
|
---|
| 39 |
|
---|
| 40 | <sect2 role="installation">
|
---|
[ec9f9d4] | 41 | <title>Installation of Procps-ng</title>
|
---|
[3f3931b0] | 42 |
|
---|
[0d84af1] | 43 | <para>Prepare procps-ng for compilation:</para>
|
---|
[62b134d] | 44 |
|
---|
[1118b17] | 45 | <screen revision="sysv"><userinput remap="configure">./configure --prefix=/usr \
|
---|
[d0da965a] | 46 | --exec-prefix= \
|
---|
| 47 | --libdir=/usr/lib \
|
---|
[79dc83f] | 48 | --docdir=/usr/share/doc/procps-ng-&procps-ng-version; \
|
---|
[d0da965a] | 49 | --disable-static \
|
---|
[ec9f9d4] | 50 | --disable-kill</userinput></screen>
|
---|
[62b134d] | 51 |
|
---|
[1118b17] | 52 | <screen revision="systemd"><userinput remap="configure">./configure --prefix=/usr \
|
---|
| 53 | --exec-prefix= \
|
---|
| 54 | --libdir=/usr/lib \
|
---|
| 55 | --docdir=/usr/share/doc/procps-ng-&procps-ng-version; \
|
---|
| 56 | --disable-static \
|
---|
| 57 | --disable-kill \
|
---|
| 58 | --with-systemd</userinput></screen>
|
---|
| 59 |
|
---|
[ec9f9d4] | 60 | <variablelist>
|
---|
| 61 | <title>The meaning of the configure options:</title>
|
---|
[3e80156] | 62 |
|
---|
[ec9f9d4] | 63 | <varlistentry>
|
---|
| 64 | <term><parameter>--disable-kill</parameter></term>
|
---|
| 65 | <listitem>
|
---|
[f0800aa] | 66 | <para>This switch disables building the <command>kill</command>
|
---|
| 67 | command that will be installed by the Util-linux package.</para>
|
---|
[ec9f9d4] | 68 | </listitem>
|
---|
| 69 | </varlistentry>
|
---|
| 70 | </variablelist>
|
---|
[2ca8941] | 71 |
|
---|
[58c4a18] | 72 | <para>Compile the package:</para>
|
---|
[73aedd1d] | 73 |
|
---|
[0445a3d] | 74 | <screen><userinput remap="make">make</userinput></screen>
|
---|
[73aedd1d] | 75 |
|
---|
[2ca8941] | 76 | <para>The test suite needs some custom modifications for LFS.
|
---|
[67ce2a2] | 77 | Remove a test that fails when scripting does not use a tty device and
|
---|
| 78 | fix two others.
|
---|
[8445b68] | 79 | To run the test suite, run the following commands:</para>
|
---|
[ec9f9d4] | 80 |
|
---|
[f873610] | 81 | <screen><userinput remap="test">sed -i -r 's|(pmap_initname)\\\$|\1|' testsuite/pmap.test/pmap.exp
|
---|
[67ce2a2] | 82 | sed -i '/set tty/d' testsuite/pkill.test/pkill.exp
|
---|
| 83 | rm testsuite/pgrep.test/pgrep.exp
|
---|
[d45e041] | 84 | make check</userinput></screen>
|
---|
[2ca8941] | 85 |
|
---|
[58c4a18] | 86 | <para>Install the package:</para>
|
---|
[73aedd1d] | 87 |
|
---|
[0445a3d] | 88 | <screen><userinput remap="install">make install</userinput></screen>
|
---|
[73aedd1d] | 89 |
|
---|
[f5e821c] | 90 | <para>Finally, move essential libraries to a location that can be found if
|
---|
[79dc83f] | 91 | <filename class="directory">/usr</filename> is not mounted.</para>
|
---|
| 92 |
|
---|
[f5e821c] | 93 | <screen><userinput remap="install">mv -v /usr/lib/libprocps.so.* /lib
|
---|
[a326b1d7] | 94 | ln -sfv ../../lib/$(readlink /usr/lib/libprocps.so) /usr/lib/libprocps.so</userinput></screen>
|
---|
[79dc83f] | 95 |
|
---|
[3f3931b0] | 96 | </sect2>
|
---|
| 97 |
|
---|
| 98 | <sect2 id="contents-procps" role="content">
|
---|
[ec9f9d4] | 99 | <title>Contents of Procps-ng</title>
|
---|
[3f3931b0] | 100 |
|
---|
| 101 | <segmentedlist>
|
---|
| 102 | <segtitle>Installed programs</segtitle>
|
---|
| 103 | <segtitle>Installed library</segtitle>
|
---|
[f41fa81] | 104 | <segtitle>Installed directories</segtitle>
|
---|
[3f3931b0] | 105 |
|
---|
| 106 | <seglistitem>
|
---|
[9132fe4] | 107 | <seg>free, pgrep, pidof, pkill, pmap, ps, pwdx, slabtop,
|
---|
[f41fa81] | 108 | sysctl, tload, top, uptime, vmstat, w, and watch</seg>
|
---|
[ec9f9d4] | 109 | <seg>libprocps.so</seg>
|
---|
[7bb9fda] | 110 | <seg>/usr/include/proc and /usr/share/doc/procps-ng-&procps-ng-version;</seg>
|
---|
[3f3931b0] | 111 | </seglistitem>
|
---|
| 112 | </segmentedlist>
|
---|
| 113 |
|
---|
| 114 | <variablelist>
|
---|
| 115 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 116 | <?dbfo list-presentation="list"?>
|
---|
| 117 | <?dbhtml list-presentation="table"?>
|
---|
| 118 |
|
---|
| 119 | <varlistentry id="free">
|
---|
| 120 | <term><command>free</command></term>
|
---|
| 121 | <listitem>
|
---|
| 122 | <para>Reports the amount of free and used memory (both physical and
|
---|
| 123 | swap memory) in the system</para>
|
---|
| 124 | <indexterm zone="ch-system-procps free">
|
---|
| 125 | <primary sortas="b-free">free</primary>
|
---|
| 126 | </indexterm>
|
---|
| 127 | </listitem>
|
---|
| 128 | </varlistentry>
|
---|
| 129 |
|
---|
| 130 | <varlistentry id="pgrep">
|
---|
| 131 | <term><command>pgrep</command></term>
|
---|
| 132 | <listitem>
|
---|
| 133 | <para>Looks up processes based on their name and other attributes</para>
|
---|
| 134 | <indexterm zone="ch-system-procps pgrep">
|
---|
| 135 | <primary sortas="b-pgrep">pgrep</primary>
|
---|
| 136 | </indexterm>
|
---|
| 137 | </listitem>
|
---|
| 138 | </varlistentry>
|
---|
| 139 |
|
---|
[9132fe4] | 140 | <varlistentry id="pidof">
|
---|
| 141 | <term><command>pidof</command></term>
|
---|
| 142 | <listitem>
|
---|
[1d6f204] | 143 | <para>Reports the PIDs of the given programs</para>
|
---|
[9132fe4] | 144 | <indexterm zone="ch-system-procps pidof">
|
---|
| 145 | <primary sortas="b-pidof">pidof</primary>
|
---|
| 146 | </indexterm>
|
---|
| 147 | </listitem>
|
---|
| 148 | </varlistentry>
|
---|
| 149 |
|
---|
[3f3931b0] | 150 | <varlistentry id="pkill">
|
---|
| 151 | <term><command>pkill</command></term>
|
---|
| 152 | <listitem>
|
---|
| 153 | <para>Signals processes based on their name and other attributes</para>
|
---|
| 154 | <indexterm zone="ch-system-procps pkill">
|
---|
| 155 | <primary sortas="b-pkill">pkill</primary>
|
---|
| 156 | </indexterm>
|
---|
| 157 | </listitem>
|
---|
| 158 | </varlistentry>
|
---|
| 159 |
|
---|
| 160 | <varlistentry id="pmap">
|
---|
| 161 | <term><command>pmap</command></term>
|
---|
| 162 | <listitem>
|
---|
| 163 | <para>Reports the memory map of the given process</para>
|
---|
| 164 | <indexterm zone="ch-system-procps pmap">
|
---|
| 165 | <primary sortas="b-pmap">pmap</primary>
|
---|
| 166 | </indexterm>
|
---|
| 167 | </listitem>
|
---|
| 168 | </varlistentry>
|
---|
| 169 |
|
---|
| 170 | <varlistentry id="ps">
|
---|
| 171 | <term><command>ps</command></term>
|
---|
| 172 | <listitem>
|
---|
| 173 | <para>Lists the current running processes</para>
|
---|
| 174 | <indexterm zone="ch-system-procps ps">
|
---|
| 175 | <primary sortas="b-ps">ps</primary>
|
---|
| 176 | </indexterm>
|
---|
| 177 | </listitem>
|
---|
| 178 | </varlistentry>
|
---|
| 179 |
|
---|
[2791a8e] | 180 | <varlistentry id="pwdx">
|
---|
| 181 | <term><command>pwdx</command></term>
|
---|
| 182 | <listitem>
|
---|
| 183 | <para>Reports the current working directory of a process</para>
|
---|
| 184 | <indexterm zone="ch-system-procps pwdx">
|
---|
| 185 | <primary sortas="b-pwdx">pwdx</primary>
|
---|
| 186 | </indexterm>
|
---|
| 187 | </listitem>
|
---|
| 188 | </varlistentry>
|
---|
| 189 |
|
---|
[8bc46a5] | 190 | <varlistentry id="slabtop">
|
---|
| 191 | <term><command>slabtop</command></term>
|
---|
| 192 | <listitem>
|
---|
[0d84af1] | 193 | <para>Displays detailed kernel slab cache information in real time</para>
|
---|
[8bc46a5] | 194 | <indexterm zone="ch-system-procps slabtop">
|
---|
| 195 | <primary sortas="b-slabtop">slabtop</primary>
|
---|
| 196 | </indexterm>
|
---|
| 197 | </listitem>
|
---|
| 198 | </varlistentry>
|
---|
| 199 |
|
---|
[3f3931b0] | 200 | <varlistentry id="sysctl">
|
---|
| 201 | <term><command>sysctl</command></term>
|
---|
| 202 | <listitem>
|
---|
| 203 | <para>Modifies kernel parameters at run time</para>
|
---|
| 204 | <indexterm zone="ch-system-procps sysctl">
|
---|
| 205 | <primary sortas="b-sysctl">sysctl</primary>
|
---|
| 206 | </indexterm>
|
---|
| 207 | </listitem>
|
---|
| 208 | </varlistentry>
|
---|
| 209 |
|
---|
| 210 | <varlistentry id="tload">
|
---|
| 211 | <term><command>tload</command></term>
|
---|
| 212 | <listitem>
|
---|
| 213 | <para>Prints a graph of the current system load average</para>
|
---|
| 214 | <indexterm zone="ch-system-procps tload">
|
---|
| 215 | <primary sortas="b-tload">tload</primary>
|
---|
| 216 | </indexterm>
|
---|
| 217 | </listitem>
|
---|
| 218 | </varlistentry>
|
---|
| 219 |
|
---|
| 220 | <varlistentry id="top">
|
---|
| 221 | <term><command>top</command></term>
|
---|
| 222 | <listitem>
|
---|
| 223 | <para>Displays a list of the most CPU intensive processes; it
|
---|
| 224 | provides an ongoing look at processor activity in real time</para>
|
---|
| 225 | <indexterm zone="ch-system-procps top">
|
---|
| 226 | <primary sortas="b-top">top</primary>
|
---|
| 227 | </indexterm>
|
---|
| 228 | </listitem>
|
---|
| 229 | </varlistentry>
|
---|
| 230 |
|
---|
| 231 | <varlistentry id="uptime">
|
---|
| 232 | <term><command>uptime</command></term>
|
---|
| 233 | <listitem>
|
---|
| 234 | <para>Reports how long the system has been running, how many users are
|
---|
| 235 | logged on, and the system load averages</para>
|
---|
| 236 | <indexterm zone="ch-system-procps uptime">
|
---|
| 237 | <primary sortas="b-uptime">uptime</primary>
|
---|
| 238 | </indexterm>
|
---|
| 239 | </listitem>
|
---|
| 240 | </varlistentry>
|
---|
| 241 |
|
---|
| 242 | <varlistentry id="vmstat">
|
---|
| 243 | <term><command>vmstat</command></term>
|
---|
| 244 | <listitem>
|
---|
| 245 | <para>Reports virtual memory statistics, giving information about
|
---|
| 246 | processes, memory, paging, block Input/Output (IO), traps, and CPU
|
---|
| 247 | activity</para>
|
---|
| 248 | <indexterm zone="ch-system-procps vmstat">
|
---|
| 249 | <primary sortas="b-vmstat">vmstat</primary>
|
---|
| 250 | </indexterm>
|
---|
| 251 | </listitem>
|
---|
| 252 | </varlistentry>
|
---|
| 253 |
|
---|
| 254 | <varlistentry id="w">
|
---|
| 255 | <term><command>w</command></term>
|
---|
| 256 | <listitem>
|
---|
| 257 | <para>Shows which users are currently logged on, where, and since
|
---|
| 258 | when</para>
|
---|
| 259 | <indexterm zone="ch-system-procps w">
|
---|
| 260 | <primary sortas="b-w">w</primary>
|
---|
| 261 | </indexterm>
|
---|
| 262 | </listitem>
|
---|
| 263 | </varlistentry>
|
---|
| 264 |
|
---|
| 265 | <varlistentry id="watch">
|
---|
| 266 | <term><command>watch</command></term>
|
---|
| 267 | <listitem>
|
---|
| 268 | <para>Runs a given command repeatedly, displaying the first
|
---|
| 269 | screen-full of its output; this allows a user to watch the output
|
---|
| 270 | change over time</para>
|
---|
| 271 | <indexterm zone="ch-system-procps watch">
|
---|
| 272 | <primary sortas="b-watch">watch</primary>
|
---|
| 273 | </indexterm>
|
---|
| 274 | </listitem>
|
---|
| 275 | </varlistentry>
|
---|
| 276 |
|
---|
[ec9f9d4] | 277 | <varlistentry id="libprocps">
|
---|
[9132fe4] | 278 | <term><filename class="libraryfile">libprocps</filename></term>
|
---|
[3f3931b0] | 279 | <listitem>
|
---|
| 280 | <para>Contains the functions used by most programs in this
|
---|
| 281 | package</para>
|
---|
[ec9f9d4] | 282 | <indexterm zone="ch-system-procps libprocps">
|
---|
| 283 | <primary sortas="c-libprocps">libprocps</primary>
|
---|
[3f3931b0] | 284 | </indexterm>
|
---|
| 285 | </listitem>
|
---|
| 286 | </varlistentry>
|
---|
| 287 |
|
---|
| 288 | </variablelist>
|
---|
| 289 |
|
---|
| 290 | </sect2>
|
---|
[673b0d8] | 291 |
|
---|
| 292 | </sect1>
|
---|