[solved] XAMPP 7.0.8 opcache can't be enabled

Problems with the Windows version of XAMPP, questions, comments, and anything related.

[solved] XAMPP 7.0.8 opcache can't be enabled

Postby ollo » 18. August 2016 23:09

Hi there,

I recently switched to the above mentioned version of XAMPP and wanted to play around with opcache. Then i noticed it's not enbled although it should be an internal extension and enabled by default in PHP7 as far as I know. The opcache_get_status() is an undfined function, ini_get('opcache.enable') gives FALSE and there also isn't any section on opcache in phpinfo() which I would expect.

I tried to force-enable it via php.ini, no luck. I then noticed there is a php_opcache.dll which I tried to load via php.ini, no luck. I also don't see any opcache-related entries in the apache error log.

Is there a known problem with this XAMPP/PHP version and opcache that prevents it from starting? Was there an error in the building process so it isn't linked or sth? I'm out of my wits and the internet sources only give irrelevant stuff, so any help would be appreciated.


EDIT/SOLUTION:

...just after posting I found a user comment in the PHP documentation I overlooked somhow, the solution is to add the following line to the php.ini which was missing from the distributed php.ini:
zend_extension=php_opcache.dll

I only tried extension=php_opcache.dll before, so that's why it didn't work before - I would suggest that this is checked and fixed in future versions of XAMPP if the original distribution has this line missing.
ollo
 
Posts: 85
Joined: 11. November 2004 12:29

Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 130 guests