防火墙启动报错 Failed to start firewalld.service: Unit is

发布时间:2024-05-09浏览量:0

一、故障现象

1、启动防火墙


# systemctl start firewalld

Failed to start firewalld.service: Unit is masked.

(启动防火墙失败:防火墙被锁定)


二、解决方法

1、防火墙解锁


# systemctl unmask firewalld

输出如下结果:

Removed symlink /etc/systemd/system/firewalld.service.

(移除符号链接)



2、再次启动firewalld:

# systemctl start firewalld


3、查看firewalld状态:

# systemctl status firewalld

输出如下结果:

● firewalld.service - firewalld - dynamic firewall daemon

   Loaded: loaded (/usr/lib/systemd/system/firewalld.service; disabled; vendor preset: enabled)

   Active: active (running) since 四 2019-06-06 14:59:42 CST; 6s ago

     Docs: man:firewalld(1)

Main PID: 31046 (firewalld)

    Tasks: 2

   Memory: 25.9M

   CGroup: /system.slice/firewalld.service

           └─31046 /usr/bin/python -Es /usr/sbin/firewalld --nofork --nopid


6月 06 14:59:41 node-3 systemd[1]: Starting firewalld - dynamic firewall daemon...

6月 06 14:59:42 node-3 systemd[1]: Started firewalld - dynamic firewall daemon.


4Active: active (running)  表示防火墙已经启动。