Editing http.conf and my.cnf - where are the correct files?


Well-Known Member
May 7, 2018
cPanel Access Level
Root Administrator
I am using a CRM system that requires specific configuration settings on the server. Yesterday I added some of the specificastions to the http.conf file located at:

nano /etc/apache2/conf/httpd.conf

Then I noticed when |I re-started the server all my changes disappeared. I later spotted the message at the foot of http.conf file saying this particular file should not be edited. It says we should use include files.

My question is, where do I find the include file to add my changes?

I need to add/change things like:

Header: Referrer-Policy same-origin
Header: X-Powered-By

In addition I need to add these values:
max_connections 151
thread_cache_size 9
key_buffer_size 8.00 MB
query_cache_size 40 MB
tmp_table_size 16 MB
max_heap_table_size 16 MB

I tried adding them to the following file (after google search it pointed me to that file):
nano /etc/my.cnf
But the changes don't take effect.

Is someone able to tell me what the correct files are that I should be editing?

Kind regards


Well-Known Member
Oct 13, 2005
Spokane, Washington
cPanel Access Level
Root Administrator
For httpd.conf you can try this this below in WHM
  • Home »
  • Service Configuration »
  • Apache Configuration »
  • Include Editor
Then Select All Versions under Pre VirtualHost Include

Enter what you need to put in and click on Update.

For /etc/my.cnf file I do not mess with this. I run Joomla, Word Press and few others and had no issues with defauts.

But in the Tweak Settings
  • Home »
  • Server Configuration »
  • Tweak Settings
In the MySQL Tab I turned on everything including this below and allow cPanel to control it.

Allow cPanel & WHM to determine the best value for your MySQL innodb_buffer_pool_size configuration? [?]
cPanel & WHM will use your total number of tables to adjust the innodb_buffer_pool_size value during each MySQL restart.

I hope this helps.
  • Like
Reactions: cPanelLauren


Product Owner II
Staff member
Nov 14, 2017
  • Like
Reactions: vlee