Re: [SLUG] amount of allocated memory that's swapped out

From: Eben King (eben1@tampabay.rr.com)
Date: Tue Mar 16 2004 - 16:32:39 EST


On Tue, 16 Mar 2004, Backward Thinker wrote:

> Eben King wrote:
> > How can I find how much memory allocated to a process is swapped
> > out?
>
> Easiest way is with top.
>
> You can take VIRT - RES, but if they are reported in different units,
> then turning on the SWAP field is probably easiest :). To toggle on
> swap, press 'f' for fields, then 'p' and enter. Now you should see a
> new field called SWAP
>
> man 1 top says:
> p: SWAP -- Swapped size (kb)
> The swapped out portion of a task's total virtual memory image.

Mine (2.0.7) must be different:

  O: SWAP = Swapped kb

So if it says

  PID USER NI SIZE SWAP RSS SHARE WCHAN STAT %CPU %MEM CTIME COMMAND
12944 eben 0 480M 520 480M 479M R 0.1 63.4 2:35 vmware
12983 eben -19 56272 668 54M 55392 do_select S < 0.0 7.1 0:01 vmware

then _right now_ VMware has a total allocation of sum(SIZE)=535M of which
about 1.2M is swapped out, right?

-- 
The people don't want war, but it's always simple to drag the people along.
The people can always be brought to the bidding of the leaders.  All you
have to do is tell them they are being attacked, and denounce the pacifists
for lack of patriotism, and exposing the country. -- Hermann Goering

----------------------------------------------------------------------- This list is provided as an unmoderated internet service by Networked Knowledge Systems (NKS). Views and opinions expressed in messages posted are those of the author and do not necessarily reflect the official policy or position of NKS or any of its employees.



This archive was generated by hypermail 2.1.3 : Fri Aug 01 2014 - 19:21:46 EDT