From: jbreiding at Hotmail dot com Operating system: windows server 2008 x64 PHP version: 5.3.0 PHP Bug Type: IIS related Bug description: unable to fork using passthru, exec, system when executing page through iis
Description: ------------ i am no longer running this configuration as i found that moving back to 5.2.11 solved this problem. php 5.3.2 (x86 fastcgi) windows server 2k8 (x64) I have spent a good few days googling around and trying things so let me give you the current state. cmd.exe copied to php folder, all instances of cmd.exe, including syswow64, given read execute permissions to domain users, local users, iis_iusrs, network service in addition to the defaults from my users command prompt i can execute php c:\inetpub\wwwroot\forktest.php, as well the same with php-cgi -f c:\inetpub\wwwroot\forktest.php system() is giving a return_val of -1 in procmon.exe i can actually see the create call succeed. the application being executed has also been given the same permissions as cmd.exe, however it is not in the php folder but the full path has been given. my application pool, default setup, runs under network service. here is a snippet that is failing from forktest.php <?php $result = 0; $resultstr = system('echo %PATH%', $result); echo "return value is $result \n"; echo "output string is $resultstr \n"; ?> output: Warning: system() [function.system]: Unable to fork [echo %PATH%] in C:\inetpub\wwwroot\forktest.php on line 25 return value is -1 output string is i went ahead and deleted the cmd.exe in my php folder and in procmon i am seeing exactly what should be happening, c:\windows\syswow64\cmd.exe. it seems my problem is actually executing cmd.exe, not the application i am attempting to execute. Reproduce code: --------------- <?php $result = 0; $resultstr = system('echo %PATH%', $result); echo "return value is $result \n"; echo "output string is $resultstr \n"; ?> -- Edit bug report at http://bugs.php.net/?id=49716&edit=1 -- Try a snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=49716&r=trysnapshot52 Try a snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=49716&r=trysnapshot53 Try a snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=49716&r=trysnapshot60 Fixed in SVN: http://bugs.php.net/fix.php?id=49716&r=fixed Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=49716&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=49716&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=49716&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=49716&r=needscript Try newer version: http://bugs.php.net/fix.php?id=49716&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=49716&r=support Expected behavior: http://bugs.php.net/fix.php?id=49716&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=49716&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=49716&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=49716&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=49716&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=49716&r=dst IIS Stability: http://bugs.php.net/fix.php?id=49716&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=49716&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=49716&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=49716&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=49716&r=mysqlcfg