0

EDIT: i've reinstalled with Ubuntu server and it's not working as it should. Was never comfortable with Gentoo anyway ;)

I'm a Gentoo noob so please be gentle :)

I'm trying to install APC on a Gentoo (2006) based LAMP stack provided on a VPS by my host. I've run

emerge -av php5-dev/pecl-apc

to install it, and it appears to be compiled etc properly. EDIT: Here's the last several lines of the emerge: http://pastebin.com/MMjtjhrz

I've added these lines to /usr/local/lib64/php5/php.ini:

[apc] apc.enabled = 1 apc.shm_size = 32 

and restarted Apache (which restarts fine, suggesting okay config), but APC doesn't run. Can't see it in phpinfo() or using php -m.

EDIT: not sure if it matters, but the .so files are located in /usr/local/php5/lib/php/extensions/no-debug-non-zts-20060613/, which seems a bit bizarre. Suhosin is in there too, but it's not running either.

Can anyone help? Much appreciated! :)

11
  • Are you sure that you edited the correct php.ini file - sometimes there can be several of them. Try php -i | grep php.ini to see which one is active. Commented Oct 15, 2011 at 10:41
  • Thanks for the response. It's the right one, that command gives /usr/local/lib64/php5/php.ini Commented Oct 15, 2011 at 10:44
  • Edit your post and append some last lines when emerging apc? Did you see apc.so in the extension directory? Commented Oct 15, 2011 at 10:54
  • 1
    How did you compile Apache and PHP? The normal path is /etc/php/apache2-php5.x/php.ini. Commented Oct 15, 2011 at 10:57
  • I didn't - it came preinstalled on the VPS. It's a Gentoo installation customised by the ISP - although to what extent it's different from a standard install I don't know. Commented Oct 15, 2011 at 10:59

1 Answer 1

1

Adding

extension=apc.so

to php.ini did the trick!

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.