How To Setup an Iptables Firewall to Enable Remote Access to Services in Linux – Part 8

Best Affordable Linux and WordPress Services For Your Business
Outsource Your Linux and WordPress Project and Get it Promptly Completed Remotely and Delivered Online.

If You Appreciate What We Do Here On TecMint, You Should Consider:

  1. Stay Connected to: Twitter | Facebook | Google Plus
  2. Subscribe to our email updates: Sign Up Now
  3. Get your own self-hosted blog with a Free Domain at ($3.45/month).
  4. Become a Supporter - Make a contribution via PayPal
  5. Support us by purchasing our premium books in PDF format.
  6. Support us by taking our online Linux courses

We are thankful for your never ending support.

Gabriel Cánepa

Gabriel Cánepa is a GNU/Linux sysadmin and web developer from Villa Mercedes, San Luis, Argentina. He works for a worldwide leading consumer product company and takes great pleasure in using FOSS tools to increase productivity in all areas of his daily work.

Your name can also be listed here. Got a tip? Submit it here to become an TecMint author.

RedHat RHCE and RHCSA Certification Book
Linux Foundation LFCS and LFCE Certification Preparation Guide

You may also like...

9 Responses

  1. Brody says:

    In image×340.png it says “you can change the default policy for a specific chain only if that chain has been flushed of all its rules.” Is this true of all versions of iptables? The reason I ask is because I’ve found tutorials that add rules to the input chain (for SSH) and then later change the default INPUT policy to drop.

  2. birdman says:

    so instead of iptables-persistent, wouldn’t it be easier/better to use ‘post-up iptables-restore < /path/to/iptables.txt' in the /etc/network/interfaces file on ubuntu?

    • @birdman,
      If you know of a better alternative which works best for you, feel free to use it. Keep in mind that both the LFCS and the LFCE are performance-based, so you have the freedom to choose any tool / command you feel for comfortable with as long as it gets the job done.

  3. Riot says:

    I failed the Exam cause at the End i made a stupid Failure and flush my iptables-Rules and had no Backup to restore them. That costs me round about 30% i think

    • @Riot,
      I am sorry to hear that. However, thanks for letting us know so other readers will be aware of that fact and take the necessary precautions when they take the exam. Good luck next time!

  4. Kindly do correct “packages” to “packet” in your article. Since you mean to say packets throught the article.

Leave a Reply to Riot Cancel reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.