# 查看防火墙状态 systemctl status firewalld
# 开启防火墙 systemctl start firewalld
# 关闭防火墙 systemctl stop firewalld
# 重启防火墙 systemctl restart firewalld
# 开启6379端口 firewall-cmd --zone=public --add-port=6379/tcp --permanent
# 关闭端口 firewall-cmd --zone=public --remove-port=6379/tcp --permanent
# 重启防火墙 firewall-cmd --reload
# 查看防火墙已开启端口 firewall-cmd --zone=public --list-ports