Wednesday, June 1, 2011

How to check CPU and Memory Leaks on Debian 6?

1. Memory Leak Check:
#top 10 applications
$ps -A --sort -rss -o comm,pmem | head -n 11

#Check All
$ps -A --sort -rss -o comm,pmem | less

2. CPU Leak Check
#top 10 applications
$ps -eo pcpu,pid,user,args | sort -k 1 -r | head -10

#check all
$ps -eo pcpu,pid,user,args | sort -r -k1 | less

Note: In using command "less", you can exit by pressing "q".

No comments:

Post a Comment