This worked flawlessly for me. I had an identical situation with a hosted client whose domain changed as the result of a trade name dispute.Remove the present addon domain from his cpanel.
Now in WHM modify accounts section change the primary domain name to that of addon domain.
Yep, I have done a lot of these lately, and it really works! I don't know WHY, but cPanel does NOT delete the mail accounts associated with the add-on domain, when you delete it. So, it's really easy to delete the Add-on domain... use Modify Account to change the primary domain for the account, to the former Add-on domain name.... and it works!With the method recommended above ("delete the addon and rename the primary") the problem is that you may lose all the stuff associated with the addon when you remove it.
Has anyone tested whether associated email accounts actually do get lost?
Ah ... that's so nice to know! I just tested and while it KEEPS the mail accounts (mail/domain.com/account/* and etc/domain.com) it DELETED the forwarders file (/etc/valiases/domain.com).I don't know WHY, but cPanel does NOT delete the mail accounts associated with the add-on domain, when you delete it.
|Thread starter||Similar threads||Forum||Replies||Date|
|E||Increase swap disk disk on CentOS 7 from 2 GB to 4 GB - how to update /etc/fstab||Operating Systems||3|
|M||Swap's partition size in CloudLinux||Operating Systems||5|
|Server Load 4.17 and swap 100%||Operating Systems||2|
|Disable swap or follow cPanel recommandation?||Operating Systems||5|
|M||How to swap main domain with addon domain ???||Operating Systems||1|