Saturday, July 2, 2022

[FIXED] How to enable PHP OPcode caching for Drupal 8?

Issue

I want to enable PHP OPcode caching for Drupal 8 installation. I have the following in Xampp php.ini. However, I still get opcode not enabled. What am I doing wrong??

opcache.enable=1

engine = On
zend_extension=php_opcache.dll


opcache.memory_consumption=128
opcache.interned_strings_buffer=8
opcache.max_accelerated_files=4000
opcache.revalidate_freq=60
opcache.fast_shutdown=1
opcache.enable_cli=1

Solution

Hello Universe see if this helps :-

  • Try to use zend_extension=opcache instead of zend_extension=php_opcache.dll as the former has been deprecated in PHP major version. Check your php.ini file for more details.
  • Check if zend.assertions! are enabled.
  • I would recommend to go through Opcache issue solved! , which is working fine for most of the cases.
  • Restart your Apache.


Answered By - SayanTan Das
Answer Checked By - Terry (PHPFixing Volunteer)

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.