|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #72590 Opcache restart with kill_all_lockers does not work as expected
Submitted: 2016-07-13 02:38 UTC Modified: 2016-07-13 03:13 UTC
From: Assigned: keyur (profile)
Status: Closed Package: opcache
PHP Version: 7.0.8 OS: Linux
Private report: No CVE-ID: None
 [2016-07-13 02:38 UTC]
Suppose one of the Apache child is blocked by a malloc deadlock while holding a read lock on Opcache. After some time Opcache gets full and is scheduled to be restarted. 

Because of the child holding the lock, we eventually end up calling kill_all_lockers.

This line calls zend_accel_error with ACCEL_LOG_ERROR.

ACCEL_LOG_ERROR is special and causes a zend_bailout, so the code never gets to call kill() in line 601. Combined with the reset of force_restart_time in line 597, the child is never terminated and Opcache never restarts.

The fix would be to change the log level to ACCEL_LOG_WARNING


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2016-07-13 02:38 UTC]
-Assigned To: +Assigned To: keyur
 [2016-07-13 03:13 UTC]
-Status: Assigned +Status: Closed
 [2016-07-13 03:13 UTC]
The fix for this bug has been committed.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at

 For Windows:
Thank you for the report, and for helping us make PHP better.

 [2016-09-05 15:06 UTC]
Backported to PHP-5.6 today
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Apr 23 04:01:29 2024 UTC