One question about SAR: Invalid system Activity File

Source: Internet
Author: User

Problem:
# Sar-q
Invalid system Activity File:/var/log/sa/sa04 (0x5)

Analysis Process:
1. Google: Get the following information:

From: http://sebastien.godard.pagesperso-orange.fr/faq.html

2. A different version of the SAR command that is suspected to be generating the SA data file and the resolution SA data file
# which SAR
/usr/local/bin/sar # This is my command to read the SA data file, version number 8.0.0
# sar-v
Sysstat version 8.0.0
(C) Sebastien Godard (sysstat <at> orange.fr)

3. How do I know which version of SAR is being used to generate the SA data file?
Typically these files are written in Cron, so grep the cron configuration file: (Note: grep SA is not grep SAR)
# grep Sa-r/etc/cron*
/ETC/CRON.D/SYSSTAT:*/10 * * * * ROOT/USR/LIB/SA/SA1 1 1
/etc/cron.d/sysstat:53 * * * root/usr/lib/sa/sa2-a

#/usr/lib/sa/sa1-v
Sysstat Version 7.0.2
(C) Sebastien Godard

4. Why is this happening?
The 7.0.2 version of SAR is in the/usr/bin/directory, and the $path variables in my execution environment are as follows:
# echo $PATH
/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin

First we found the SAR under/usr/local/bin.

Solution: (Write the full path of SAR)
#/usr/bin/sar-q

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.