CentOS Optimization: Apache
CPanel Installations
If you are modifying an Apache configuration that is modified by CPanel, then you will need to use the CPanel interface to make changes.
Additionally, you will need to edit /usr/local/apache/conf/includes/post_virtualhost_global.conf
to make any changes to the global configuration that fall outside of the scope of directives that CPanel can access.
Here are some sample configurations that you would want to add.
AWstats
Alias /awstats "/var/www/html/awstats" <Directory "/var/www/html/awstats"> Order deny,allow Deny from all Allow from 1.2.3.4 Allow from 127.0.0.1 </Directory>
server-info
<Location /server-info> SetHandler server-info Order deny,allow Deny from all Allow from 1.2.3.4 </Location>
Apache security
RequestHeader unset Range RequestHeader unset Request-Range ContentDigest On FileEtag None TraceEnable Off
Apache tuning
HostnameLookups Off EnableMMAP On EnableSendfile On