perl-embperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Cameron B. Prince" <cpri...@rideware.com>
Subject Forking
Date Fri, 12 Sep 2003 14:33:09 GMT
Hi all,

I have an Embperl page that uses a custom module which has code that calls
an external perl script via fork. This script takes a considerable amount of
time to run and I need it to just run in the background. I've gotten it to
work but I'm noticing that I've got zombies once the processes complete
until I restart Apache.

Here's the code:

   my $pid;

   unless ($pid = fork) {
      local($SIG{HUP}) = 'IGNORE';
      local($SIG{USR1}) = 'IGNORE';
      local($SIG{USR2}) = 'IGNORE';
      exec $command;
      die "no exec";
      exit 0;
   }

Am I missing a signal or something to run this command as an entirely
stand-alone process?

Thanks,
Cameron


---------------------------------------------------------------------
To unsubscribe, e-mail: embperl-unsubscribe@perl.apache.org
For additional commands, e-mail: embperl-help@perl.apache.org


Mime
View raw message