centos7.6 常用命令(防火墙关停、selinux关停)

查看防火墙状态

firewall-cmd --state
systemctl status firewalld
停止firewall
systemctl stop firewalld.service
禁止firewall开机启动
systemctl disable firewalld.service

 

关掉selinux
sed -i 's/SELINUX=enforcing/SELINUX=disabled/' /etc/selinux/config

永久修改主机名
hostnamectl set-hostname ***

查看开机自启动的服务

systemctl list-unit-files|grep enabled 

posted @ 2020-04-07 17:53  邓旭阳  阅读(319)  评论(0)    收藏  举报