I call red.php through apache http request, and red.php make exec('./s.php')
call, then I got bunch of s.php processes, and system locked me out any task
due to no more processes available. Why this would happen?
marvin:~/liang.ns2user.info/php> less red.php
<?php
ignore_user_abort(true);
header("Location: redirect2.html");
exec('./s.php');
?>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
marvin:~/liang.ns2user.info/php> less s.php
#!/usr/local/bin/php -q
<?php
echo "This is a PHP-CLI Script!!";
for($i=0;$i<10;$i++) { echo $i; sleep(1); }
$fp = fopen("/tmp/foo.txt","a");
fputs($fp,$i);
fclose($fp);
?>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
marvin:~> ps -u liang
PID TTY TIME CMD
20368 ? 00:00:00 s.php
3184 ? 00:00:00 s.php
27596 ? 00:00:00 s.php
17509 ? 00:00:00 s.php
10471 ? 00:00:00 s.php
20244 ? 00:00:00 s.php
31762 ? 00:00:00 s.php
12067 ? 00:00:00 s.php
14125 ? 00:00:00 s.php
13003 ? 00:00:00 s.php
25257 ? 00:00:00 s.php
22482 ? 00:00:00 s.php
3117 ? 00:00:00 s.php
27203 ? 00:00:00 s.php
28537 ? 00:00:00 s.php
30534 ? 00:00:00 s.php
873 ? 00:00:00 s.php
8452 ? 00:00:00 s.php
306 ? 00:00:00 s.php
15703 ? 00:00:00 s.php
24708 ? 00:00:00 s.php
5745 ? 00:00:00 s.php
11949 ? 00:00:00 s.php
34 ? 00:00:00 s.php
22545 ? 00:00:00 s.php
11775 ? 00:00:00 s.php
12333 ? 00:00:00 s.php
27383 ? 00:00:00 s.php
612 ? 00:00:00 s.php
6437 ? 00:00:00 s.php
14648 ? 00:00:00 s.php <defunct>
14040 pts/1 00:00:00 tcsh
14027 pts/1 00:00:00 ps
I am really confused, anybody has any idea?
Thank you very much.
Liang
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php