iptables

To list current rules, run

Or

To list rules in numeric format, run

Or

To view nat rules

To see rules with counter, use

Open port 80

To open port 8080 in iptables firewall, run

Open Port Range

Whitelist an IP

Forward a Port to Another

All request on port 80 will get forwarded to port 7080

Saving IP tables

Above IP table commands take effect immediatly, but they get lost when you reboot the PC. To make it permanent, run

You can also use

Related config are saved in

Before Flush

Make sure all Chains are set to ACCEPT, if DROP, run

Need help with Linux Server or WordPress? We can help!

Leave a Reply

Your email address will not be published. Required fields are marked *