Install CloudFlare Apache Module

Download the Pearl installer script that will allow you to compile the Apache EasyScript to include the mod_cloudflare module. Login your cpanel server ssh.

perl <(curl https://raw.github.com/tylerl/util/master/easyapache/cloudflare.pl) install

Go to WHM->EasyApache update script.

mod-cloudflare-apache

You get to the short options list or exhaustive list and select the ModCloudFlare option.

mod-cloudflare-apache

Save and build the new profile. Thats all!!.. When you run the installer script, it downloads the latest version of the mod_cloudflare.c source code from the official distribution point and packages it up with a simple description file that tells EasyApache what to do with it.

Solution 2

You can simply install it directly through the script. To run the install script on your server, download this script here: https://raw.github.com/tylerl/util/master/easyapache/cloudflare.pl Then run it using the following command:

perl cloudflare.pl install

Once you’ve installed the EasyApache component, re-run the EasyApache build script, either through the WHM web interface or by running /scripts/easyapache to complete the installation. Select “Mod CloudFlare” from the build menu to enable the Apache module, or deselect it to disable the module, and then run your build.

mod_cloudflare.c

Based on mod_remoteip.c, this Apache extension will replace the remote_ip variable in user’s logs with the correct remote IP sent from CloudFlare. The module only performs the IP substitution for requests originating from CloudFlare IPs by default. To install, follow the instructions on: https://www.cloudflare.com/resources-downloads#mod_cloudflare Logging Real Visitor IP Addresses: mod_cloudflare for Apache httpd

Preserve Original Visitor IP in Log Files

All requests to a CloudFlare protected website will come from the CloudFlare IP address ranges: http://www.cloudflare.com/ips

DO NOT THROTTLE OR RATE-LIMIT these IP addresses, or your customers’ website visitors will see a “Website Offline” page.

CloudFlare passes the original visitor IP address in the header of every request. To retrieve the original visitor IP from the header, install the appropriate software on your server, you can find download links in the CloudFlare Partner Portal at https://partners.cloudflare.com. (Note: If you use the cPanel plugin and are running Apache, the visitor IP software will automatically be installed).

0.00 avg. rating (0% score) - 0 votes
Website Pin Facebook Twitter Myspace Friendfeed Technorati del.icio.us Digg Google StumbleUpon Premium Responsive