心理

当前位置 /首页/完美生活/心理/列表

6搭建web服务端口更改,centos7

centos7.6搭建web服务端口更改

在selinux中添加端口

安装semanage

yum install semanage

它提示没有可用软件包

执行yum provides semanage

查看软件包名字

yum -y install 7.x86_64

/usr/sbin/sestatus -v //查看SELinux状态

semanage port -l | grep ssh //查询当前 ssh 服务端口

semanage port -a -t ssh_port_t -p tcp 1234 //向 SELinux 中添加 ssh 端口

systemctl restart ice //重启ssh服务