Bug #75579 [Ana->Csd]: All Interned Strings Free memory used and PHP crashes
From: dmitry@php.net Date: Thu, 21 Dec 2017 20:49:33 +0000 Subject: Bug #75579 [Ana->Csd]: All Interned Strings Free memory used and PHP crashes References: 1 Groups: php.bugs Request: Send a blank email to php-bugs+get-213227@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=75579&edit=1
ID: 75579
Updated by: dmitry@php.net
Reported by: post at minhost dot no
Summary: All Interned Strings Free memory used and PHP
crashes
-Status: Analyzed
+Status: Closed
Type: Bug
Package: opcache
Operating System: CentOS 7.4
PHP Version: 7.1.12
Assigned To: dmitry
Block user comment: N
Private report: N
New Comment:
Automatic comment on behalf of dmitry@zend.com
Revision: http://git.php.net/?p=php-src.git;a=commit;h=37bf8bdc1494abb2ce5cac40e0be80e23682f851
Log: Fixed bug #75579 (Interned strings buffer overflow may cause crash)
Previous Comments:
------------------------------------------------------------------------
[2017-12-21 20:38:10] nikic@php.net
@dmitry: With your latest patch, if the interned string buffer is full, but SHM is not full,
won't we end up repeatedly allocating SHM memory that's not going to be used?
------------------------------------------------------------------------
[2017-12-21 17:10:48] post at minhost dot no
@dmitry: I have now tested your newest patch against PHP 7.1.13RC1, and I did not find any problems.
PHP does not crash. The behaviour seemed to be the same as with your previous patch. Anyway, it
seems to work fine! Can you please apply your newest patch to the 7.x branch? I expect it will be
applied to all of PHP 7.0.x, 7.1.x and 7.2.x? Hopefully it will be in time for the release of PHP
7.0.27 and 7.1.13? Thanks!
------------------------------------------------------------------------
[2017-12-21 12:05:14] post at minhost dot no
Ok, thanks for explainging it to me, @dmitry. Sorry I misunderstood the change. I will test your
newest patch later tonight, and let you know if it works correct for me.
------------------------------------------------------------------------
[2017-12-21 12:01:34] dmitry@php.net
This is not a new feature. file cache worked in this way, if it wasn't able to allocate enough
shared memory for the script at once, but it didn't allocate additional blocks for
"overflowing" interned strings before (this was the bug).
With the first patch, if there is no enough memory for "overflowing" interned string, we
fall-back to recompilation from source. With the second patch we still load precompiled version from
file, but not to shared but regular memory.
------------------------------------------------------------------------
[2017-12-21 12:00:41] post at minhost dot no
And the answer is: When SHM is full, don't do anything new regarding file cache on disk, but
keep it the way it was working in PHP 7.1.11
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
https://bugs.php.net/bug.php?id=75579
--
Edit this bug report at https://bugs.php.net/bug.php?id=75579&edit=1
Thread (52 messages)
- Bug #75579 [Opn]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Opn]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Opn]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Opn]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Opn]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Opn]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Opn]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Opn]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Opn]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Opn]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Opn]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Opn->Ana]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Ana]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Ana]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Ana]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Ana]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Ana]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Ana]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Ana]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Ana]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Ana->Csd]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Csd]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Csd]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Csd]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Csd]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Csd]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Csd]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Csd]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
- Bug #75579 [Com]: All Interned Strings Free memory used and PHP crashes
| « previous | php.bugs (#213227) | next » |
|---|