在强制模式下运行SELinux (AEN 4.2.1)#
要在强制模式下运行SELinux,必须使用semanage port
命令设置一些端口。
semange
命令依赖于 policycoreutils-python
。如果需要安装 policycoreutils-python
,请运行:
sudo yum -y install policycoreutils-python
为Elasticsearch启用端口9200和9300:
sudo semanage port -a -t http_port_t -p tcp 9200
sudo semanage port -a -t http_port_t -p tcp 9300