[comp.sys.apollo] more on process sizes

gjalt@ele.tue.nl (Gjalt de Jong) (02/14/91)

In addition to previous postings on process sizes:

Who can explain to me why a 'ps l' and a 'ps u' do not agree on the sizes of
the processes. For example:

ps aux:
USER       PID   SZ  RSS TTY     STAT  TIME COMMAND
root         1  768  536 ?       S <   0:12 /etc/init
root         2    0    0 ?       R   1207:17 null
root         3    0    0 ?       S     1:01 purifier
root         4    0    0 ?       S     0:02 purifier
root         5    0    0 ?       S     2:24 unwired_dxm
root         6    0    0 ?       S     0:00 pinger
root         7    0    0 ?       S     0:42 netreceive
root         8    0    0 ?       S     0:39 netpaging
root         9    0    0 ?       S     1:39 wired_dxm
root        10    0    0 ?       S     2:11 netrequest
root        89  512  124 ?       S     8:11 /etc/tcpd -c
root        96  512   72 ?       S     0:04 /etc/syslogd
root        99  512   68 ?       S     0:20 /etc/routed -f -q
root       102  512   64 ?       S     0:00 /etc/inetd
root       105  512  140 ?       S     0:01 /etc/named
root       109  256   64 ?       S     0:31 /etc/rwhod
root       113  256  124 ?       S <   1:45 /usr/local/bin/xntpd -b
root       116  512  124 ?       S     0:00 /etc/snmpd
root       121  256   68 ?       S     0:02 /etc/ncs/llbd
root       125  256   64 ?       S     0:43 /etc/cron
user       133  256   44 ?       S     0:04 /sys/spm/spm
user       135  256   76 ?       S     0:00 /etc/writed
user       139  512   12 ?       S     0:00 /sys/mbx/mbx_helper
root       142 2048  360 ?       S <  19:53 /etc/Xapollo -K /usr/X11/lib/keyboard/keyboard.config -D1 s+r-
sys_pers   145  512  824 ?       S <   9:39 dm
root       748  512  168 ?       S     0:00 rshd
michel     754 1792  600 ?       S     3:39 gnuemacs -i -font f7x13.b -w =80x55-0+0 -b 3 -ms red
root      1356  512   40 ?       S     0:25 rlogind
root      1430  512   52 ?       S     0:04 rlogind
root      1591  512  172 ?       S     0:00 rshd
gjalt     1592  512  192 ?       S     0:00 csh -c ps aux
gjalt     1596  512  172 ?       R     0:00 ps aux
geert     1357  512  140 ttyp0   S     0:04 -sh
geert     1585  256  136 ttyp0   S     0:00 time n_ptl -v -R ../examples/mul4.ptl
geert     1586 5120 4384 ttyp0   R     5:17 n_ptl -v -R ../examples/mul4.ptl
frans      870  256   76 ttyp1   S     0:16 /usr/local/emacs-18.56/etc/loadst -n 60
michel     755  256   76 ttyp2   S     0:20 /usr/local/emacs-18.56/etc/loadst -n 60
michel     756  512  196 ttyp3   S     0:02 /bin/csh -i
michel    1235  512  112 ttyp3   S     0:01 /bin/sh decom_all apex3.log apex4.lo
michel    135510624016680 ttyp3   R   570:12 log_decom primes12
ed        1431  512  132 ttyp4   S     0:02 -csh
ed        1547  256  536 ttyp4   S     0:02 xload
michel     822  512  128 ttyp5   S     0:03 /bin/csh -i
michel     826  256  184 ttyp5   S     1:34 xload
frans      869 1024  424 ttyp5   S     1:08 gnuemacs
frans      871  512  120 ttyp6   S     0:01 /bin/csh -i

ps alx:
      F   UID   PID  PPID CP PRI NI ADDR   SZ  RSS STAT TTY      TIME COMMAND
1008001     0     1     1  0   1-20    1  512  536 S <  ?        0:12 /etc/init
      3     0     2     0  0  17  0    0    0    0 R    ?      1207:17 null
      3     0     3     0  0   1  0    0    0    0 S    ?        1:01 purifier
      3     0     4     0  0   1  0    0    0    0 S    ?        0:02 purifier
      3     0     5     0  0   1  0    0    0    0 S    ?        2:25 unwired_dxm
      3     0     6     0  0   1  0    0    0    0 S    ?        0:00 pinger
      3     0     7     0  0   1  0    0    0    0 S    ?        0:42 netreceive
      3     0     8     0  0   1  0    0    0    0 S    ?        0:39 netpaging
      3     0     9     0  0   1  0    0    0    0 S    ?        1:39 wired_dxm
      3     0    10     0  0   1  0    0    0    0 S    ?        2:11 netrequest
1008001     0    89     1  0   3  0    5  256  124 S    ?        8:11 /etc/tcpd -c
1008001     0    96     1  0   3  0    6  256   72 S    ?        0:04 /etc/syslogd
1008001     0    99     1  0   3  0    7  256   68 S    ?        0:20 /etc/routed -f -q
1008001     0   102     1  0   3  0    8  256   64 S    ?        0:00 /etc/inetd
1008001     0   105     1  0   3  0    9  256  132 S    ?        0:01 /etc/named
1008001     0   109     1  0   3  0    a  256   64 S    ?        0:31 /etc/rwhod
1008001     0   113     1  0   1-12    c  256  124 S <  ?        1:45 /usr/local/bin/xntpd -b
1008001     0   116     1  0   3  0    d  256  124 S    ?        0:00 /etc/snmpd
1008001     0   121     1  0   3  0    4  256   68 S    ?        0:02 /etc/ncs/llbd
1008001     0   125     1  0   3  0    e  256   68 S    ?        0:43 /etc/cron
1008001    14   133     1  0   3  0   10  256   44 S    ?        0:04 /sys/spm/spm
1008001    14   135     1  0   3  0   11  256   76 S    ?        0:00 /etc/writed
1008001    14   139     1  0   3  0   12  256   12 S    ?        0:00 /sys/mbx/mbx_helper
1008001     0   142     1  0   1 -6    3 1536  360 S <  ?       19:53 /etc/Xapollo -K /usr/X11/
1008001    13   145     1  0   1-20    2  256  824 S <  ?        9:39 dm
1008001     0   748   102  0   3  0   17  256  168 S    ?        0:00 rshd
1008001    38   754     1  0   3  0   1d 1792  608 S    ?        3:39 gnuemacs -i -font
1008001     0  1356   102  0   3  0   16  256   44 S    ?        0:25 rlogind
1008001     0  1430   102  0   3  0   19  256   52 S    ?        0:04 rlogind
1008001     0  1597   102  0   3  0   23  256  164 S    ?        0:00 rshd
1008001    20  1598  1597  0   5  0   24  256  196 R    ?        0:00 csh -c ps alx
1008001    20  1602  1598  0   3  0   25  256  176 R    ?        0:00 ps alx
1008001    19  1357  1356  0   3  0   18  256  140 S    ttyp0    0:04 -sh
1008001    19  1585  1357  0   3  0   1e  256  136 S    ttyp0    0:00 time n_ptl -v -R ../examples/mul4.ptl
1008001    19  1586  1585  0  14  0   20 4864 4040 R    ttyp0    5:45 n_ptl -v -R ../examples/mul4.ptl
1008001    18   870   869  0   3  0   13  256   76 S    ttyp1    0:16 /usr/local/emacs-18.56/etc/loadst -n 60
1008001    38   755   754  0   3  0   1b  256   80 S    ttyp2    0:20 /usr/local/emacs-18.56/etc/loadst -n 60
1008001    38   756   754  0   3  0   1c  256  196 S    ttyp3    0:02 /bin/csh -i
1008001    38  1235   756  0   3  0    b  256  112 S    ttyp3    0:01 /bin/sh decom_all apex3.log
1008001    38  1355  1235  0  14  0    f10598416676 R    ttyp3  570:40 log_decom primes12
1008001    68  1431  1430  0   3  0   1a  256  132 S    ttyp4    0:02 -csh
1008001    68  1547  1431  0   3  0   22  256  536 S    ttyp4    0:02 xload
1008001    38   822   754  0   3  0   1f  256  128 S    ttyp5    0:03 /bin/csh -i
1008001    38   826   822  0   3  0   21  256  184 S    ttyp5    1:35 xload
1008001    18   869     1  0   4  0   14 1024  424 S    ttyp5    1:08 gnuemacs
1008001    18   871   869  0   3  0   15  256  120 S    ttyp6    0:01 /bin/csh -i

Especially note all the small processes with a size of 256 or 512kB

BTW, these ps's were run on a node running 10.3, but it's same for 10.2

Some more weirdness:
a running lisp after running 5 minutes, with a size of 16MB, showed to have a
resident size of only 156kB (on a DN2500 with 16MB memory), and there were 
no other time consuming processes running. Amazing isn't it?
--
__
Gjalt G. de Jong,                 | Phone: +(31)40-473345
Eindhoven University of Technology, Dept. of Electr. Eng. (ES/EH 7.26)
P.O. Box 513, 5600 MB Eindhoven, The Netherlands
Email: gjalt@ele.tue.nl

krowitz@RICHTER.MIT.EDU (David Krowitz) (02/15/91)

It appears that the listing from /bin/ps -alx shows the "size" to be
256 KB less than the listing from /bin/ps -aux. It occurs to me that 
the default stack size is (if I'm not wrong) 256 KB. Could this be the
difference?


 -- David Krowitz

krowitz@richter.mit.edu   (18.83.0.109)
krowitz%richter.mit.edu@eddie.mit.edu
krowitz%richter.mit.edu@mitvma.bitnet
(in order of decreasing preference)