remoteIP
cPanel
install the mod_remoteip Apache module via EasyApache in WHM
Create the following file on the server:
In here, we need to enter the addresses for proxying, in this example I'm using CloudFlare's IP ranges:
This list is correct as of April 2024, it may be worth double checking CloudFlares IP range list to ensure all IPs are included.
Once you've done this, we need to update the log formatting to instruct Apache to write logs correctly.
Via WHM, browse to the following page:
WHM > Service Configuration > Apache Configuration > Global Configuration
From here we need to amend the combined and common LogFormat variables.
In short, any reference to 'h' needs to be replaced with an 'a'
Before:
After:
Save the configuration and make sure Apache reloads without any issues.
No Comments