0

Hello i just installeed Fedora and I'm trying to open the port 20190 I do everything just as normal but when i use firewall-cmd --list-all to see if the port is opened, i see nothing !!!

This is what i do to open the port

firewall-cmd --zone=public --permanent --add-port=20190/tcp

Then i reload it

firewall-cmd --reload

Then this is the firewall-cmd --list-all result which my ports is empty !!!!!!

FedoraServer (active)
  target: default
  icmp-block-inversion: no
  interfaces: eno1
  sources: 
  services: cockpit dhcpv6-client ssh
  ports: 
  protocols: 
  forward: no
  masquerade: no
  forward-ports: 
  source-ports: 
  icmp-blocks: 
  rich rules: 
HelloMachine
  • 355
  • 2
  • 8

1 Answers1

0

you are adding the port 20190 to the zone public.

By default, --list-all default to the "default zone (FedoraServer)". See the target in default in your output.

Explicitly mention public to see the rules for the zone "public" like below

firewall-cmd --list-all --zone=public

Additional tip:

If you want to make public as the default zone, use

firewall-cmd --set-default-zone=public

AnilV
  • 56
  • 4