启动apache 出现如下错误:
httpd: syntax error on line 107 of /usr/local/apache/conf/httpd.conf: cannot load /usr/local/apache/modules/libphp5.so into server: /usr/local/apache/modules/libphp5.so: cannot restore segment prot after reloc: permission denied
解决办法:
1关闭selinux的方法:
vi /etc/selinux/config 将selinux=enforcing 改成selinux=disabled 需要重启
这个方法可能会对服务器带来风险。
2不关闭selinux的方法:# setenforce 0# chcon -c -v -r -u system_u -r object_r -t textrel_shlib_t /usr/local/apache/modules/libphp5.so# service httpd restart
# setenforce 1
阅读(2357) | 评论(0) | 转发(0) |