which ports to open/close for a standard web server?


Well-Known Member
Mar 25, 2002
Hi All,

I'm looking for a little guidance.

I'm in the process of setting up a 2 new web development servers here in Perth, Western Australia. Both web servers will be running CentOS, and cPanel+WHM. One is a dedicated server for a single client, the other can expect to host multiple websites for a range of clients with varying needs. Historically I've only ever rented pre-installed, pre-configured cPanel+WHM boxes from US data centres, so this initial 'hands-on' setup is new to me :)

Both servers will be protected by a single hardware firewall / switch box. In addition, both servers will have the apf software firewall installed and configured. Some might think that having a hardware firewall AND a software firewall is overkill, but
a) I like the idea that if one fails (for whatever reason) I've got a second line of defence
b) If the truth be told, very shortly we also plan to have another server - a Windows server - in the same rack, and protected by the same hardware firewall (prob. running Zone Alarm pro as the software firewall bit). The Windows server will be offering a remote backup service, and will prob. not host any websites. But I digress...

My question: (forgetting the Windows box) which ports is it reasonable that I should open on the hardware firewall for the CentOS boxes for the general purpose web serving running cPanel+WHM?

Last edited:


Well-Known Member
Mar 12, 2004
Another good place is in the instructions for install APF. They list all the ports there.