<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: SAR in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320988#M187359</link>
    <description>why would you use both sa1 and sa2 ? - I guess both collect the same data.&lt;BR /&gt;&lt;BR /&gt;It could be because lack of space in /var/adm/sa file system. &lt;BR /&gt;&lt;BR /&gt;I believe the first 3 entries will suffice to record all the activities.</description>
    <pubDate>Thu, 01 Jul 2004 16:22:14 GMT</pubDate>
    <dc:creator>Sundar_7</dc:creator>
    <dc:date>2004-07-01T16:22:14Z</dc:date>
    <item>
      <title>SAR</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320986#M187357</link>
      <description>Hi, we have set in /var/spool/cron/crontabs/root the following lines: &lt;BR /&gt;&lt;BR /&gt;0 *       * *    0,6  /usr/lbin/sa/sa1&lt;BR /&gt;&lt;BR /&gt;0 8-17    * *    1-5  /usr/lbin/sa/sa1 1200 3&lt;BR /&gt;&lt;BR /&gt;0 18-7    * *    1-5  /usr/lbin/sa/sa1&lt;BR /&gt;&lt;BR /&gt;5 18      * *    1-5  /usr/lbin/sa/sa2 -s 8:00 -e 18:01 -i 3600 -u&lt;BR /&gt;&lt;BR /&gt;5 18      * *    1-5  /usr/lbin/sa/sa2 -s 8:00 -e 18:01 -i 3600 -b&lt;BR /&gt;&lt;BR /&gt;5 18      * *    1-5  /usr/lbin/sa/sa2 -s 8:00 -e 18:01 -i 3600 -q&lt;BR /&gt;&lt;BR /&gt;but the system only keep the information for ten days, but we need more days, somebody help me, please, thanks!</description>
      <pubDate>Thu, 01 Jul 2004 16:06:55 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320986#M187357</guid>
      <dc:creator>Luis Lino_1</dc:creator>
      <dc:date>2004-07-01T16:06:55Z</dc:date>
    </item>
    <item>
      <title>Re: SAR</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320987#M187358</link>
      <description>I think the removal of old sar files are controlled by the sa2 script. By default it will delete files older than a week.&lt;BR /&gt;&lt;BR /&gt;Try editing the /usr/lbin/sa/sa2 script and change the +7 in the find command at the end, to the number of day's worth of data you want to keep. eg(+14 for two weeks).&lt;BR /&gt;&lt;BR /&gt;regds,&lt;BR /&gt;Abdul.</description>
      <pubDate>Thu, 01 Jul 2004 16:21:33 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320987#M187358</guid>
      <dc:creator>Abdul Rahiman</dc:creator>
      <dc:date>2004-07-01T16:21:33Z</dc:date>
    </item>
    <item>
      <title>Re: SAR</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320988#M187359</link>
      <description>why would you use both sa1 and sa2 ? - I guess both collect the same data.&lt;BR /&gt;&lt;BR /&gt;It could be because lack of space in /var/adm/sa file system. &lt;BR /&gt;&lt;BR /&gt;I believe the first 3 entries will suffice to record all the activities.</description>
      <pubDate>Thu, 01 Jul 2004 16:22:14 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320988#M187359</guid>
      <dc:creator>Sundar_7</dc:creator>
      <dc:date>2004-07-01T16:22:14Z</dc:date>
    </item>
    <item>
      <title>Re: SAR</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320989#M187360</link>
      <description>Yes Abdul was right on.&lt;BR /&gt;&lt;BR /&gt;sa2 script has the following entry&lt;BR /&gt;&lt;BR /&gt;find /var/adm/sa \( -name 'sar*' -o -name 'sa*' \) -mtime +7 -exec rm {} \;&lt;BR /&gt;&lt;BR /&gt;that deletes files older than 7 days.&lt;BR /&gt;&lt;BR /&gt;Just schedule only the first 3 jobs.</description>
      <pubDate>Thu, 01 Jul 2004 16:23:50 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320989#M187360</guid>
      <dc:creator>Sundar_7</dc:creator>
      <dc:date>2004-07-01T16:23:50Z</dc:date>
    </item>
    <item>
      <title>Re: SAR</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320990#M187361</link>
      <description>Hi Luis,&lt;BR /&gt;&lt;BR /&gt;Check cron for any file trimming jobs.&lt;BR /&gt;sa1, sa2 &amp;amp; sadc should keep files in /var/adm/sa/saDD where DD is day of the month &amp;amp; will be held until it's overwritten by the next month's entry. &lt;BR /&gt;I'd also check the cron log to see if the job(s) are possibly failing.&lt;BR /&gt;&lt;BR /&gt;Rgds,&lt;BR /&gt;Jeff&lt;BR /&gt;</description>
      <pubDate>Thu, 01 Jul 2004 16:25:40 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320990#M187361</guid>
      <dc:creator>Jeff Schussele</dc:creator>
      <dc:date>2004-07-01T16:25:40Z</dc:date>
    </item>
    <item>
      <title>Re: SAR</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320991#M187362</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Actually you don't need to run sa2 command unless you want the reports to be generated automatically in which case you can follow the above suggestions. It does nothing but to run sar command with -f option. So anytime you want a report, you can get it using the command&lt;BR /&gt;&lt;BR /&gt;sar -f /var/adm/sa/sa&lt;DATE&gt; &amp;gt; your_outfile&lt;BR /&gt;&lt;BR /&gt;-Sri&lt;/DATE&gt;</description>
      <pubDate>Thu, 01 Jul 2004 16:58:39 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320991#M187362</guid>
      <dc:creator>Sridhar Bhaskarla</dc:creator>
      <dc:date>2004-07-01T16:58:39Z</dc:date>
    </item>
    <item>
      <title>Re: SAR</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320992#M187363</link>
      <description>The sa2 will convert the binary output to an ascii output that you can be human readable.&lt;BR /&gt;&lt;BR /&gt;You can put in info that tells sa2 to only keep a certain number of days. It can also be somewhere else that says only keep so many days of these files.&lt;BR /&gt;&lt;BR /&gt;Here is a script I have used that will keep these ascii outputs by months indefinitely (unless there is a specific job to do the cleaning).&lt;BR /&gt;&lt;BR /&gt;Put this in cron and run at 2357 hrs nightly. &lt;BR /&gt;&lt;BR /&gt;#!/bin/ksh&lt;BR /&gt;                                                                                &lt;BR /&gt;set `date +'%d %b %Y'`&lt;BR /&gt;DAY=$1&lt;BR /&gt;MONTH=$2&lt;BR /&gt;YEAR=$3&lt;BR /&gt;DATE=$DAY$MONTH$YEAR&lt;BR /&gt;PERF_HOME=/var/adm/sa/perf&lt;BR /&gt;                                                                                &lt;BR /&gt;if [ -d $PERF_HOME/$YEAR ]&lt;BR /&gt;then&lt;BR /&gt;  echo "directory exists" &amp;gt; /dev/null&lt;BR /&gt;else&lt;BR /&gt;  mkdir $PERF_HOME/$YEAR&lt;BR /&gt;fi&lt;BR /&gt;if [ -d $PERF_HOME/$YEAR/$MONTH ]&lt;BR /&gt;then&lt;BR /&gt;  echo "directory exists" &amp;gt; /dev/null&lt;BR /&gt;else&lt;BR /&gt;  mkdir $PERF_HOME/$YEAR/$MONTH&lt;BR /&gt;fi&lt;BR /&gt;                                                                                &lt;BR /&gt;# cpu report&lt;BR /&gt;/usr/lbin/sa/sa2 -i 300&lt;BR /&gt;mv /var/adm/sa/sar`date +\%d` $PERF_HOME/$YEAR/$MONTH/cpu.$DATE&lt;BR /&gt;                                                                                &lt;BR /&gt;# buffer cache report&lt;BR /&gt;/usr/lbin/sa/sa2 -b -i 300&lt;BR /&gt;mv /var/adm/sa/sar`date +\%d` $PERF_HOME/$YEAR/$MONTH/bufcache.$DATE&lt;BR /&gt;                                                                                &lt;BR /&gt;# disk activity report&lt;BR /&gt;/usr/lbin/sa/sa2 -d -i 300&lt;BR /&gt;mv /var/adm/sa/sar`date +\%d` $PERF_HOME/$YEAR/$MONTH/diskio.$DATE&lt;BR /&gt;                                                                                &lt;BR /&gt;# inode, test, and process report&lt;BR /&gt;/usr/lbin/sa/sa2 -v -i 300&lt;BR /&gt;mv /var/adm/sa/sar`date +\%d` $PERF_HOME/$YEAR/$MONTH/inode.$DATE&lt;BR /&gt;                                                                                &lt;BR /&gt;# semaphore report&lt;BR /&gt;/usr/lbin/sa/sa2 -m -i 300&lt;BR /&gt;mv /var/adm/sa/sar`date +\%d` $PERF_HOME/$YEAR/$MONTH/semaphore.$DATE&lt;BR /&gt;                                                                                &lt;BR /&gt;# swap report&lt;BR /&gt;/usr/lbin/sa/sa2 -w -i 300&lt;BR /&gt;mv /var/adm/sa/sar`date +\%d` $PERF_HOME/$YEAR/$MONTH/swap.$DATE&lt;BR /&gt;</description>
      <pubDate>Thu, 01 Jul 2004 22:09:16 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320992#M187363</guid>
      <dc:creator>Rick Garland</dc:creator>
      <dc:date>2004-07-01T22:09:16Z</dc:date>
    </item>
    <item>
      <title>Re: SAR</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320993#M187364</link>
      <description>Thanks, we have changed sa2 script and our system is working ok.</description>
      <pubDate>Mon, 05 Jul 2004 10:14:56 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sar/m-p/3320993#M187364</guid>
      <dc:creator>Luis Lino_1</dc:creator>
      <dc:date>2004-07-05T10:14:56Z</dc:date>
    </item>
  </channel>
</rss>

