Global Hosting Talk

APC problems

by Feeder on Nov.09, 2009, under Web Hosting Talk

Hey,

We have installed APC 3.1.3p1 beta (and also 3.0.19 stable seperately, to test) and we are seeing a lot of "out of memory" and "timeout" errors. For example, a php scripts dies saying the available memory is 256Kbytes, and the script tries to allocate 256 Mbytes of memory.

Here are the APC settings:

[APC]
apc.enabled = 1
apc.shm_segments = 1
apc.shm_size = 128
apc.max_file_size = 8M
apc.stat = 1

and PHP settings related to memory is

memory_limit = 1024M

We have tried included apc.php file to watch out the cache, but it doesn’t show any kind of fragmantation or etc. related with system, instead it shows "timeout" and "out of memory" errors with php scripts.

We have thought that the error can be related to /dev/shm as you should increase apc.shm_size in order to obtain more memory, therefore we have mounted /dev/shm as 4Gbytes. The server has 8Gbytes of memory (using 64-bit CentOS).

Note that once we set apc.enabled = 0, the problems go away, so it’s definitely something with APC.

Any ideas?


Comments are closed.

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!

Visit our friends!

A few highly recommended friends...