安装
rpm -ivh nginxxxx
解决Nginx的connect() to 127.0.0.1:8080 failed (13: Permission denied) while connect
配置nginx:
防火墙设置:selinux
安装组件:
#查询状态sestatus#开启selinuxsetenforce 1#关闭selinuxsetenforce 0
vim /etc/selinux/config
# vim /etc/selinux/config# This file controls the state of SELinux on the system.# SELINUX= can take one of these three values:# enforcing - SELinux security policy is enforced.# permissive - SELinux prints warnings instead of enforcing.# disabled - No SELinux policy is loaded.SELINUX=enforcing#SELINUX=disabled# SELINUXTYPE= can take one of three two values:# targeted - Targeted processes are protected,# minimum - Modification of targeted policy. Only selected processes are protected.# mls - Multi Level Security protection.SELINUXTYPE=targeted
允许nginx 白名单:
yum install policycoreutils-pythoncat /var/log/audit/audit.log | grep nginx | grep denied | audit2allow -M mynginxsemodule -i mynginx.pp
