How to unblock port 25 in IpTables?

September 20, 2013 19.8k views
Hello Can someone please tell me how i can unblock port 25 in IpTables ?
6 Answers
iptables -I INPUT -p tcp -m tcp --dport 25 -j ACCEPT
Thank you. Will that also save, so when i reboot it remembers it ?
Not by default. What OS are you using?
Run these commands:

sudo apt-get install iptables-persistent

iptables-save | sudo tee /etc/iptables/rules.v4
  • This doesnt appear to work. It still says connection refuses. Bad part about it is, my port 993 was working now that doesnt appear to work either after installing the iptables persistent

Have another answer? Share your knowledge.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!