Questions tagged [opcache]

OPcache is a PHP opcode cache introduced in PHP 5.5 (and is also available as a PECL extension for PHP 5.2+). It is based on the Zend Optimizer+

The Zend OPcache provides faster PHP execution through opcode caching and optimization. It improves PHP performance by storing precompiled script bytecode in the shared memory. This eliminates the stages of reading code from the disk and compiling it on future access. In addition, it applies a few bytecode optimization patterns that make code execution faster.

Also see the OpCache Readme, the PHP OPcache documentation and the PECL OPcache page.

304 questions
0
votes
1 answer

Enable opcache from htacces not from .ini file

I set opcache.enable=0 in opcache.ini Now I want to enable opcache from my htaccess file using php_flag opcache.enable On But it is not working Is there any way, I disable opcache in opcache.ini, and enable in my application's htacces file. Thanks
user3483449
  • 11
  • 1
  • 1
  • 6
0
votes
1 answer

Opcache does not get enabled

I've installed Apache 2.4.x webserver on Ubuntu and also PHP5.5.x from sources. I go to php installation folder and do find . -name "opcache.so". Then, to php.ini (same as in phpinfo()), I add…
zavr
  • 2,049
  • 2
  • 18
  • 28
0
votes
1 answer

PHP request_uri vs. __FILE__

Is there any circumstance in which the same $_SERVER['REQUEST_URI'] should open two different PHP files? I'm not using mod_rewrite, just Apache virtual hosts and Alias pointers to the target directories in which my PHP files live, but I'm seeing…
leei
  • 139
  • 5
0
votes
1 answer

installing php5.3 with Opcache

I'm just curious if it is possible to have both php5.3 and OpCache mod. installed on Linux Debian based OS. I spent the almost all day searching over the internet to find out whether it is possible to or not to install php5.3 + OpCache. I don't want…
Digital site
  • 4,431
  • 12
  • 48
  • 72
0
votes
1 answer

Apache Worker and APC user cache

Anybody tried APCu with ZendOPcache in MPM Worker ? I went into problems with MPM Worker-APC but I found the article https://engineyard.zendesk.com/entries/26902267 My target is to achieve Apache MPM Worker with mod_fcgi [ for mod_spdy to work ]…
radus
  • 3
  • 3
0
votes
0 answers

Invalid UTF8 characters after installing Opcache on AWS EB PHP server

I'm using CakePHP 2.4.2 to run a CMS site on Amazon Elastic Beanstalk servers with an RDS database. Starting last night I am seeing errors in my logs, and certain pages not loading (500 error) because of it: error: [PDOException] SQLSTATE[HY000]:…
James Alday
  • 873
  • 9
  • 23
0
votes
2 answers

Failed loading opcache.so: opcache.so: cannot open shared object file

Ive got an issues with Opcache on my apache2 logs file The error is : Failed loading opcache.so: opcache.so: cannot open shared object file Do you have any ideas ? I'm running on Debian squeeze php 5.4 with Opcache Thanks
SoCkEt7
  • 2,237
  • 5
  • 22
  • 30
0
votes
1 answer

What is longterm alternate for APC for PHP 5.5?

I was having a scenario where on every request i had to fetch the data from database. SO i thought of using APC to cache the variable. But later found out that APC was no longer the choice for newer versions of PHP. So i checked out memcahced and…
Dangling Cruze
  • 3,283
  • 3
  • 32
  • 43
0
votes
1 answer

Top Performance PHP + HTTPD + OPCACHE

I'm trying to figure out what would be the most performing configuration to host a PHP website on Amazon EC2. Which webserver? (Apache, Lighttpd, nginx)? Which PHP module? mod_php, FastCgi? Which OpCache? (xcache, APC, eAccelerator, Varnish) What…
0
votes
1 answer

Opcache with Joomla! and Resolved Name

I have been researching the best use of OPcache with Joomla. This github page, The Zend Engine and OPcode caching, is the best explanation of how OPcache works that I've seen and was trying to get answers to a couple of points here. Resolved…
0
votes
0 answers

nginx with php-fpm or standard LAMP in heavy load sites

I'm currently using Nginx with php-fpm 5.4 (Centos 6.4) I want to switch to standard LAMP installation with OpCache for performance improvement. I decided to go with Nginx initially because it's very lightweight and can handle load, but now that all…
Danny Valariola
  • 1,118
  • 5
  • 26
  • 41
-1
votes
1 answer

PHP script is not reacting to code changes, although opcache and jit are both disabled. What might be happening?

I have a php script that is not reacting to code changes that I make (I inserted a deliberate syntax error which is not be being picked up). I am running php 8.1 on apache2 (on a local copy of ubuntu 22.04). The script is part of a drupal 9.4…
user13167
  • 11
  • 1
  • 3
-1
votes
1 answer

phpinfo() shows opcache.blacklist_filename file, but contents ignored

In my Symfony/Sonata application's php.ini file, I have opcache.blacklist_filename set to /usr/src/app/config/opcache-exclude.txt. In a phpinfo() call on my test server, that file shows up in the correct place. Here is the content of the…
-1
votes
1 answer

Is OPcache a plus if HTTP caching is enabled?

I have been reading about general concepts in PHP performance and what could be done to improve it. When developing websites and it's the time to go live I use HTTP caching and maybe a CDN (depends on traffic). Now that made me wonder if OPcache…
Antonios Tsimourtos
  • 1,676
  • 1
  • 14
  • 37
-1
votes
2 answers

Problems install install zend opcache

I have problem for install zendopcache [root@cp ~]# yum install php-pecl-zendopcache Loaded plugins: fastestmirror, security Setting up Install Process Loading mirror speeds from cached hostfile Excluding mirror:…
Jos
  • 29
  • 1
  • 5
1 2 3
20
21