![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Forum Rules | FAQ | Contribute | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Explain the line "mn_code=`env|grep "..mn"|awk -F"=" '{print $2}'`" | Lokesha | UNIX for Dummies Questions & Answers | 4 | 12-19-2007 10:52 PM |
| Debian: doubt in "top" %CPU and "sar" output | jaduks | Linux | 0 | 09-12-2007 05:05 AM |
| "highlighting the text in ur output" | sakthi.abdullah | Shell Programming and Scripting | 6 | 12-11-2006 02:51 PM |
| Use "read" with a text file with comments | mbarberis | Shell Programming and Scripting | 3 | 03-29-2005 11:24 PM |
| Convert "text" to "packed-decimal"? | HuskyJim | UNIX for Dummies Questions & Answers | 2 | 06-08-2001 11:59 AM |
|
|
Submit Tools | LinkBack | Thread Tools | Search this Thread | Display Modes |
|
#8
|
|||
|
|||
|
>prtconf -v | grep -i mem
Memory size: 2048 Megabytes memory (driver not attached) virtual-memory (driver not attached) memory-controller, instance #0 memory-controller, instance #1 This seems to return the amount of physical memory I have, but not what is being used. We are getting closer! |
| Forum Sponsor | ||
|
|
|
#9
|
||||
|
||||
|
doing 'man vmstat' yields:
Code:
memory
Report on usage of virtual and real memory.
swap amount of swap space currently available
(Kbytes)
free size of the free list (Kbytes)
I'm not sure though - others might correct the 'math' |
|
#10
|
|||
|
|||
|
Since your question is performance related, you really don't need to know how much physical memory is in use. vmstat will give you the performance information you're looking for (I cleaned up the output a little, format wise).
Code:
$ vmstat 5 procs memory page disk faults cpu r b w swap free re mf pi po fr de sr s6 s8 s8 s8 in sy cs us sy id 0 0 0 14334608 10300056 25 146 13 1 1 0 0 0 0 0 0 708 172 4666 2 2 96 0 0 0 14221840 9149336 0 2 0 0 0 0 0 0 0 0 0 622 6071 3948 0 1 99 0 0 0 14221864 9149360 0 1 0 0 0 0 0 0 1 0 0 808 6476 4026 0 1 98 0 0 0 14221880 9149376 0 0 0 0 0 0 0 0 0 0 0 647 6157 3998 0 1 98 The sr column (Scan Rate) is probably the most important when determining whether you're short on memory or not. When this number gets to a high rate (200 pages per second averaged over 30 seconds), then you're short on memory and need to add more. Swap space and available swap isn't a real help since the system will balance things out and the free column will stablize out. For CPU's, four times the number of CPUs in the run queue (the procs/r column) means you should add another cpu. For disk slowness, the blocked queue gives you the info (procs/b column). If b => r then you should look at balancing your data or perhaps getting a RAID in place. Carl |
|
#11
|
|||
|
|||
|
Did you lookat pmap
pmap -x <PID> |
|
#12
|
|||
|
|||
|
Quote:
Carl |
|
#13
|
|||
|
|||
|
I am very appreciative that you are all helping me with this. Let me first explain what I am trying to accomplish, and then let me ask for clarification about vmstat and top.
I am a middleware sys admin (not a Unix admin). I do a daily healthcheck of the Solaris servers where my software (MQSeries) runs. In addition to looking at specific MQ logs and queues, I also look at some system-level stats, including CPU and memory usage. This is not a "scientific" look; rather, it's a point-in-time peek that has allowed me to develop a "baseline" of normal operations. I look at the system-level stuff because 1) these are dedicated middleware servers & nothing else runs on them and 2) MQ & related software spawns many processes (that's why I don't just look at one process). This approach has helped me catch problems several times. My specific question about vmstat and top is about interpreting the data. (Remember, I'm not a unix admin!) Here is vmstat output: r b w swap free re mf pi po fr de sr m1 m1 m1 m2 in sy cs us sy id 0 0 0 5622568 1636016 38 137 5 0 0 0 0 0 0 0 0 258 1235 307 1 1 99 I *think* this means that I have 5.6 Gb of total memory available, of which 1.6 Gb is free. Here is the top output: Memory: 2048M real, 1555M free, 4099M swap free I *think* this means that I have 2.0 GB of physical memory, of which 1.5 Gb is free AND I have 4.1 GB of swap that is also free. I must not understand how to read these outputs, eh? Gratefully yours, Shirley |
|||
| Google The UNIX and Linux Forums |