AFAIK grep -m 1 exiting causes the OS to send a SIGPIPE to tac upon grep exit... hmm. Could it be that SIGPIPE is masked somewhere in mod_perl, ? is that masking propagated to the child? Is it even possible to mask a signal for a process group? Now that's something I don't know, you got me there :-)
If that's the case - i.e. if SIGPIPE is masked - try my solution (which doesn't involve grep) and kill off tac with another signal (15 or, if it's renitent, 9 - SIGKILL).
--shmem
_($_=" "x(1<<5)."?\n".q·/)Oo. G°\ /
/\_¯/(q /
---------------------------- \__(m.====·.(_("always off the crowd"))."·
");sub _{s./.($e="'Itrs `mnsgdq Gdbj O`qkdq")=~y/"-y/#-z/;$e.e && print}
| [reply] [d/l] [select] |
That was it, changed the signal to 9 and the script now executes in about 10 seconds. Thanks!
Cheers,
Troy
| [reply] |