in reply to Re: Long running task from web app
in thread Long running task from web app

Thanks. I guess I should mention that I don't want to hang around and wait for the job to complete. I have no interest in comunicating with or monitoring the child process - I just want to kick off the job and let it run .. cos it will take ages, and the user will want to move onto other things. From my understanding of the doco for the modules above, they're all about communicating with the child process

Replies are listed 'Best First'.
Re^3: Long running task from web app
by ikegami (Patriarch) on Mar 04, 2006 at 02:55 UTC

    According to perlipc,

    On most Unix platforms, the CHLD (sometimes also known as CLD) signal has special behavior with respect to a value of 'IGNORE' . Setting $SIG{CHLD} to 'IGNORE' on such a platform has the effect of not creating zombie processes when the parent process fails to wait() on its child processes (i.e. child processes are automatically reaped). Calling wait() with $SIG{CHLD} set to 'IGNORE' usually returns -1 on such platforms.

    The alternative is to do something called "double forking", at least on unix. I'm not sure on the details, but a Super Search or a Google search for this should give you some info.

    But really, in this case, friedo's response is probably the best for you.