We help IT Professionals succeed at work.
Get Started

WHM cPanel iptables

Last Modified: 2012-05-10
After WHM/cPanel was first installed by cPanel tech support I could not access WHM. I contacted cPanel and they said that my iptables need to be updated to allow access. This is what they told me to run via SSH:

iptables -L
service iptables save
service iptables stop

I don't know what that does but it makes it work. Recently, the server was reset and the iptables went back to the original settings before I changed it. I asked my hoster what happened and they said I needed to update the iptables again and save the config so if the server is reset again the correct. But they also told me that the way I opened the iptables were too liberal and the server could be prone to attacks.

My question is how should set the iptables for a normal web server that uses WHM/cPanel, FTP, SSL, MySQL, IMAP, SMTP, SSH and how do I save the configuration so when the server is reset the new config remains?
Watch Question
Technical Support
Top Expert 2005
This problem has been solved!
Unlock 2 Answers and 4 Comments.
See Answers
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE