Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 4 of 4
  1. #1
    Registered User
    Join Date
    Aug 2011
    Posts
    2

    Default Switching the main domain for an account in WHM

    Hi all,

    I am trying to switch the main domain for my client to another domain. For the purpose of testing, I created an account with a main domain sdomain.mydomain.com and addon domain sdomain1.mydomain.com. I removed the sdomain1.mydomain.com and went to WHM. I replaced the sdomain.mydomain.com with the subdomain that was removed. Then I added the replaced subdomain as an addon domain. Everything went fine.

    But... It didn't when I tried to do the same on my client's account. He wanted to switch the main domain with another domain (hisdomain.com to anotherdomain.com). So I removed the addon domain anotherdomain.com (which was the target main domain for the account) and went to WHM. Switching the domains went quite smoothly, no problems occured. But when I tried to add the domain that was the main domain, an error occured. there is a message about editing the httpd.conf file and I have no clue where to find this file and how to edit it. Moreover, to my surprise, the domain that was the main domain for this account appeared as an addon domain in "addon domains" section, but the e-mail accounts related to that domain are no longer on the list in the "email accounts" section. When I try to remove the domain, a message saying that I am not the owner of this domain appears.

    What should I do?

    More info:
    - I have shell access
    - I have access to the root account (but I use the reseller account)

    Thanks in advance for your help
    Oruen

  2. #2
    cPanel Staff cPanelTristan's Avatar
    Join Date
    Oct 2010
    Location
    somewhere over the rainbow
    Posts
    6,305
    cPanel/Enkompass Access Level

    Root Administrator

    Default Re: Switching the main domain for an account in WHM

    I have one question. If the old main domain is supposed to be an addon domain and it is showing up now as an addon domain, why does that domain need to be removed and re-added as an addon domain? Is the domain not working or pointing to the wrong folder location?
    cPResources: Support Options | More Support Options | Forums Search | cPanel.net Site Search | Mailing Lists(Alt) | Docs
    -- Tristan, Forums Technical Analyst, cPanel Tech Support

    Submit a ticket | Check an existing ticket

  3. #3
    Registered User
    Join Date
    Aug 2011
    Posts
    2

    Default Re: Switching the main domain for an account in WHM

    There was a lot of e-mail accounts defined for that domain that don't show up in the email accounts section. I have read a tutorial that says that if I remove the domain and then re-attach it, the email accounts will be there again.

    Thanks for your help
    Oruen

  4. #4
    cPanel Staff cPanelTristan's Avatar
    Join Date
    Oct 2010
    Location
    somewhere over the rainbow
    Posts
    6,305
    cPanel/Enkompass Access Level

    Root Administrator

    Default Re: Switching the main domain for an account in WHM

    The following thread explains what to check to remove the subdomain that likely exists for that addon domain:

    http://forums.cpanel.net/f5/error-do...tml#post915312

    You can replace sub with the addon domain name in most instances to see if it exists in any of the files. The main differences would be these greps:

    Code:
    grep addon.com /var/cpanel/users/*
    grep addon.com /etc/*
    grep -R addon.com /var/cpanel/userdata/*
    ls -lah /var/named/addon.com.db
    cPResources: Support Options | More Support Options | Forums Search | cPanel.net Site Search | Mailing Lists(Alt) | Docs
    -- Tristan, Forums Technical Analyst, cPanel Tech Support

    Submit a ticket | Check an existing ticket

Similar Threads & Tags
Similar threads

  1. Switching main domain for resold acct
    By Sauzzbozz in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 11-21-2007, 10:44 AM
  2. Switching main domain
    By Netmaking in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 11-04-2006, 02:47 PM
  3. Switching Account's Main Domain
    By xxkylexx in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 07-06-2006, 04:29 PM
  4. Cpanel for main Domain? WHM Can't create account!
    By kioussis in forum cPanel and WHM Discussions
    Replies: 7
    Last Post: 03-29-2005, 10:49 AM
  5. switching domain name on existing account?
    By magicman in forum cPanel and WHM Discussions
    Replies: 3
    Last Post: 02-11-2005, 07:47 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube