Quantcast
Channel: CodeSection,代码区,Linux操作系统:Ubuntu_Centos_Debian - CodeSec
Viewing all articles
Browse latest Browse all 11063

Tips & Tricks : CentOS firewalld : open port

$
0
0
Once you install CentOS 7 , by default firewalld will block almost all network traffic.

In order to open ports for certain services you can easily reconfigure firewall using firewall-cmd command.

[root@localhost firewalld]# firewall-cmd --get-active-zones
public
interfaces: eno16777728
[root@localhost firewalld]# firewall-cmd --zone=public --add-port=80/tcp --permanent
success
[root@localhost firewalld]# firewall-cmd --reload
success

Example contains port 80, however you can open any port using same method.

It is worth to check zones configured on your machine and make sure you open port in proper zone where service should be enabled.


Viewing all articles
Browse latest Browse all 11063

Trending Articles