Custom httpd.conf not saving after rebuild

GoWilkes

Well-Known Member
Sep 26, 2006
703
34
178
cPanel Access Level
Root Administrator
I went through my httpd.conf file quite awhile back, creating numerous RewriteRules, combining ServerAliases, etc. When it was all said and done, the file had gone from 122kb to 30kb (including the new RewriteRules), and the server load was notably lower.

A few days ago, though, Apache updated, and I lost all of those custom configurations! Luckily, I had a backup on file, and after going through everything line-by-line, the only thing that the update HAD to change was turning this line:

UserDir public_html

To this:

<IfModule !mod_ruid2.c>
UserDir public_html
</IfModule>

<IfModule mod_ruid2.c>
UserDir disabled
</IfModule>

So, after I updated everything and uploaded the new, updated httpd.conf, I ran:

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

This was linked in the httpd.conf file, but I thought that I had just overlooked it before.

The problem now, though, is that when I rebuild Apache, via:

/usr/local/cpanel/bin/build_apache_conf

I lose all of those changes again.

So, the question is, how can I permanently store those changes, so that future updates don't wipe them all out again?