where are the processes?

Michael McDaniel erlang@REDACTED
Sat Apr 22 00:58:17 CEST 2006


SHORT:  etop says 'procs  734506' and 'runq  15902' though I can't
        find the processes

LONG: ...


SYSTEM:

  yaws 1.56 compiled and running on R10B-10 on Linux 

  Everything is started from yaws except for the process
  that the 404 error handler sends messages to.

  one appmod sends/receives messages with a persistent process

  another persistent process does some file monitoring

  a special 404 error handler sends a message to another
  persistent process (started independent of yaws).


  I start yaws thusly:

  /bin/su root -c " /usr/local/bin/yaws -sname yaws_autosys -heart  \
                    -pa /var/yaws/ebin -D -x                        \
                    -erlarg \"-config /var/yaws/ebin/sys.config\"   \
                  "

  and contents of sys.config are

  [{mnesia, [{dir, "/var/yaws/Mnesia.yaws_autosys"}]}].



Everything seems to work fine.  This all runs on a remote machine.
I login to that machine via ssh and run the following:


I have been noticing that, when running etop as

$ erl -sname etop -hidden -s etop -s erlang halt -output text \
      -lines 27 -interval 33 -node 'yaws_autosys@REDACTED'
  
I am seeing an increasing number of processes and also of 
run queue processes, for example,

========================================================================
yaws_autosys@REDACTED                                               20:25:01

Load: cpu      0        Memory:  total      756842    binary        121
      procs  734563              processes       0    code          543
       runq   15736              atom         4626    ets           342

------------------------------------------------------------------------

When first starting, the procs is less than 1000, runq is zero or single
digit count, and total memory is less than ten megabytes.  binary, code,
ets, atom stay about the same.


Now, when I remote shell as follows,

$ erl -sname fu -remsh yaws_autosys@REDACTED
Erlang (BEAM) emulator version 5.4.13 [hipe]

Eshell V5.4.13  (abort with ^G)
(yaws_autosys@REDACTED)1> erlang:statistics(run_queue).
0
(yaws_autosys@REDACTED)2>
User switch command
 --> q
$

The zero processes from erlang:statistics/1 has me confused compared to
what I am seeing using erlang:statistics/1 and what etop is showing me.

I am concerned about all these processes I can't find and the large runq
shown by etop.

I can do etop:config(lines, 300) there are less than 300 processes listed;
same for i() from the remote shell.



QUESTIONS:

1) what are the two different run queues from erlang:statistics/1
   and the runq shown by etop?

2) how can I see (via some text mode tool) what the actual processes
   and processes in the runq that etop says exist ?


thanks,

~Michael



More information about the erlang-questions mailing list