How do you handle while(1) fork(); ?
Guy Harris
guy at auspex.auspex.com
Sun Jul 15 04:21:35 AEST 1990
>Am I missing something? I thought the kernel table had only so many
>slots for processes on the whole system, each of which is available
>to anyone.
Yes, you're missing something. Modern versions of UNIX (V7 and later)
(unless some exceptionally bright person took it out of some system)
allow only the super-user to take the last slot in the process table.
If you have a "getty" running on a terminal, you should log in as "root"
on that terminal; your shell uses the same process slot as the "getty",
and the "reserved" slot probably isn't taken up yet, thus increasing the
chances that slot will be available for "kill".
Alternatively, if you have a shell where "kill" is a built-in (e.g. the
C shell), the "kill" won't require another slot.
More information about the Comp.unix.questions
mailing list