The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

iptables -F

Discussion in 'General Discussion' started by epanagio, Jun 21, 2014.

  1. epanagio

    epanagio Well-Known Member

    Joined:
    May 26, 2012
    Messages:
    50
    Likes Received:
    1
    Trophy Points:
    8
    cPanel Access Level:
    Website Owner
    Somehow a few hours ago all my domains and cpanel that I host on a server weren't available. Using a browser I would get an error telling me that the domain could not be accessed.

    I was able to ssh using the IP address and I started searching the Internet about networking issues and fixes. Finally I issued the command
    Code:
    iptables -F
    I think this command flushes the iptables. If I reboot the server, everything becomes unavailable again. As soon as I issue the above command, poof, everything is available again.

    Can someone please help me understand what is happening here, please. Why is tis command makes everything to work but if I reboot everything becomes unavailable?

    HELP!!!!
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    654
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    That command will temporarily flush the rules. If you want to ensure the default rules are not restored, then you must run a command such as:

    Code:
    /etc/init.d/iptables save
    That being said, it's likely a better idea to install a third-party firewall management utility such as CSF.

    Thank you.
     
Loading...

Share This Page