in reply to Requires explicit package name
The warnings are being raised because you are using variables out of scope. For example, in your open statement, you call $houtputfile and $pid before declaring them with a "my" or, worse, giving them a value. I'd offer a fix, but I'm not sure what their values are supposed to be. Your %hfiles problems are easier to spot - perl is case sensitive, and you've declared %hFiles, not %hfiles.