Linode Forum Index Linode Forum
Linode Community Forums
 


APC cache size settings

Click here to go to the original topic

 
       Linode Forum Index -> Performance and Tuning
Author Message
ericholtman



Joined: 05 Sep 2010
Posts: 76

Posted: Sun Jan 22, 2012 1:21 pm    Post subject: APC cache size settings  

I'm experimenting with APC on a scratch linode, and I'm having trouble changing the cache size.

I wanted to try 15M instead of 30. I added a line 'apc.shm_size=15M' to my apc.ini.

I restarted nginx (pretty sure I didn't need to do that), and restarted php-cgi.

If I run php_info.php or apc.php, they show that it picked up my new size. That is, I can see the 15M entry in the settings. But the cache size is still 30M: apc.php shows that, as do the munin plugins.

Since it's a scratch linode, I also tried rebooting it, just to see if there was some "ordering of service restarts" problem. The problem remains.

Am I doing something wrong, or is there a hard minimum (30) for that value?
Back to top  
ericholtman



Joined: 05 Sep 2010
Posts: 76

Posted: Sun Jan 22, 2012 1:26 pm    Post subject:  

God damnit.

Twice in one weekend I fiddle for a couple of hours, google to no avail, then immediately after asking for help, find the answer.

I needed to drop the 'M' from the config.

Code: apc.shm_size=15

works.

Sigh. Carry on!
Back to top  
glg



Joined: 09 Jan 2009
Posts: 505

Posted: Sun Jan 22, 2012 1:40 pm    Post subject:  

ericholtman wrote: God damnit.

Twice in one weekend I fiddle for a couple of hours, google to no avail, then immediately after asking for help, find the answer.

I needed to drop the 'M' from the config.

Code: apc.shm_size=15

works.

Sigh. Carry on!

You probably have my.cnf on the brain ;)
Back to top  
ericholtman



Joined: 05 Sep 2010
Posts: 76

Posted: Sun Jan 22, 2012 1:43 pm    Post subject:  

glg wrote:
You probably have my.cnf on the brain ;)

As a matter of fact, mysql is next on my list of things to "tune" on this linode.

So stay tuned for another question that I'll self-answer immediately after posting.
Back to top  
sleddog



Joined: 31 Aug 2008
Posts: 101

Posted: Sun Jan 22, 2012 6:31 pm    Post subject:  

ericholtman wrote: God damnit.

Twice in one weekend I fiddle for a couple of hours, google to no avail, then immediately after asking for help, find the answer.

I needed to drop the 'M' from the config.

Code: apc.shm_size=15

works.

Sigh. Carry on!

This depends on the version of APC. I have 3.1.9 on one Linode and without the 'M' it throws a warning about the missing M. On my other boxes, APC 3.1.3 behaves as you describe.

So you may want to hold on to that M for after you upgrade :)
Back to top  
 
       Linode Forum Index -> Performance and Tuning
Page 1 of 1