SAR

I am running below script to display last 48 hour data but the output is not displaying heading -

AIX eqrdb26u1 1 6 00CFD5E34C00    01/21/10
System configuration: lcpu=8 ent=2.00 mode=Uncapped 
22:31:40    %usr    %sys    %wio   %idle   physc   %entc

and footer -

Average       25       9       1      64    0.72    35.8

SCRIPT:
--------

sar -f sa15 | grep -v Average | grep -v "^$" | grep -vi restart | grep -v System | grep -vi AIX | tail -48 > sa15.$$
mailx -s "Last 48 hours sar data at `date`" xyz@abc.com < sa15.$$

Please advice and also tel if if can make this script to run every hour without using crontab?

It does not display any header since you 1st grep for "Average" and so the header is lost. Maybe just add a printf somewhere in there with printing the header your own.
Also your chain of greps (crepes? :smiley: ) can be done with one grep like for example:

grep -viE "Average|^$|restart|System|AIX"

Your question about an alternative for cron has been answered in your other post where you explicit ask for this. Double posting is not allowed so keep your questions separated please.