Page 1 of 1

SAR (System Activity Report)

Posted: 2024-02-22 11:25
by jasonnix
Hello,
Does anyone have experience with SAR? I installed SAR, then I activated and executed it using the following commands

Code: Select all

# systemctl enable sysstat
#
# systemctl start sysstat
This program created the fileĀ /var/log/sysstat/sa21. I want to know if SAR is automatically recording system activities or need to write cron file?

Thank you.

Re: SAR (System Activity Report)

Posted: 2024-02-23 04:59
by NorthEast
If /var/log/sysstat/sa21 is created, and sysstat is enabled in /etc/default/sysstat, and systemctl has enabled and started it, then a command like:
sar -u
would normally show output of the current CPU usage for the current day. If it's not working, the output will say that sysstat can't open the relevant file.