in reply to Run perl script from web page

I hope the replies above are helpful. This is not a situation that I've had to face, but looking at your code, and thinking about the situation in general, I wanted to raise some points: There are other issues that I'd expect to arise, but again, I'm not that familiar with the issues... things like zombie processes (parents going away and leaving unreaped children behind).

On the whole, I'm thinking there must be a better way to actually run this process, other than launching it directly from a cgi script -- e.g. as suggested in a previous reply, you could have a cron process running every few minutes or so, to check whether a request has come in to run fsscan and if so, go ahead and run it (and don't accept any more requests until that run is finished). Then all the cgi script has to do is write some little file somewhere to indicate that such a request has been made.

Replies are listed 'Best First'.
Re^2: Run perl script from web page
by smist (Acolyte) on May 24, 2007 at 02:43 UTC
    All very good points. Thank you very much. As I posted previously, I found that the problem was with the pico http server I was using. I tried similar code on my home Linux box running Apache and it worked fine. I do like the cron idea especially and will look at implementing it. As far as security, this particular server is not accessible from the Internet. It's for internal use only.

    Thanks again!