How to Install mod_geoIP for cPanel

Please do the following steps:

# cd /var/cpanel/easy/apache/custom_opt_mods
# wget http://docs.cpanel.net/twiki/pub/EasyApache3/CustomMods/custom_opt_mod-mod_geoip.tar.gz
# tar -xvf custom_opt_mod-mod_geoip.tar.gz

run easy apache. That's all.

 

In mod_security create a new rule for China:

# mod_geo deny access by country
SecFilterSelective “ENV_GEOIP_COUNTRY_NAME” “China” “deny,log,status:403″

Note the env variable must start with ENV_ so mod_sec knows where to look for it.

Was this answer helpful?

 Print this Article

Also Read

Optimize MySQL

You could try running the following script to see the recommendations it provides: Code:...

Install Softaculous di cPanel

Sebelum melakukan install, pastikan ioncube terinstall pada server.Perintah instalasi: wget -N...

How to Change Your FTP Port

Lately FTP has been a problem for a lot of hosting providers. Especially since the recent influx...

Mail Security Tweaks

Cek lokasi pengiriman email terbanyak grep cwd /var/log/exim_mainlog | grep -v /var/spool | awk...

Installing mod_cloudflare on cPanel

You can install mod_cloudflare on your cPanel server by running the following command:sudo perl...

Powered by WHMCompleteSolution