cpanel

rebuild cpanel apache config for custom includes

Posted in cpanel on December 1st, 2009 by paul – Be the first to comment

I needed to create a ServerAlias for one of my subdomains recently and cPanel was stubbornly refusing to do it via the web interface, something to do with dns servers.

Anyway, I just added a simple ServerAlias subdomain.domain.com entry in a file in

/usr/local/apache/conf/userdata/std/2/domain.com/sub.domain.com/subdomain.conf

Then I ran this command:

/scripts/ensure_vhost_includes --all-users

which gets cPanel to rebuild it’s various config files.

Everything works fine now

problems updating ssl certificate on cpanel

Posted in cpanel on October 14th, 2009 by paul – Be the first to comment

Today I had to install a renewed ssl cert for a client on their cpanel server.

cPanel has a pretty good interface for managing ssl certs, but it doesn’t always go to plan (so, perhaps not so good…).

I logged in to the clients cpanel account and installed the new certificate (the contents of the .crt file).

On submitting this, everything appeared to work ok, but the website was still showing the expired certificate. So the new certificate was being installed but apache was still using the old one.

After much head scratching I tried doing the install via WHM, i.e. the ‘root’ user interface.

I used the “Install a SSL Certificate and Setup the Domain” page. I pasted in the ssl cert, and this meant WHM autimatically picked up the domain, the key and ca bundle. Submitting this form seemed to work, i.e. apache started serving up the correct certificate.

Bit of a pain…