[ab4fdfc] | 1 | <?xml version="1.0" encoding="UTF-8"?>
|
---|
[6732c094] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
[f384a9d] | 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
[bba4499b] | 7 | <!ENTITY sysstat-download-http "https://sysstat.github.io/sysstat-packages/sysstat-&sysstat-version;.tar.xz">
|
---|
[dc2b407] | 8 | <!ENTITY sysstat-download-ftp " ">
|
---|
[416bb219] | 9 | <!ENTITY sysstat-md5sum "16fd81728fec899f22155fdfcebece97">
|
---|
| 10 | <!ENTITY sysstat-size "900 KB">
|
---|
[b1463480] | 11 | <!ENTITY sysstat-buildsize "29 MB">
|
---|
[fb19ab2c] | 12 | <!ENTITY sysstat-time "0.1 SBU">
|
---|
[f384a9d] | 13 | ]>
|
---|
| 14 |
|
---|
[880c568] | 15 | <sect1 id="sysstat" xreflabel="Sysstat-&sysstat-version;">
|
---|
[eb2cf83a] | 16 | <?dbhtml filename="sysstat.html"?>
|
---|
| 17 |
|
---|
| 18 |
|
---|
[880c568] | 19 | <title>Sysstat-&sysstat-version;</title>
|
---|
[eb2cf83a] | 20 |
|
---|
| 21 | <indexterm zone="sysstat">
|
---|
[880c568] | 22 | <primary sortas="a-Sysstat">Sysstat</primary>
|
---|
[eb2cf83a] | 23 | </indexterm>
|
---|
| 24 |
|
---|
| 25 | <sect2 role="package">
|
---|
| 26 | <title>Introduction to Sysstat</title>
|
---|
| 27 |
|
---|
[b1532549] | 28 | <para>
|
---|
| 29 | The <application>Sysstat</application> package contains utilities
|
---|
| 30 | to monitor system performance and usage activity.
|
---|
| 31 | <application>Sysstat</application> contains the <command>sar</command>
|
---|
| 32 | utility, common to many commercial Unixes, and tools you can schedule via
|
---|
| 33 | cron to collect and historize performance and activity data.
|
---|
| 34 | </para>
|
---|
[eb2cf83a] | 35 |
|
---|
[868811b] | 36 | &lfs121_checked;
|
---|
[fdc00738] | 37 |
|
---|
[eb2cf83a] | 38 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 39 | <itemizedlist spacing="compact">
|
---|
| 40 | <listitem>
|
---|
[b1532549] | 41 | <para>
|
---|
| 42 | Download (HTTP): <ulink url="&sysstat-download-http;"/>
|
---|
| 43 | </para>
|
---|
[eb2cf83a] | 44 | </listitem>
|
---|
| 45 | <listitem>
|
---|
[b1532549] | 46 | <para>
|
---|
| 47 | Download (FTP): <ulink url="&sysstat-download-ftp;"/>
|
---|
| 48 | </para>
|
---|
[eb2cf83a] | 49 | </listitem>
|
---|
| 50 | <listitem>
|
---|
[b1532549] | 51 | <para>
|
---|
| 52 | Download MD5 sum: &sysstat-md5sum;
|
---|
| 53 | </para>
|
---|
[eb2cf83a] | 54 | </listitem>
|
---|
| 55 | <listitem>
|
---|
[b1532549] | 56 | <para>
|
---|
| 57 | Download size: &sysstat-size;
|
---|
| 58 | </para>
|
---|
[eb2cf83a] | 59 | </listitem>
|
---|
| 60 | <listitem>
|
---|
[b1532549] | 61 | <para>
|
---|
| 62 | Estimated disk space required: &sysstat-buildsize;
|
---|
| 63 | </para>
|
---|
[eb2cf83a] | 64 | </listitem>
|
---|
| 65 | <listitem>
|
---|
[b1532549] | 66 | <para>
|
---|
| 67 | Estimated build time: &sysstat-time;
|
---|
| 68 | </para>
|
---|
[eb2cf83a] | 69 | </listitem>
|
---|
| 70 | </itemizedlist>
|
---|
| 71 |
|
---|
| 72 | <bridgehead renderas="sect3">Sysstat Dependencies</bridgehead>
|
---|
| 73 |
|
---|
[b1532549] | 74 | <para role="recommended">
|
---|
| 75 | There are no build-time requirements for this package; however,
|
---|
| 76 | it is designed to be controlled by a cron daemon such as
|
---|
| 77 | <xref linkend="fcron" role="runtime"/>.
|
---|
| 78 | </para>
|
---|
[b058cd3] | 79 |
|
---|
[eb2cf83a] | 80 | </sect2>
|
---|
| 81 |
|
---|
| 82 | <sect2 role="installation">
|
---|
| 83 | <title>Installation of Sysstat</title>
|
---|
| 84 |
|
---|
[b1532549] | 85 | <para>
|
---|
| 86 | Install <application>Sysstat</application> by running the
|
---|
| 87 | following commands:
|
---|
| 88 | </para>
|
---|
[eb2cf83a] | 89 |
|
---|
[fdc00738] | 90 | <screen><userinput>sa_lib_dir=/usr/lib/sa \
|
---|
| 91 | sa_dir=/var/log/sa \
|
---|
[bba4499b] | 92 | conf_dir=/etc/sysstat \
|
---|
[fdc00738] | 93 | ./configure --prefix=/usr \
|
---|
[fb19ab2c] | 94 | --disable-file-attr &&
|
---|
[eb2cf83a] | 95 | make</userinput></screen>
|
---|
| 96 |
|
---|
[b1532549] | 97 | <para>
|
---|
[f179b24] | 98 | This package does not come with a working test suite.
|
---|
[b1532549] | 99 | </para>
|
---|
[5ba48e8] | 100 |
|
---|
[b1532549] | 101 | <para>
|
---|
| 102 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 103 | </para>
|
---|
[eb2cf83a] | 104 |
|
---|
[58a8fab2] | 105 | <screen role="root"><userinput>make install</userinput></screen>
|
---|
| 106 |
|
---|
[1552ac8] | 107 | <para revision="systemd">
|
---|
[eb07735] | 108 | Install the systemd unit by running the following commands as the
|
---|
[1552ac8] | 109 | <systemitem class="username">root</systemitem> user:
|
---|
| 110 | </para>
|
---|
| 111 |
|
---|
[5aaa067] | 112 | <screen role="root" revision="systemd"><userinput>install -v -m644 sysstat.service /usr/lib/systemd/system/sysstat.service &&
|
---|
[dfe5714] | 113 | install -v -m644 cron/sysstat-collect.service /usr/lib/systemd/system/sysstat-collect.service &&
|
---|
[5aaa067] | 114 | install -v -m644 cron/sysstat-collect.timer /usr/lib/systemd/system/sysstat-collect.timer &&
|
---|
[9498e22] | 115 | install -v -m644 cron/sysstat-rotate.service /usr/lib/systemd/system/sysstat-rotate.service &&
|
---|
[5aaa067] | 116 | install -v -m644 cron/sysstat-rotate.timer /usr/lib/systemd/system/sysstat-rotate.timer &&
|
---|
[dfe5714] | 117 | install -v -m644 cron/sysstat-summary.service /usr/lib/systemd/system/sysstat-summary.service &&
|
---|
| 118 | install -v -m644 cron/sysstat-summary.timer /usr/lib/systemd/system/sysstat-summary.timer</userinput></screen>
|
---|
[1552ac8] | 119 |
|
---|
[d4b0dc1] | 120 | <para revision="systemd">
|
---|
| 121 | Fix the systemd unit by running the following command as the
|
---|
| 122 | <systemitem class="username">root</systemitem> user:
|
---|
| 123 | </para>
|
---|
| 124 |
|
---|
[ea3a605d] | 125 | <screen role="root" revision="systemd"><userinput>sed -i "/^Also=/d" /usr/lib/systemd/system/sysstat.service</userinput></screen>
|
---|
[d4b0dc1] | 126 |
|
---|
[eb2cf83a] | 127 | </sect2>
|
---|
| 128 |
|
---|
| 129 | <sect2 role="commands">
|
---|
| 130 | <title>Command Explanations</title>
|
---|
| 131 |
|
---|
[b1532549] | 132 | <para>
|
---|
| 133 | <envar>sa_lib_dir</envar>: This environment variable specifies the
|
---|
| 134 | location of the package-specific library directory.
|
---|
| 135 | </para>
|
---|
[5a195f0f] | 136 |
|
---|
[b1532549] | 137 | <para>
|
---|
| 138 | <envar>sa_dir</envar>: This environment variable specifies the
|
---|
| 139 | location of the directory containing the data files.
|
---|
| 140 | </para>
|
---|
[5a195f0f] | 141 |
|
---|
[b1532549] | 142 | <para>
|
---|
| 143 | <envar>conf_dir</envar>: This environment variable specifies the
|
---|
| 144 | location of the system configuration directory.
|
---|
| 145 | </para>
|
---|
[5a195f0f] | 146 |
|
---|
[b1532549] | 147 | <para>
|
---|
| 148 | <parameter>--disable-file-attr</parameter>: Do not set attributes on
|
---|
| 149 | files being installed. This parameter causes the installation to ignore
|
---|
| 150 | the man group variable resulting in the man files having
|
---|
| 151 | <systemitem class="username">root</systemitem>:
|
---|
| 152 | <systemitem class="groupname">root</systemitem> ownership.
|
---|
| 153 | </para>
|
---|
[5a195f0f] | 154 |
|
---|
[b1532549] | 155 | <note>
|
---|
| 156 | <para>
|
---|
| 157 | Run <command>./configure --help</command> to see other influential
|
---|
| 158 | environment variables you can pass to <command>configure</command>.
|
---|
| 159 | You may want to use the <envar>history</envar> and
|
---|
| 160 | <envar>compressafter</envar> variables to customize the amount of data
|
---|
| 161 | files kept on the system.
|
---|
| 162 | </para>
|
---|
| 163 | </note>
|
---|
[eb2cf83a] | 164 |
|
---|
| 165 | </sect2>
|
---|
| 166 |
|
---|
| 167 | <sect2 role="configuration">
|
---|
| 168 | <title>Configuring Sysstat</title>
|
---|
| 169 |
|
---|
[f1b1c20] | 170 | <sect3 id="sysstat-config">
|
---|
| 171 | <title>Config Files</title>
|
---|
| 172 |
|
---|
| 173 | <para>
|
---|
| 174 | <filename>/etc/sysconfig/sysstat</filename> and
|
---|
| 175 | <filename>/etc/sysconfig/sysstat.ioconf</filename>
|
---|
| 176 | </para>
|
---|
| 177 |
|
---|
| 178 | <indexterm zone="sysstat sysstat-config">
|
---|
| 179 | <primary sortas="e-etc-sysconfig-sysstat">/etc/sysconfig/sysstat</primary>
|
---|
| 180 | </indexterm>
|
---|
| 181 | <indexterm zone="sysstat sysstat-config">
|
---|
| 182 | <primary sortas="e-etc-sysconfig-sysstat.ioconf">/etc/sysconfig/sysstat.ioconf</primary>
|
---|
| 183 | </indexterm>
|
---|
| 184 |
|
---|
| 185 | </sect3>
|
---|
| 186 |
|
---|
[eb2cf83a] | 187 | <sect3>
|
---|
| 188 | <title>Cron Information</title>
|
---|
| 189 |
|
---|
[b1532549] | 190 | <para>
|
---|
| 191 | To begin gathering <application>Sysstat</application> history
|
---|
| 192 | information, you must add to, or create a privileged user's crontab.
|
---|
| 193 | The history data location is
|
---|
| 194 | <filename class="directory">/var/log/sa</filename>. The user running
|
---|
| 195 | <application>Sysstat</application> utilities via cron must have write
|
---|
| 196 | access to this location.
|
---|
| 197 | </para>
|
---|
[eb2cf83a] | 198 |
|
---|
[b1532549] | 199 | <para>
|
---|
| 200 | Below is an example of what to install in the crontab. Adjust the
|
---|
| 201 | parameters to suit your needs. Use <command>man sa1</command> and
|
---|
| 202 | <command>man sa2</command> for information about the commands.
|
---|
| 203 | </para>
|
---|
[eb2cf83a] | 204 |
|
---|
| 205 | <screen><literal># 8am-7pm activity reports every 10 minutes during weekdays
|
---|
[f384a9d] | 206 | 0 8-18 * * 1-5 /usr/lib/sa/sa1 600 6 &
|
---|
[481b3e8] | 207 |
|
---|
[f384a9d] | 208 | # 7pm-8am activity reports every hour during weekdays
|
---|
| 209 | 0 19-7 * * 1-5 /usr/lib/sa/sa1 &
|
---|
[481b3e8] | 210 |
|
---|
[f384a9d] | 211 | # Activity reports every hour on Saturday and Sunday
|
---|
| 212 | 0 * * * 0,6 /usr/lib/sa/sa1 &
|
---|
[481b3e8] | 213 |
|
---|
[f384a9d] | 214 | # Daily summary prepared at 19:05
|
---|
[eb2cf83a] | 215 | 5 19 * * * /usr/lib/sa/sa2 -A &</literal></screen>
|
---|
| 216 |
|
---|
[b1532549] | 217 | <para>
|
---|
| 218 | Ensure you submit the revised crontab to the cron daemon.
|
---|
| 219 | </para>
|
---|
[eb2cf83a] | 220 |
|
---|
| 221 | </sect3>
|
---|
| 222 |
|
---|
| 223 | <sect3 id="sysstat-init">
|
---|
| 224 | <title>System Startup Information</title>
|
---|
| 225 |
|
---|
| 226 | <indexterm zone="sysstat sysstat-init">
|
---|
| 227 | <primary sortas="f-sysstat">sysstat</primary>
|
---|
| 228 | </indexterm>
|
---|
| 229 |
|
---|
[b1532549] | 230 | <para revision="sysv">
|
---|
| 231 | At system startup, a LINUX RESTART message must be
|
---|
| 232 | inserted in the daily data file to reinitialize the kernel counters.
|
---|
| 233 | This can be automated by installing the
|
---|
| 234 | <filename>/etc/rc.d/init.d/sysstat</filename> init script included in
|
---|
| 235 | the <xref linkend="bootscripts"/> package using the following command
|
---|
| 236 | as the <systemitem class="username">root</systemitem> user:
|
---|
| 237 | </para>
|
---|
[1552ac8] | 238 |
|
---|
| 239 | <screen role="root" revision="sysv"><userinput>make install-sysstat</userinput></screen>
|
---|
| 240 |
|
---|
[b1532549] | 241 | <para revision="systemd">
|
---|
| 242 | At system startup, a LINUX RESTART message must
|
---|
| 243 | be inserted in the daily data file to reinitialize the kernel counters.
|
---|
| 244 | This can be automated by enabling the previously installed systemd unit
|
---|
| 245 | by running the following command as the
|
---|
| 246 | <systemitem class="username">root</systemitem> user:
|
---|
| 247 | </para>
|
---|
[eb2cf83a] | 248 |
|
---|
[1552ac8] | 249 | <screen role="root" revision="systemd"><userinput>systemctl enable sysstat</userinput></screen>
|
---|
[eb2cf83a] | 250 |
|
---|
| 251 | </sect3>
|
---|
| 252 |
|
---|
| 253 | </sect2>
|
---|
| 254 |
|
---|
| 255 | <sect2 role="content">
|
---|
| 256 | <title>Contents</title>
|
---|
| 257 |
|
---|
| 258 | <segmentedlist>
|
---|
| 259 | <segtitle>Installed Programs</segtitle>
|
---|
| 260 | <segtitle>Installed Libraries</segtitle>
|
---|
| 261 | <segtitle>Installed Directories</segtitle>
|
---|
| 262 |
|
---|
| 263 | <seglistitem>
|
---|
[b1d3c72a] | 264 | <seg>cifsiostat, iostat, mpstat, pidstat, sadf, sar, and tapestat</seg>
|
---|
[eb2cf83a] | 265 | <seg>None</seg>
|
---|
[b9a81999] | 266 | <seg>/usr/lib/sa,
|
---|
[fb19ab2c] | 267 | /usr/share/doc/sysstat-&sysstat-version; and
|
---|
[59382ab] | 268 | /var/log/sa
|
---|
| 269 | </seg>
|
---|
[eb2cf83a] | 270 | </seglistitem>
|
---|
| 271 | </segmentedlist>
|
---|
| 272 |
|
---|
| 273 | <variablelist>
|
---|
| 274 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 275 | <?dbfo list-presentation="list"?>
|
---|
| 276 | <?dbhtml list-presentation="table"?>
|
---|
| 277 |
|
---|
[fdc00738] | 278 | <varlistentry id="cifsiostat">
|
---|
| 279 | <term><command>cifsiostat</command></term>
|
---|
| 280 | <listitem>
|
---|
[b1532549] | 281 | <para>
|
---|
| 282 | displays statistics about read and write operations on CIFS
|
---|
[4c24eb0a] | 283 | filesystems
|
---|
[b1532549] | 284 | </para>
|
---|
[fdc00738] | 285 | <indexterm zone="sysstat cifsiostat">
|
---|
| 286 | <primary sortas="b-cifsiostat">cifsiostat</primary>
|
---|
| 287 | </indexterm>
|
---|
| 288 | </listitem>
|
---|
| 289 | </varlistentry>
|
---|
| 290 |
|
---|
[eb2cf83a] | 291 | <varlistentry id="iostat">
|
---|
| 292 | <term><command>iostat</command></term>
|
---|
| 293 | <listitem>
|
---|
[b1532549] | 294 | <para>
|
---|
| 295 | reports CPU statistics and input/output
|
---|
[4c24eb0a] | 296 | statistics for devices and partitions
|
---|
[b1532549] | 297 | </para>
|
---|
[eb2cf83a] | 298 | <indexterm zone="sysstat iostat">
|
---|
| 299 | <primary sortas="b-iostat">iostat</primary>
|
---|
| 300 | </indexterm>
|
---|
| 301 | </listitem>
|
---|
| 302 | </varlistentry>
|
---|
| 303 |
|
---|
[fdc00738] | 304 | <varlistentry id="mpstat">
|
---|
| 305 | <term><command>mpstat</command></term>
|
---|
[b058cd3] | 306 | <listitem>
|
---|
[b1532549] | 307 | <para>
|
---|
[4c24eb0a] | 308 | writes activities for each available processor
|
---|
[b1532549] | 309 | </para>
|
---|
[fdc00738] | 310 | <indexterm zone="sysstat mpstat">
|
---|
| 311 | <primary sortas="b-mpstat">mpstat</primary>
|
---|
[b058cd3] | 312 | </indexterm>
|
---|
| 313 | </listitem>
|
---|
| 314 | </varlistentry>
|
---|
| 315 |
|
---|
[5a195f0f] | 316 | <varlistentry id="pidstat">
|
---|
| 317 | <term><command>pidstat</command></term>
|
---|
| 318 | <listitem>
|
---|
[b1532549] | 319 | <para>
|
---|
| 320 | is used for monitoring individual tasks currently being managed
|
---|
[4c24eb0a] | 321 | by the Linux kernel
|
---|
[b1532549] | 322 | </para>
|
---|
[5a195f0f] | 323 | <indexterm zone="sysstat pidstat">
|
---|
| 324 | <primary sortas="b-pidstat">pidstat</primary>
|
---|
| 325 | </indexterm>
|
---|
| 326 | </listitem>
|
---|
| 327 | </varlistentry>
|
---|
| 328 |
|
---|
[5ba48e8] | 329 | <varlistentry id="sadf">
|
---|
| 330 | <term><command>sadf</command></term>
|
---|
| 331 | <listitem>
|
---|
[b1532549] | 332 | <para>
|
---|
| 333 | is used for displaying the contents of data files created by
|
---|
| 334 | the <command>sar</command> command. But unlike
|
---|
| 335 | <command>sar</command>, <command>sadf</command> can write its data
|
---|
[4c24eb0a] | 336 | in many different formats
|
---|
[b1532549] | 337 | </para>
|
---|
[5ba48e8] | 338 | <indexterm zone="sysstat sadf">
|
---|
| 339 | <primary sortas="b-sadf">sadf</primary>
|
---|
| 340 | </indexterm>
|
---|
| 341 | </listitem>
|
---|
| 342 | </varlistentry>
|
---|
| 343 |
|
---|
[fdc00738] | 344 | <varlistentry id="sar">
|
---|
| 345 | <term><command>sar</command></term>
|
---|
| 346 | <listitem>
|
---|
[b1532549] | 347 | <para>
|
---|
| 348 | is used for displaying the contents of elected cumulative activity
|
---|
[4c24eb0a] | 349 | counters in the operating system
|
---|
[b1532549] | 350 | </para>
|
---|
[fdc00738] | 351 | <indexterm zone="sysstat sar">
|
---|
| 352 | <primary sortas="b-sar">sar</primary>
|
---|
| 353 | </indexterm>
|
---|
| 354 | </listitem>
|
---|
| 355 | </varlistentry>
|
---|
| 356 |
|
---|
[b9a81999] | 357 | <varlistentry id="tapestat">
|
---|
| 358 | <term><command>tapestat</command></term>
|
---|
| 359 | <listitem>
|
---|
[b1532549] | 360 | <para>
|
---|
| 361 | is used for monitoring the activity of tape drives connected to
|
---|
[4c24eb0a] | 362 | a system
|
---|
[b1532549] | 363 | </para>
|
---|
[b9a81999] | 364 | <indexterm zone="sysstat tapestat">
|
---|
| 365 | <primary sortas="b-tapestat">tapestat</primary>
|
---|
| 366 | </indexterm>
|
---|
| 367 | </listitem>
|
---|
| 368 | </varlistentry>
|
---|
| 369 |
|
---|
[eb2cf83a] | 370 | </variablelist>
|
---|
| 371 |
|
---|
| 372 | </sect2>
|
---|
[f384a9d] | 373 |
|
---|
| 374 | </sect1>
|
---|