- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: SAR Command help.
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-03-2004 07:52 AM
02-03-2004 07:52 AM
SAR Command help.
I need to capture total cpu utilization and Load Average on the box using SAR. Can someone help me with the commands?
Thanks
Joe.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-03-2004 07:56 AM
02-03-2004 07:56 AM
Re: SAR Command help.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-03-2004 08:01 AM
02-03-2004 08:01 AM
Re: SAR Command help.
sar -uq 5 10
will print 10 iterations of Utilization and Queue metrics (first and second row of each iteration respectively).
If you want to collect the stats over a period of time, then you will need to enable sar in cron. Look at the man page of 'sa1' and how it can be implemented in cron. Once the data is being collected through cron (it will be output to /var/adm/sa), you can extract the previous information with the sar command (look at -s and -e options of sar)
-Sri
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-03-2004 08:17 AM
02-03-2004 08:17 AM
Re: SAR Command help.
an alternative is to run for command line redirected to file.
sar -A 30 5000 > /tmp/outfile
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-03-2004 08:38 AM
02-03-2004 08:38 AM
Re: SAR Command help.
Thanks for the reply. What i am trying to do is to put a simple command in a script to find out the cpu utilization ans load and based on that i am trying to connect to different machines. I hope i am clear. The bottomline is if machine a's load is more than machine d then the connection would go to ,machine d. That is what i am trying to achieve.
Thanks Again,
Joe.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-03-2004 09:06 AM
02-03-2004 09:06 AM
Re: SAR Command help.
or
If you tail the last entry of the sar history,
sar -f /var/adm/sa/sa02
you'll be able to see the average load over prior 20 mins. ( time of this is configurable, as in the man sa1)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-03-2004 09:29 AM
02-03-2004 09:29 AM
Re: SAR Command help.
sar -u 1 1
means get cpu stats 1 time for 1 second and looks like this:
root> sar -u 1 1
HP-UX servername B.11.11 U 9000/800 02/03/04
16:27:05 %usr %sys %wio %idle
16:27:06 8 2 0 90