restarting firewall loses my new rule
I want to open port 1055 so I did the following command:
iptables -A INPUT -m state --state NEW -m tcp -p tcp --dport 1055 -j ACCEPT Then I ran iptables -L -n to check the rule was there. Then I ran /etc/init.d/firewall restart and my rule has gone...? There is no man for firewall either. What do I have to do to get this port opened permanently? Thanks. |
Your /etc/init.d/firewall script probably does a "iptables --flush" that removes all the rules. Edit the script and add your rule there so it's added on every boot. Firewall rules are kept in startup files afaik, at least I do that : ).
|
Quote:
Quote:
There are a number of ways of skinning this particular cat and you just have to choose the most appropriate one for your circumstances. |
Thanks! I added the rule to the firewall script and it worked a treat :D
|
All times are GMT -5. The time now is 11:42 AM. |