The Linux Page

Just installed a PECL extension and Apache still doesn't understand it?!

Last night as I was compiling a new PECL extension for an install, after a while it worked... I could run php -v and it would give me the version of the PHP modules without telling me that the it couldn't load the extension (i.e. we already had the extension=http; in the php.ini file.)

But when testing with php -v on the command line, it would reload the php.ini and apply the extension feature and such.

However, when testing with Apache, it was still not working. The PECL installation was all correct, so why would it not see the resulting extensions?!

Because you need to restart Apache. Simple, but if you forget, that's just not going to work.

service apache2 restart (Debian, Ubuntu, etc.)

service httpd restart (RedHat, Fedora, Centos, etc.)