CentOS7 use systemctl Command to manage a single service of the system , stay CentOS7 In terms of firewalld( firewall ) Service opening , close , The same instruction is used for status queries , The operation is as follows :

Start firewall : systemctl start firewalld

View firewall status : systemctl status firewalld 

Turn off the firewall : systemctl stop firewalld

Enable firewall service at power on :systemctl enable firewalld

Disable firewall service at power on :systemctl disable firewalld

Query whether the firewall service is started :systemctl is-enabled firewalld

Query the list of started services :systemctl list-unit-files|grep enabled

Query the list of services that failed to start :systemctl –failed

When installing software or column Library , In addition to directly opening and closing the firewall , You can also open the connection directly through the port operation ; Add port :firewall-cmd –zone=public –add-port=80/tcp –permanent 

Update firewall rules :firewall-cmd –reload

View port status :firewall-cmd –zone=public –query-port=80/tcp

Remove open ports :firewall-cmd –zone=public –remove-port=80/tcp –permanent

Firewall rules are updated every time , All need to be updated :firewall-cmd –reload, Update status ;

in addition , After updating the firewall settings , You can also view all open ports :firewall-cmd –zone=public –list-ports

©2020 ioDraw All rights reserved
Vue slot slot: Default slot , Named slot , Scope slot algorithm : Longest common subsequence ( Output all longest common subsequences ) Simple student achievement management system 《 How does the program run 》 Chapter 11 Hardware control method FDTD solution—— Material fitting , Light source settings MMKV The principle and implementation of virtual reality ( one )vue-element-admin Step record of adding menu python Simple understanding of decorator Java The realization of snake eating (1 Hour Society ) New photo album app launched by Microsoft : Using cross platform framework React Native to write