apache添加suexec.so模块

进入apache源代码的modules/generators目录


/usr/local/apache2/bin/apxs -c mod_suexec.c
/usr/local/apache2/bin/apxs -i -a -n suexec ./.libs/mod_suexec.so
cd ../../
./configure --prefix=/usr/local/apache2 --enable-so --enable-rewrite \
--enable-vhost-alias  --enable-mods-shared=most \
--enable-suexec --with-suexec-bin=/usr/local/apache2/bin/suexec \
--with-suexec-caller=ftp --with-suexec-docroot=/var/www \
--with-suexec-logfile=/usr/local/apache2/logs/suexec_log
make suexec
make install-suexec

 

如果出现configure: error: Cannot use an external APR with the bundled APR-utilq错误解决
解决http://hi.baidu.com/sanve/blog/item/ab33be192bfe2f4443a9adc7.html

如果出现从源码安装apache2,遇到错误:cannot install `libaprutil-1.la'
解决http://hi.baidu.com/wa0362/blog/item/9dd128992447da0c6f068c25.html

 
如果安装好就启用它
<VirtualHost *:80>
ServerName mail.example.com
DocumentRoot /var/www/extsuite/extman/html
ScriptAlias /extman/cgi /var/www/extsuite/extman/cgi
Alias /extman /var/www/extsuite/extman/html
SuexecUserGroup vuser vgroup
</VirtualHost>
 
如果突然出现空白页,查看日志是不是产生perl CGI错误"Premature end of script headers"的可能原因

可能是权限问题。把WEB目录改下所属组吧。

你可能感兴趣的:(apache)