Tag Archives: sysstat

Sysstat – CPU Load, Uptime. RAM usage check in Linux System

Automatic Installation

root@choi:~# apt-get install sysstat

Reading package lists… Done
Building dependency tree
Reading state information… Done
The following extra packages will be installed:
libsensors4 multiarch-support
Suggested packages:
lm-sensors isag
The following NEW packages will be installed:
libsensors4 multiarch-support sysstat
0 upgraded, 3 newly installed, 0 to remove and 282 not upgraded.
Need to get 595 kB of archives.
After this operation, 1,625 kB of additional disk space will be used.
Do you want to continue [Y/n]? y
Get:1 ftp://ftp.debian.org/debian/ testing/main multiarch-support amd64 2.13-38 [150 kB]
Get:2 ftp://ftp.debian.org/debian/ testing/main libsensors4 amd64 1:3.3.2-2 [54.9 kB]
Get:3 ftp://ftp.debian.org/debian/ testing/main sysstat amd64 10.0.5-1 [391 kB]
Fetched 595 kB in 18s (31.9 kB/s)
Preconfiguring packages …
Selecting previously deselected package multiarch-support.
(Reading database … 39769 files and directories currently installed.)
Unpacking multiarch-support (from …/multiarch-support_2.13-38_amd64.deb) …
Setting up multiarch-support (2.13-38) …
Selecting previously deselected package libsensors4.
(Reading database … 39773 files and directories currently installed.)
Unpacking libsensors4 (from …/libsensors4_1%3a3.3.2-2_amd64.deb) …
Selecting previously deselected package sysstat.
Unpacking sysstat (from …/sysstat_10.0.5-1_amd64.deb) …
Processing triggers for man-db …
Setting up libsensors4 (1:3.3.2-2) …
Setting up sysstat (10.0.5-1) …

Creating config file /etc/default/sysstat with new version
update-alternatives: using /usr/bin/sar.sysstat to provide /usr/bin/sar (sar) in auto mode.
root@choi:~#vi /etc/default/sysstat
change ENABLED=”false” to ENABLED=”true”
save the file

root@choi:~#vi /etc/cron.d/sysstat
5-55/10 * * * * root command -v debian-sa1 > /dev/null && debian-sa1 1 1
*/2 * * * * root command -v debian-sa1 > /dev/null && debian-sa1 1 1
save the file

root@choi:~#service sysstat restart
Starting the system activity data collector: sadc.

See all the statistics type the command below.

root@choi:~#sar -A


root@choi:~#sar -A > $(date +`hostname`-%d-%m-%y-%H%M.log)

You may also find the other options of the command.

root@choi:~#man sysstat
root@choi:~#man sar


Manual Installation

root@choi:~# apt-cache show sysstat
Package: sysstat
Priority: optional
Section: admin
Installed-Size: 872
Maintainer: Robert Luberda <robert@debian.org>
Architecture: amd64
Depends: libc6 (>= 2.7), debconf (>= 0.5) | debconf-2.0, ucf (>= 2.003), lsb-base (>= 3.0-6), bzip2
Recommends: cron
Suggests: isag
Conflicts: atsar (<< 1.5-3)
Filename: pool/main/s/sysstat/sysstat_9.0.6.1-2_amd64.deb
Size: 308104
MD5sum: 272651494df300c14c3a19a0401bda91
SHA1: 6c21e5962beb5c5e78a5cc784196a7ea5d7a73ed
SHA256: eef2ae99f7a5028d42a2da2aef51cdc4df21d4344999278136a2d69a57c81dbe
Description: system performance tools for Linux
The sysstat package contains the following system performance tools:
– sar: collects and reports system activity information;
– iostat: reports CPU utilization and disk I/O statistics;
– mpstat: reports global and per-processor statistics;
– pidstat: reports statistics for Linux tasks (processes);
– sadf: displays data collected by sar in various formats.
The statistics reported by sar deal with I/O transfer rates,
paging activity, process-related activities, interrupts,
network activity, memory and swap space utilization, CPU
utilization, kernel activities and TTY statistics, among
others. Both UP and SMP machines are fully supported.
Homepage: http://pagesperso-orange.fr/sebastien.godard/
Tag: admin::{accounting,benchmarking,monitoring}, implemented-in::c, interface::commandline, interface::daemon, role::program, use::measuring, use::monitor, works-with::logfile

We can download the install in this URL http://pagesperso-orange.fr/sebastien.godard/ specified in the Homepage section.








root@choi:~#cd /usr/src/

root@choi:/usr/src/#wget http://pagesperso-orange.fr/sebastien.godard/sysstat-10.1.5.tar.gz

root@choi:/usr/src/#tar -zxvf sysstat-10.1.5.tar.gz

root@choi:/usr/src/sysstat-10.1.5# ./configure –prefix=/opt/recon/dcm/platforms/CENTOS6 –disable-documentation –disable-stripping –disable-sensors –disable-nls

root@choi:/usr/src/sysstat-10.1.5# make

root@choi:/usr/src/sysstat-10.1.5# make install
mkdir -p /opt/recon/dcm/platforms/CENTOS6/lib/sa
mkdir -p /var/log/sa
mkdir -p /opt/recon/dcm/platforms/CENTOS6/bin
mkdir -p /opt/recon/dcm/platforms/CENTOS6/share/doc/sysstat-10.1.5
mkdir -p /etc/sysconfig
install -m 755 sa1 /opt/recon/dcm/platforms/CENTOS6/lib/sa
install -m 755 sa2 /opt/recon/dcm/platforms/CENTOS6/lib/sa
install -m 755 sadc /opt/recon/dcm/platforms/CENTOS6/lib/sa
install -m 755 sar /opt/recon/dcm/platforms/CENTOS6/bin
install -m 755 sadf /opt/recon/dcm/platforms/CENTOS6/bin
install -m 755 iostat /opt/recon/dcm/platforms/CENTOS6/bin
install -m 755 mpstat /opt/recon/dcm/platforms/CENTOS6/bin
install -m 755 pidstat /opt/recon/dcm/platforms/CENTOS6/bin
install -m 755 nfsiostat /opt/recon/dcm/platforms/CENTOS6/bin
install -m 755 cifsiostat /opt/recon/dcm/platforms/CENTOS6/bin
install -m 644 sysstat.ioconf /etc/sysconfig
install -m 644 sysstat.sysconfig /etc/sysconfig/sysstat