- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Script for monitoring the Utilization of CPU a...
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
12-09-2009 04:12 AM
12-09-2009 04:12 AM
I want to write a script to monitor the utilization of CPU and Physical Memory every 15 min for 24 hours so that later i can plot the graph for CPU and Memory utilization.And using internal HP-UX command i.e. sar,top and vmstat.
Thanks,
Narendra
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-09-2009 05:07 AM
12-09-2009 05:07 AM
Re: Script for monitoring the Utilization of CPU and Memory.
Read the relevant man pages: use the commands "man sar", "man top" and "man vmstat" to find the options you may need.
Find the commands that would produce the information you need if you had to do it manually. Then write the commands into a text file, one per line. You now have the basics of your script right there!
Read "man sh-posix" if you need to learn about shell script syntax, shell built-in commands or general features of the standard Posix shell.
MK
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-10-2009 12:11 AM
12-10-2009 12:11 AM
Re: Script for monitoring the Utilization of CPU and Memory.
this is monitoring script that uses glance.
#!/usr/bin/sh
GlnCmd=/opt/perf/bin/glance
WrkDir=~gpsactv/CHECK/scripts
GlnSyn=$WrkDir/gln_syntax_file
GlnOpt="-j60 -adviser_only -nosort -iterations 2 -bootup -syntax $GlnSyn"
ResLog=$(date +%Y%m)-res-cop.log
# Create glance syntax file
cat<
print "-- ",
gbl_statdate,
" ",
gbl_stattime,
" ",
gbl_cpu_total_util|3|0,
" ",
gbl_disk_util_peak|3|0,
" ",
gbl_mem_util|3|0,
" ",
gbl_swap_space_util|3|0
EOD
#echo -- MM/DD/YY HH:MM:SS CPU DSK MEM SWA
$GlnCmd $GlnOpt 2>/dev/null |tail +2 >>$WrkDir/../dat/$ResLog
#eof
HTH,
Art
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-10-2009 01:32 AM
12-10-2009 01:32 AM
Re: Script for monitoring the Utilization of CPU and Memory.
Bill McNAMARA created two threads to collect usefull scripts of any sort:
http://forums11.itrc.hp.com/service/forums/questionanswer.do?threadId=178514
HTH
Volkmar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-10-2009 06:44 AM
12-10-2009 06:44 AM
Solutionhttps://h10078.www1.hp.com/cda/hpms/display/main/hpms_content.jsp?zn=bto&cp=1-11-15-28^1792_4000_100__
You don't need to write a script, with Performance Manager you can reach back to historical data:
"
HP Performance Manager Software is a web-based analysis and visualization tool that analyzes performance trends of applications, systems, and services. This software helps you manage your application performance by enabling you to proactively detect and isolate server bottlenecks. It provides a consistent set of cross-platform metrics for heterogeneous physical and virtual environments. And it enables you to examine server utilization in real time and historical performance trends. "
Unix operates with beer.