how to find out 6 most memory-hungry processes – the 6 that are using the largest amount of RAM?

6 most memory-hungry processes  that are using the largest amount of RAM. and need to draw a line or bar or pie graph using memory. using PHP

Thank you
vishnu kalakotaAsked:
Who is Participating?
vishnu kalakotaAuthor Commented:
i have tried this one ..but am not sure is this correct r not?
ps -eo pmem,vsize,pid | sort -nr | head -7

6.0  3883268  1855
 5.3  3965284   380
 4.4  3070580   273
 3.2  3668732   203
 2.2  3475368  1894
 1.9  2832112   207
 1.8  3768628   147
Scott MadeiraCommented:
What have you tried so far?  We don't really write applications on this site but we can help with specific problems you encounter along the way.
vishnu kalakotaAuthor Commented:
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.