It is not possible to use the function
'pcntl_fork' when PHP is used as Apache module. You can only use
pcntl_fork in CGI mode or from command-line.
Using this function will result in: 'Fatal error: Call to undefined function: pcntl_fork()'所以只能想其它方法进行处理了。
Using this function will result in: 'Fatal error: Call to undefined function: pcntl_fork()'
-
foreach
($generateFiles as $generateNumber => $generateMsg) {
-
$generateNumberArr[$generateNumber] = popen("php /var/www/html/DNSnew/include/generateZonfConf.php " . $generateMsg . " " . $serial . " " . $forderDir, 'r');
-
}
-
-
foreach ($generateNumberArr as $generateNumberArr_k =>$generateNumberArr_v) {
-
while (! feof($generateNumberArr_v)) {
-
$buffer = fgets($generateNumberArr_v, 4096);
-
if (strstr($buffer, 'ff0000')) {
-
$forderDir = false;
-
}
-
usleep(100000);
-
}
-
pclose($generateNumberArr_v);
-
}
版权声明:本文为博主原创文章,未经博主允许不得转载。