]> git.itanic.dy.fi Git - rrdd/commit
jobcontrol: Fork bomb prevental
authorTimo Kokkonen <timo.t.kokkonen@iki.fi>
Sun, 28 Oct 2012 16:12:08 +0000 (18:12 +0200)
committerTimo Kokkonen <timo.t.kokkonen@iki.fi>
Sun, 28 Oct 2012 16:19:56 +0000 (18:19 +0200)
commitd5f03d9c3a441beee543e1aceaf4bf3d3bccc994
treeb82d7e8ea5ac9d5eb8339d81a51448fd387035e3
parentd5c899de72475b042eaca85e7748bf422c6a6c2f
jobcontrol: Fork bomb prevental

If something happens that prevents existing jobs from terminating, it
is generally bad practice to keep on forking more processes
indefinitely. To alleviate the problem, implement a somewhat trivial
process limitation feature. This will define a limit of maximum number
for the processes pending execution. If the number exceeds the global
limit, new processes are to be terminate itself immediately.

This however prevents only "limited forks" for creating too many
processes for waiting execution. Normal forks still have no
limit. This should still make the system to stay alive longer during
situations where something prevents (temporarily) executing processes
to finish in time.

Signed-off-by: Timo Kokkonen <timo.t.kokkonen@iki.fi>
process.c