1833641 Members
3692 Online
110062 Solutions
New Discussion

SysteM process Status

 
SOLVED
Go to solution
karthiknarayan
Advisor

SysteM process Status

Hi-

How to find the list Process that utilises most memory.

and how long the process are there in the sleeping state.
In Love with Life
5 REPLIES 5
Yang Qin_1
Honored Contributor

Re: SysteM process Status

Hi,

Do you have glance installed on your system?
glance can tell you a lot, CPU, Memory, system calls, Process WAIT ....

Regards,
Yang
sudhapage
Regular Advisor

Re: SysteM process Status

Hi,

You can use 'top' command to list top processes on the system.

Regards,
Sudhakaran.K
sudhapage
Regular Advisor

Re: SysteM process Status

In top command itself, you can find the STATE & How long that process in sleeping status and all the things.

Regards,
Sudhakaran.K
Ninad_1
Honored Contributor
Solution

Re: SysteM process Status

Hi,

Top will sort the output as per CPU % usage and not memory usage. A simpler method could be
UNIX95= ps -e -o "pid,user,sz,args" | sort -nr -k 3 | more

Note there is no space between UNIX95 and the = sign, whereas there is a space between = and ps.

The 3rd column is memory size in pages. 1 page = 4kb.

But you need to understand one thing is that the memory shown includes shared memory area and hence will be shown by all the processes using the shared memory not just one. e.g. if you have Oracle database - all the ora processes will show memory size including the shared memory used in terms of SGA by the Oracle processes. But this will give you a fair amount of idea which processes are using top memory.

Regards,
Ninad
spex
Honored Contributor

Re: SysteM process Status

Hi,

# UNIX95= ps -e -o pid= -o user= -o vsz= -o args= | sort -n -k3

'-o vsz' shows memory used in KB. Specifying the columns as separate options to 'ps' followed by '=' turns the column headers off.

PCS