How to Open Port on Server

How to Open Port on Server

Following are the commands to open tcp or udp ports on the server.

Before using commands for opening the port please make sure the specific port is already opend and what is the use of that port.

you can verify the port with

netstat -nap | grep :

1. you can open TCp port with

iptables -A INPUT -p tcp –dport


2. You can open UDP port with

iptables -A INPUT -p udp –sport


after that

3. service iptables save

and for flushhing iptables us

iptables -F

Visit the eukhost website for more news, blog posts, knowledge base articles and information on our wide range of hosting services.