-   Linux - Newbie (
-   -   CPU and memory usage?? (

msmeenamani 02-22-2009 12:40 AM

CPU and memory usage??
Can any one suggest a profiler or a command to get the exact cpu and memory usage of the system?? Some suggest valgrind, but i need the output in text format whereas valgrind displays it in graphical mode..

syg00 02-22-2009 12:45 AM

Define "exact"

msmeenamani 02-22-2009 01:54 AM

exact in the sense that ps command will only get the amount of memory pages allocated by that process,does not reflect the actual amount of memory used by the application. I need something tat gives the actual memory used by the process.

syg00 02-22-2009 02:49 AM

Meaning what ??? Way too nebulous.
Have a look at pmap, /proc/<pid>/maps and probably most useful /proc/<pid>/smaps

But the way shared libraries are (not) accounted for in Linux, all the numbers you can come up with will be fuzzy. Exact ain't a description I'd be using in any sense of the word.

All times are GMT -5. The time now is 01:42 AM.