Process killing Daemon. Ideas?

Mark Andrew Crichton (crichton@ecn.purdue.edu)
Fri, 23 Feb 1996 00:41:28 -0500 (EST)


Hello,

I was thinking a few days ago how nice it would be for me to be able
to kill errant processes under Linux even if I can't get to my shell command
line. It then came to pass that the SAK would be a great place to start, then
(seeing how almost everyone is using kerneld) use kerneld to spawn a little
program to interactively kill processes.

My problem is this. I would like to know how to a) get a list of
processes/mem size/cpu use/etc. (I think this is all in proc somewhere...anyone
got distilled documentation (I've got the kernel source...and grepping thru it
would work...)?) and b) somehow throttle enough system resources so that my
spawned process actually gets some CPU time (needs to be almost exclusive use
of the CPU, I think...someone correct me on this).

(A) should be simple. (B), on the other hand, is driving me nuts. It
needs to be able to..well..run, even if the machine was well into swap and
giving the appearance nothing was working. I was also wondering how much of
this stuff should go into the kernel and how much into user-space.

Anyone got any good suggestions?

Mark Crichton
crichton@ecn.purdue.edu