apc

Weird 500 Internal Server Error (firebug, php, display_errors, ajax)

Guys, on one page I am doing multiple AJAX calls. All calls return responses successfully but the last one (not related to other ajax calls) returns 500 internal server error as response code (as firebug tells). However, in spite of error code, correct content is returned from that AJAX call. To my amazement, when I set display_errors ...

APC Enabled but Apache Still Opening Files?

Hey guys, I'm working on a high-traffic webserver farm serving dynamic PHP code which includes around 100 files on most requests. APC opcode cache is enabled, include_once_override is enabled, and I have allocated 64MB ram to the cache, yet when I strace an apache process I still see it open()ing and stat()ing all of these includes for ...

PHP APC in CLI mode

Hi, Does APC module in PHP when running in CLI mode support code optimization? For example, when I run a file with php -f <file> will the file be optimized with APC before executing or not? Presuming APC is set to load in config file. Also, will the scripts included with require_once be also optimized? I know optimization works fine wh...

Why does mysqli_close fail after calling apc_fetch on a stored ArrayObject?

The following code; //... connect to mysqli database $xyz = array(); $xyz[] = new Object(); $xyz[] = new Object(); apc_store("xyz", new ArrayObject(xyz), 600); $xyz = apc_fetch("xyz"); mysqli_close($link); causes mysqli_close to throw; Error Type: mysqli_close() [function.mysqli-close]: Couldn't fetch mysqli (WARNING) I need to sto...

Opcode (APC/XCache), Zend, Doctrine, and Autoloaders

I am trying to use either APC or XCache as an opcode to cache my php pages. I am using it with Zend and Doctrine and it's having a problem with the autoloader. If I try with APC, I get the following: Fatal error: spl_autoload() [<a href='function.spl-autoload'>function.spl-autoload</a>]: Class Doctrine_Event could not be loaded in ...

How to make APC (PHP Cache) work?

I've read about APC that it speeds up multiple php file sites. So I have this particular project in PHP with many files and i discover that require_once and parsing only class definitions (without executing them) takes most time. So I've installed APC on my CentOS 5 server. I moved apc.php to my webserver and it displays Hits: 1 (50....

Zend Cache Core and APC - I don't understand how old cache entries get invalidated

For Zend_Cache_Frontend_Core you can define a lifetime and, according to the documentation, a "automatic_cleaning_factor". According to the manual, this property specifies on how many writes to the cache old cache entries get invalid. When I use APC as backend shouldn't the cache invalidate itself automatically without having to write ...

PHP: Using APC as general cache, XCache as opcache, possible?

I'm really intreagued by the general cache aspects of APC and want to use it in my code (this I know how to do, this is not the problem). However, I'm using XCache as opcache now and want to continue to do so since I have it tweaked "just right" for my particular needs. The reason I want to use APC cache as general cache is that I'm no...

Which one would you choose ; XCache or APC ?

I need a opcode-cache in my project. Also i will use for the datastore (mysql returned row) cache ? Which is the best for you and WHY ? ...

APC Hits/Misses and configuration

What are "Hits & Misses" in reference to APC opcode caching? I've installed APC and it's running great, but I've got "some" misses and I'm wondering if that's "bad". Also, I am running Openx and, as such, am filling up the "Cache full count(s)" pretty quickly. What do I need to change in the configuration to minimize that? Any recommende...

apc.filters by path?

How would I use the apc.filters parameter in APC opcode caching to not cache certain paths? For example, I want caching to be active for anything under the path: "/var/www/vhosts" and exclude paths like "/usr/share/psa-horde/" I tried using apc.cache_by_default = 0 apc.filters = "+/var/www/vhosts" and apc.cache_by_default = 1 apc...

Zend Framework optimization, tcpsndbuf & kmemsize

Hi friends. We're on the mid-tier DV Rage server on media temple using Zend Framework, and we've been getting QoS warnings in Virtuzzo pretty consistantly. We've spent the last week installing APC (tweaking that to death), mysql and apache tweaks (many recommended by Media Temple), front end gzip, Zend_View caching, and every optimizatio...

Why would apc_store() return false?

The documentation on php.net is very spotty about causes of failure for APC writes. What kind of scenarios would cause a call to apc_store() to fail? There's plenty of disk space available, and the failures are spotty. Sometimes the store operation will succeed and sometimes it'll fail. ...

How to change the locking mechanism in Alternative PHP Cache (APC)?

I recently read in a presentation on Scribd that Facebook had benchmarked a variety of locking mechanisms for APC including file locks (default), IPC semaphore locks, linux Futex locks, pthread mutex locks, and spin locks. You can view this presentation by clicking the following link: APC@Facebook I was wondering if anybody knew off ha...

Optimize PHP, MYSQL community website performance

Hi, I own a community website of about 12.000 users (write heavy), 100 concurrent users max on a single VPS with 1Gb ram. The load rarely goes above 3 and response is quite good. Currently a simple file cache is used to store DB query results to ease the load on the DB, but the website still can slow down over 220 concurrent users (loa...

[Dojo / PHP + apc.rfc1867] I can't get xhrPost upon form submission via input button, I'm going insane...

It's rather lengthy, TLDR version below crit wall of text. Setup: Our company had been using prototype for some time, and just recently switched to dojo. I have been converting lots and lots of JS and setting everything back up to normal and then I encountered this issue... The issue: I have a typical form set up with a upload file fi...

PHP APC multiple upload does not work

Hi! I tried to use PHP APC to upload files on wamp, windows2003. But when 2 or more uploads are working at the same time, only one upload is working. It seams that I'm not the only one experiencing this error: http://pecl.php.net/bugs/bug.php?id=13719 Can anyone tell how can I fix this problem? Thanks in advance! ...

Can the APC cache be shared among multiple PHP processes running as fastcgi/fcgid?

I'm running a LAMP box with PHP running as fcgid. APC is installed and working well. However, each PHP process gets its own cache. This is a problem, because it would make far more sense to have 10 PHP processes with 300MB shared APC cache than 10 PHP processes, each with a redundant 30MB unshared APC cache. There was a prior thread on ...

Using APC in PHP Version 6.0.0-dev

PHP 6 has APC included in the core distribution, but its off by default. I have compiled from source and tried '--enable-apc' but no luck. I also tried to download and compile the APC module but it fails. How do I turn APC on in PHP 6? ...

Where is APC dll for PHP Version 5.2.11 (on Windows)?

Trying to locate the correct APC DLL for my windows machine. All I have tried so far, causes Apache to crash. Short of compiling from the sources (which I dont really want to do), I seem to have come to a dead end. Details are: OS: XP PHP: php-5.2.11-win32-vc6 ...