in reply to Daemonized with max processes

Perhaps it's just me, but supposing you give this program 5 files to work on, then you'll never actually execute the wait, since $processes >= $MAX_PROCESSES will never be true. This is probably why you're getting Zombies.

I am no expert on this front, but if I were you, I'd try maintaining a global "child count" variable, and have a $SIG{CHLD} handler that decremented this value. Then, in your loop, you can check to see if there are any spaces to create another free child, and if so then do the fork.