Installing mod fcgid on CentOS Linux

From ISPWiki

Jump to: navigation, search

Installing mod_fcgid on CentOS Linux to enable PHP as FastCGI

(Last edited 12.25.2009; CentOS 5.4 32bit)

mod_fcgid is not available in the official CentOS 5.4. repositories.

Install a httpd-devel package for compilation.

Execute the command:

# yum install httpd-devel

Once the installation is complete, download mod_fcgid from the official site

# wget

Untar it, open the directory with source texts to install the module:

# tar xzf mod_fcgid-2.3.4.tar.gz
# cd mod_fcgid-2.3.4
# ./configure.apxs
# make
# make install

The module will be automatically installed and specified in the Apache configuration file.

Change access privileges to the directory with log-files for the web-server to be able to read the socket file fcgid:

# chmod 705 /var/log/httpd

We would recommend that you add the line into /etc/php.ini cgi.fix_pathinfo = 1 run:

# echo 'cgi.fix_pathinfo = 1' >> /etc/php.ini

Restart Apache and ISPmanager:

# /etc/init.d/httpd restart
# killall ispmgr

In the user properties form you will see the PHP as FastCGI check box. Select it to add the PHP as FastCGI mode to the WWW domain properties form. Make sure everything is up and running.

Was this helpful? Yes | No
Personal tools