0
votes

I am trying to configure apache 2.2.15 with php5 in my linux system. I have installed both of them. But when I added libphp5.so module in httpd.conf of apache, it has given the following error while starting the server:

Starting httpd: httpd: Syntax error on line 202 of /etc/httpd/conf/httpd.conf: Cannot load /etc/httpd/modules/libphp5.so into server: /etc/httpd/modules/libphp5.so: undefined symbol: ap_unixd_config

Can anybody tell me how to fix this, as I tried every possible solution by googling it but in vain?

3
which linux distribution are you using? - hek2mgl

3 Answers

1
votes

Some newer PHP versions may not be compatible with Apache2.2. This error occurs because the function ap_unixd_config is in Apache2.2 still called unixd_config.

Try to use Apache2.4 if you need to use this PHP version, otherwise you can use an older version of PHP.

1
votes

This also happens on Arch Linux when one doesn't upgrade Apache 2.2 to Apache 2.4. So if you are using Arch Linux you need to downgrade php-apache package to the version that works for you. php-apache-5.5.8-1 is still OK, whereas 5.5.11-1 is not.

0
votes

On RedHat Apache2 and PHP installation is done by issuing the following commands (as root):

yum install httpd httpd-devel php php-mysql php-common php-gd php-mbstring php-mcrypt php-devel php-xml
/etc/init.d/httpd start

That's all. (I'm following this tutorial.) You may add or remove some php extensions to or from the list of packages to be installed if so desired.