How to tell when a job is swapping?

Daniel Kidger Daniel.Kidger at quadrics.com
Tue Feb 19 09:55:33 EST 2002



-----Original Message-----
From: Jeff Layton [mailto:jeffrey.b.layton at lmco.com]

>   I usually assume that if the free swap space falls below
>the maximum and load starts climbing that the node is
>swapping. However, when I talk to the user, he states that
>the code is running fine and the timing numbers are where
>they should be. So, I'm obviously interpreting something
>incorrectly (unless the job is really swapping but for some
>reason performance is unaffected).


if a job allocates large areas of memory (beyond physical available) , uses
them once - say fills them with zeroes and then  doesn't use much of that
array space, then:
   a/ you will be using swap space
but
   b/ performance is unaffected since these (unused) pages will get swapped
out pretty quickly, but never get swapped back in since they are never
referenced again.




If you want to watch swapping actually happening then one way is to run
vmstat, e.g. "/usr/bin/vmstat 2". look at the si and so columns. 
eg.  I   run 2 copies of a code that almost uses up all memory and then I
start a third copy (last two lines below)  which causes the machine to start
swaping frantically ...
 
[root at dell7 /root]# vmstat 2
   procs                      memory    swap          io     system
cpu
 r  b  w   swpd   free   buff  cache  si  so    bi    bo   in    cs  us  sy
id
 2  0  5  29540 620624   1688   7876  49  81   201    84   71    30  84   1
15
 2  0  5  29540 620624   1688   7876   0   0     0     0  127     8 100   0
0
 2  0  5  29540 620624   1688   7876   0   0     0     0  127    10 100   0
0
 2  0  5  29540 620624   1688   7876   0   0     0     0  128     8 100   0
0
 3  0  5  29540 269312   1688   7876   0   0     0     0  139    38  73  27
0
 3  0  5  29540  43816   1688   7876  36   0    36     0  135    32  84  16
0
 3  0  5  73612   3356   1672   7788   0 20732     0 20778  214   718  82
18   0
 2  1  5 115668   5700    292   4668  80 22100    80 22100  541  1468  78
22   0






Yours,
Daniel.

--------------------------------------------------------------
Dr. Dan Kidger, Quadrics Ltd.      daniel.kidger at quadrics.com
One Bridewell St., Bristol, BS1 2AA, UK         0117 915 5505
----------------------- www.quadrics.com --------------------
_______________________________________________
Beowulf mailing list, Beowulf at beowulf.org
To change your subscription (digest mode or unsubscribe) visit http://www.beowulf.org/mailman/listinfo/beowulf



More information about the Beowulf mailing list