in reply to A Quick fork theory question

You might want to check out Parallel::ForkManager. I haven't used this myself yet, but I think that what you can do here is use finish() to return an error code, and run_on_finish() to specify what to do with that error code.

-- Frag.