[转] Apache Mod_proxy '[Error] (13)Permission Denied' Error on RHEL

原文地址: http://sysadminsjourney.com/content/2010/02/01/apache-modproxy-error-13permission-denied-error-rhel/
现象:
Apache 错误 Log 如下:

1
2
[Wed Feb 08 05:53:54.633904 2017] [proxy_http:error] [pid 29252] [client 172.30.1.26:21397] AH01114: HTTP: failed to make connection to backend: localhost
[Wed Feb 08 05:54:22.880990 2017] [proxy:error] [pid 29249] (13)Permission denied: AH00957: HTTP: attempt to connect to 127.0.0.1:8080 (localhost) failed

解决办法:

1
/usr/sbin/setsebool httpd_can_network_connect 1

若经过上述修改不报错了,再执行下面的命令,使其永久生效:

1
/usr/sbin/setsebool -P httpd_can_network_connect 1

坚持原创及高品质技术分享,您的支持将鼓励我继续创作!