How to restart Apache to make httpd.conf changes permanent?

When cPanel is updated or Httpd service is restarted using WHM, the custom changes made in the Apache configuration file directly won't work because cPanel looks the new values in the file /var/cpanel/conf/apache/local.

However, you can still make the changes directly in the Apache configuration and run the following distiller commands to save the changes. In order to make the changes permanent and make sure the changes don't get overwritten on the next cPanel update / WHM restart, execute the following commands:

# /usr/local/cpanel/bin/apache_conf_distiller –update –main
# /usr/local/cpanel/bin/build_apache_conf
# /scripts/restartsrv httpd

  • 2 Users Found This Useful

Was this answer helpful?

Related Articles

How to speed up website performance using caching solution XCache?

If you are looking for caching solution to speed up the website performance, XCache is one of the...

How to Enable/Disable Apache/PHP Modules Using EasyApache3?

In this article we'll discuss how to enable/disable Apache or PHP modules using the EasyApache...

How to Recompile Apache Using EasyApache from WHM?

You would required to recompile the Apache mainly when you attempt to perform one of the...

How to Upgrade Apache using EasyApache?

In this article we'll discuss how to upgrade Apache using EasyApache tool in WHM. EasyApache is a...

How to Generate a Certificate Signing Request (CSR) with OpenSSL?

OpenSSL is a common utility used to generate a pair of private key and public Certificate Signing...