Enabling PHP7 Opcache

我的梦境 提交于 2019-12-06 05:35:35

问题


I recently upgraded to PHP 7.

I placed this in /etc/php.d/opcache.ini

opcache.file_cache = /var/www/html/.opcache
opcache.file_cache_only = 1

and created the directory (as root)

When I visit the site there is nothing created in the .opcache folder

a phpinfo(); reflects the changes I made in opcache.ini

How can I get PHP 7 Opcache working at optimal performance with WordPress?

update The problem was witch folder permissions. 'Ale sure the Apache can write to it.

What are the optimal settings for it? Security and speed wise?


回答1:


I fixed this by making sure apache get write to the folders I created. Once that was done restarting httpd made it work.



来源:https://stackoverflow.com/questions/39211800/enabling-php7-opcache

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!