Tuesday 4 March 2014

Manually remove the cPanel account from the server

Inorder to manually remove the cPanel account from the server , please follow the below steps : 
(Note: For example consider the domain name as abc.com and username of the cPanel as abc)

  • rm /var/cpanel/users/abc
  • Remove the Virtual host entry for the domain abc.com from httpd.conf
    vi /etc/httpd/conf/httpd.conf remove the site VirtualHost entry
  • rm /var/named/[domain_name].db (If you used DNS Only cPanel, you may remove zone through WHM).
  • vi /etc/userdomains (remove only the abc.com: abc entry)
  • vi /etc/trueuserdomains (remove only the abc.com: abc entry)
  • vi /etc/trueuserowners ( remove only the abc: root entry)
  • vi /etc/named.conf ( remove the following entry:
                           zone "abc.c" {
                           type master;
                           file "/var/named/abc.com.db";
                             }; )
  • vi /etc/localdomains (remove only the abc.com: abc entry)
  • /etc/valiases (remove only the abc.com: abc entry)
Please login into the mysql and follow the steps
  • #mysql
  • mysql > use mysql;
  • mysql > drop user dbuser@localhost;
                     OR
          mysql> delete from mysql.user where user=dbuser;
  • vi /var/cpanel/databases/users.db ( remove only the entry of the domain )
  • rm /var/cpanel/databases/abc.cache
  • rm /var/cpanel/databases/abc.yaml
  • vi /etc/dbowners ( remove only the abc.com: abc entry)
This will manually remove the cPanel account from the server. 

6 comments:

  1. Great Post, I love to read articles that are informative and actually have good content. Thank you for sharing your experiences and I look forward to reading more.

    cpanel server management | 24x7 Technical Support Service

    ReplyDelete
  2. A good tut however i need to vary the domain of my cpanel account… i.e. I don’t have whm access however have ssh root access. thus my previous domain was removed or expired currently i need to vary this please any tutorial or resolution Cpanel Server Management

    ReplyDelete
  3. Good job! This message is a great example of why I go back again to read your quality content that is always updated.
    cpanel

    ReplyDelete
  4. Interesting topic for a blog. I have been searching the Internet for fun and came upon your website. Fabulous post. Thanks a ton for sharing your knowledge! It is great to see that some people still put in an effort into managing their websites. I'll be sure to check back again real soon. 4gbps servers

    ReplyDelete
  5. A person publish your website or even weblog in addition to a short explanation. backlinks freelancer

    ReplyDelete
  6. If you would like to secure your blog, please reach out to us and we will help you cleanup and secure this website. We would be happy to provide you with a fully Managed Wordpress Hosting at CSpace Hostings

    ReplyDelete

ERR_CONTENT_DECODING_FAILED

If you are getting the error as ERR_CONTENT_DECODING_FAILED while accessing the domain then add the below extension in php.ini  ++++++++...