Page 1 of 1

How to check 'how much ram and cpu a process is consuming'

Posted: 2010/03/19 18:35:51
by DANNDP
Hello my friends,

I'm trying to check how much ram memmory and CPU is a particular process consuming, i have checked free -m and top but is not esay to undesrtand the output from CPU

What i need is to check the consuming for a particular process; with free -m i'm able to see only the available space of memmry and i want to know how much is consuming a particular process, the same with 'top'

It's hard ot understan the output from top, to many columns and MAY process, not easy to check the process i want to monitor

Thanks in advance for your help

How to check 'how much ram and cpu a process is consuming'

Posted: 2010/03/19 18:47:42
by pschaff
man top
top -p -p ...

Re: How to check 'how much ram and cpu a process is consuming'

Posted: 2010/03/19 19:21:25
by DANNDP
Thanks Phil,

Do you see any weird here:
[code]
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
21040 root 15 0 30180 12m 5788 S 0.0 0.3 2:08.19 asterisk
[/code]
Thanks again!

Re: How to check 'how much ram and cpu a process is consuming'

Posted: 2010/03/19 19:28:57
by pschaff
Not that I can spot. Watching the change over time might tell you something. Should asterisk run as root?

Re: How to check 'how much ram and cpu a process is consuming'

Posted: 2010/03/19 21:04:30
by DANNDP
Thanks Phil,

What should i check over the time? the problem is that this application (Asterisk) get freezed "some times" and i want to know why?

Whats the meaning of PR? NI? VIRT? RES? SHR? S? %CPU? %MEM? TIME+?

Thanks in advance my friend

Regards!

Re: How to check 'how much ram and cpu a process is consuming'

Posted: 2010/03/19 21:37:38
by pschaff
[quote]
DANNDP wrote:
What should i check over the time? the problem is that this application (Asterisk) get freezed "some times" and i want to know why?[/quote]
My guess is primarily CPU and MEM. May also want to keep an eye on swap usage.

[quote]
Whats the meaning of PR? NI? VIRT? RES? SHR? S? %CPU? %MEM? TIME+?
[/quote]
man top