Just another Perl shrine | |
PerlMonks |
Re^2: No child processes - system limit?by clinton (Priest) |
on Apr 01, 2010 at 17:01 UTC ( [id://832344]=note: print w/replies, xml ) | Need Help?? |
Yes - in the parent process, I'm reading 5000 records from a source, then forking off a child to reindex each of those 5000 records. The parent forks $max_kids processes, recording the PIDs in a hash, then waits until there are fewer than $max_kids active.
My reaper looks like this:
Note, in the reaper, I set $Children{$pid} = 0 instead of deleting the key, as that was causing panic: freed scalar errors. I now clean up the %Children hash in the main loop of the parent. The error I'm seeing is at the stage in the parent when I'm reading the 5,000 records from the source thanks Clint
In Section
Seekers of Perl Wisdom
|
|