pokermagic

Member
Sep 1, 2010
7
0
51
Hi,

I have a dedicated box which I am the only administrator on. For some reason and I can't tell why this happens is that my apache httpd.conf file gets updated. This unfortunately messes up our site since we have specific configurations.

It seems to just happen randomly and always just after midnight. It just happened tonight at 00:08 if I look at the file.

My question is what could be automatically updating my apache? My only thought is through WHM and some configuration. Does anyone have any thoughts if apache is getting automatically update through WHM and if so how I can at least disable this so my site does not go down randomly?

Regards,

JR
 

24x7server

Well-Known Member
Apr 17, 2013
1,912
99
78
India
cPanel Access Level
Root Administrator
Twitter
Hello,

I will suggest you update your changes in apache config and run the following command so that you should not face any issues after apache rebuild

Code:
/usr/local/cpanel/bin/apache_conf_distiller --update
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,270
463

mctekk

Registered
Mar 24, 2004
4
0
151
Hello :)

You can use custom templates to include information inside the httpd.conf file that the Template Toolkit will process. Custom templates are preferable to direct changes in httpd.conf, because your changes to httpd.conf could be overwritten.

Custom Directives Outside of a VirtualHost Tag
Changes Contained Within a VirtualHost Directive

Thank you.
Hi Michael,

Same thing happen to me, is there any way to avoid cpanel from overwriting the httpd.conf?

I have some specific modification to httpd.conf and even after running /usr/local/cpanel/bin/apache_conf_distiller --update and recreating the httpd.con for some reason they don't stick.

So I'm looking for a way to lock httpd.conf but cant find it.

Thanks
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,270
463
The two links in my last response describe to preserve changes to the Apache configuration file.

Thank you.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,270
463
There are several functions of cPanel/WHM that rebuild the Apache configuration file. It's not so much that it's overwritten, but rather it's rebuilt through:

/scripts/rebuildhttpdconf

Custom changes are preserved as long as you use the supported methods of making changes to the file.

Thank you.