Is there really a need to use forking? Instead, how about: 1. CGI prints instant reply. 2. CGI execs long job (you *are* using exec and not system, right?), and exits. 3. long job sends mail (exec or system or a subroutine) when it's done. You'd need to pass $loginid to the long job of course. hugh Rajat Sharma wrote: > > Script looks something like below > > 1. print ("Location: http://XYZ:9090/Project/filepath.html\n\n"); > 2. close(STDOUT); > 3. my $pid = fork; > > 4. $pid = 0 unless defined $pid; # be the kid if fork failed > > 5. exit 0 if $pid; > > ## child... > > 6. close(STDOUT); > > ### LONG DIRTY JOB START > 7. exec "la_results.pl $input{'dirPath'} $checkboxString"; > ### LONG DIRTY JOB OVER > > 8. mail.pl $loginId ## MAIL THE NOTIFICATION > > Issue is that the after submit of the page, the IE still keeps loading > the page until the long\dirty job is over. -- Hugh Williams "There are two things to aim for in life; hugh_williams@xxxxxxxxxxx first, to get what you want; and after that, Agilent Technologies to enjoy it. Only the wisest of mankind Santa Rosa 2US-C achieve the second." 707.577.4941 - Logan Pearsall Smith, 1931 --------------------------------------------------------------------- The official User-To-User support forum of the Apache HTTP Server Project. See <URL:http://httpd.apache.org/userslist.html> for more info. To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx " from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx