Opcache – The mystery of PHP7 and 1% hit ratio

Well I have been trying to make this site even faster with all kinds of tweaks like OPcache and optimizations until I pull my hair out and my eyes melt…

opcache dashboard screenshot
Opcache Dashboard Screenshot

This post is about Opcache with PHP 7… arrrrg

So I have Centos 6.8 and WHM 60 with Apache 2.4.and php 7… But little did I know that by using suphp as a handler that I am unable to use any caching like acpu! I am using php-fpm and a WordPress cache plug in Cache Enabler but ya it’s been a mystery and couldn’t figure out until I googled “suphp acpu opcache”. So I still get very fast website but maybe I should have looked into the caching part before I went and tried to do configuration and pull my hair out lol.

 

 

UPDATE:

 

opcache_php71
Updated screenshot of Opcache

 

Well I updated to PHP 7.1 and the cache is now working!! Yay! One thing I did was use the MPM_prefork instead of MPM_event, so maybe that has something to do with it as well…

3 comments on “Opcache – The mystery of PHP7 and 1% hit ratio

  1. Not sure of why the difference. Neither agrees with my web server which has an even higher count. It could be that one or the other is ignoring certain traffic or maybe their servers are down sometimes and missing trefifc.Chears,-Walter

Leave a Reply

Your email address will not be published. Required fields are marked *