Configuring IPTABLES and fail2ban on centOS 6

In this post I’ll explain how to configure iptables along with fail2ban and how to start/stop these services without messing up your chains or configuration.

Iptables should be included in your default Linux OS, and you can easily get fail2ban from standard repos. So, just enable the chains you need on /etc/fail2ban/jail.local. Copy the file from /etc/fail2ban/jail.conf if it doesn’t exist. For example, if you want (you should) activate ssh jail, just add/uncomment this lines to the file:

configuring a LAMP server on CentOS 6

In this first post I’ll explain how I configurated my VPS to run a basic LAMP server with multiple php versions, compiled by myself. You can get your own cheap VPS (~3€) and test a lot of things.

Dir structure

Firstly, we’ll create our dir structure. I’ll use jag.co as a domain for this example, you can choose the dir structure you want, but I recommend following this one: