Operating System - HP-UX
1834814 Members
2789 Online
110070 Solutions
New Discussion

How to collect the memory utilisation for a month

 
SOLVED
Go to solution
Kenn Chen
Advisor

How to collect the memory utilisation for a month

In term of disk and CPU, we can use sar command to collect the usage data, so how about the memory usage data ?
Cyber Zen
2 REPLIES 2
Denver Osborn
Honored Contributor

Re: How to collect the memory utilisation for a month

maybe vmstat is what you are looking for?

# man vmstat

Have you thought about using any utilities like glance?
federico_3
Honored Contributor
Solution

Re: How to collect the memory utilisation for a month



In order to collect data about memory you can insert in the cron a script that sends the informations in a log file.

0,10,20,30,40,50 0-23 * * * path_file >> /tmp/vmstat.log

the file could be like this:

#!/bin/ksh
export data=`date +%d/%m" "%H:%M `

vmstat -nS 1 1 | awk '{dd = ENVIRON["data"]; print dd "### "$0 }'


i hope this helps

federico