How to Start/Stop or Enable/Disable firewalld on Fedora 25
firewalld
(Dynamic Firewall Manager) tool provides a dynamically managed firewall. The tool enables network/firewall zones to define the trust level of network connections and/or interfaces. It has support both for IPv4
and IPv6
firewall settings. Also, it supports Ethernet bridges and allow you to separate between runtime and permanent configuration options. Finally, it supports an interface for services or applications to add firewall rules directly.
Disable firewalld
To disable firewalld
, execute the following command as root or using sudo
:
systemctl disable firewalld;
Enable firewalld
To enable firewalld
, execute the following command as root or using sudo
:
systemctl enable firewalld;
Stop firewalld
To stop (or deactivate) firewalld
,execute the following command as root or using sudo
:
systemctl stop firewalld;
Start firewalld
To start (or activate) firewalld
, execute the following command as root or using sudo
:
systemctl start firewalld;
Status of firewalld
To check the status of firewalld
, execute the following command as root or using sudo
:
systemctl status firewalld;
CONCEPTS
systemd provides a dependency system between various entities called “units” of 12 different types. Units encapsulate various objects that are relevant for system boot-up and maintenance. The majority of units are configured in unit configuration files, whose syntax and basic set of options is described in systemd.unit(5), however some are created automatically from other configuration, dynamically from system state or programmatically at runtime. Units may be “active” (meaning started, bound, plugged in, …, depending on the unit type, see below), or “inactive” (meaning stopped, unbound, unplugged, …), as well as in the process of being activated or deactivated, i.e. between the two states (these states are called “activating”, “deactivating”). A special “failed” state is available as well, which is very similar to “inactive” and is entered when the service failed in some way (process returned error code on exit, or crashed, or an operation timed out). If this state is entered, the cause will be logged, for later reference. Note that the various unit types may have a number of additional substates, which are mapped to the five generalized unit states described here.
— From man systemd
The above, in a nutshell:
enabled
is a service that is configured to start when the system bootsdisabled
is a service that is configured to not start when the system bootsactive
is a service that is currently runninginactive
is a service that is currently stopped and may be disabled, but it can be started and become active