Re: SHM issues PHP7 x64
[email protected] (Jan Ehrhardt) Thu, 13 Apr 2017 17:44:35 +0200
| Newsgroups | php.internals.win |
|---|---|
| Message-ID | <[email protected]> |
Hi Anatol, Anatol Belski in php.internals.win (Thu, 13 Apr 2017 14:09:09 +0000): >The Opcache error is the issue which is worked around by the exact >suggestion from the error message. In most case it's conditioned by >ASLR and the workaround reduces the failures to almost zero. You might >try to disable ASLR for the PHP build, however it in many cases won't >work as Windows itself will enforce it. OK. >With APCu, I'd like to point you to this issue >https://github.com/krakjoe/apcu/issues/67#issuecomment-164926913. The >issue in APCu is in most case the locking, so not all the processing >modes are supported. Particularly on Windows, you should ensure there's >no inter process cache sharing, as the locking is not suitable for such >model. Thanks for the pointer. In short: running PHP NTS with php_apcu.dll under mod_fcgid is not possible. Silly thing: I am doing exactly that with PHP 5.6.30 NTS x86 under Apache VC11 x86 + mod_fcgid 2.3.9. It started to crash when I changed to Apache VC14 x64 and PHP 7.1 NTS x64. >While the Opcache behavior wrt the issue is sporadic and system >conditioned, the APCu one is clearly about the SAPIs and their >limitations. Anyway, they should not be mixed up, as they're completely >different matters. I see, that your primary interest is about APCu, so >you might check in further whether the crash conditions involve inter >process SHM access, which would require inter process locking that is >currently absent in APCu. Here is the same difference between PHP5 and PHP7. Running 'php-cgi.exe -m' on the command line crashes with PHP7 and runs fine with PHP5. Test conditions are with no other process running at all, so there can't hardly be any inter process locking or inter process communication. Even more intriguing: If we ensure that php-cgi.exe writes to the errorlog, it does not crash. Example: generate an error by adding 'extension=whatever' to php.ini and 'php-cgi -m' does not crash. https://github.com/krakjoe/apcu/issues/223#issuecomment-288263701 This smells like something not being initialized in PHP7, which is initialized in PHP5 and in PHP7 with an erronous php.ini. -- Jan