problem redirecting to Suspended Page in WHM

asked Apr 22, 2012 in General by chris (500 points)

I have suspended a domain using suspended page option in WHM and now the domain that I had just suspended is redirecting to the WHM login screen instead of redirecting to the suspended page. How can I fix this? Please help


2 Answers

0 like 0 dislike
answered Apr 22, 2012 by expert (14,380 points)
Each time an account is suspended, WHM creates an .htaccess with the following information;
RedirectMatch .* http://<hostname>/

if points to the IP of WHM but points off of the server WHM is on, this is a problem. As such, the hostname needs to be updated  within cPanel to something such as and then add the A record in WHM or our DNS.
After doing so, log into the server via SSH and copy the files in /usr/local/apache/htdocs/ to /home/<username_of_hostname>/www/ (where the 'username_of_hostname' is the username of the domain which is now the hostname) by running the command below via SSH:
cp -R /usr/local/apache/htdocs/ /home/username_of_hostname/www/
Chown the files to the correct user.
cd /home/<username_of_hostname>/www/ (where <username_of_hostname> is the user on the server noted above)
chown -R username.username .

Then you should un-suspend the site that was incorrectly resolving to the WHM login page and then re-suspend it. What this does is creates a new .htaccess file with the correct information in it now.
0 like 0 dislike
answered Apr 22, 2012 by RalphK (5,800 points)
If you are not sure how to update the host name, this is how you can do it:

Open a web browser and connect to your cPanel Control Panel located at https://ip address:2087.
Login as the Administrator using the information sent to you in your setup email.
From the menu, under Networking Setup, click Hostname.  
Enter a fully qualified domain name as the new Hostname and click Change.