天天看點

centos7設定sshd端口,firewall,selinux設定

https://blog.csdn.net/qq_31927797/article/details/81095829

#停止firewall

systemctl stop firewalld.service

#禁止firewall開機啟動

systemctl disable firewalld.service

#檢視防火牆狀态

firewall-cmd --state

#臨時關閉selunx

setenforce 0

#關閉selinux

sed -i 's/SELINUX=enforcing/SELINUX=disabled/g';

# 安裝iptables

yum install iptables-services