Resolving Domain Park Wrapper Errors
- Written by Vanessa Vasile
- Published in Apache, Fixes
- Permalink
If you run a more populated shared hosting server, sooner or later you'll have received complaints about the dreaded park wrapper errors in cPanel that occur when a user tries to add a parked or addon domain to their cPanel. The errors may look like this:
Error from domain wrapper: domain.com is owned by another user.
Error from domain wrapper: Domain already exists, it was not added.
I've never really been able to attribute that error to a specific action, but my assumption is that it occurs as a result of the end user not completely removing the domain from their cPanel (i.e. hitting esc or closing the browser during removal), therefore not allowing cPanel to remove the domain's entries to allow that domain to be re-added when certain security settings are enabled in WHM > Tweak Settings.
The easy solution to the first error is to enable the option for users to add domains owned by other users via WHM > Tweak Settings. But this is a very bad idea as it essentially allows users to repoint domains that you're already hosting.
If you're attempting to re-add a domain to a cPanel account and are getting one of the above errors, first check that the error needs to be corrected.
Meaning, make sure that the domain in question isn't already set up elsewhere. If it is, you would need to remove it from that account before being able to add it to another.
If the error is actually occurring due to an improperly removed domain, follow the below steps until you are able to add the domain back to the server:
- run /scripts/killdns
on the server to remove the DNS records from the DNS cluster - do grep -r
/var/cpanel/users to see if it exists in a user file, and if so, delete the entry and run /scripts/updateuserdomains, make sure it's remove from /etc/userdomains - grep -r
/var/cpanel/userdata to see if the domain appears in a user's template. If so, remove any files based on the domain name (including .cache files), and remove any subdomain/parked/addon domain entries for that domain from the 'main' file located in that user's folder (i.e. /var/cpanel/templates/username/main), then /scripts/rebuildhttpconf to remove it from httpd.conf .
This should allow you to re-add the domain name to the user's cPanel without getting the park wrapper error.
2 Comments
Pingback: Servers Admins » Blog Archive » Allowing Users to Customize AwStats
Thanks for this. This is the only actually solution I could find on the web.
I’m pretty sure it’s a bug rather than a user error. Havent tested but keep running into it. My guess would be that it can be recreated as follows:
1. On CPanel account1 add “mydomain.com” as an addon domain.
2. Also on account1 add subdomain “sub.mydomain.com”
3. Delete the addon domain under account1
4. Create account2 with mydomain.com as its domain.
5. Try to add “sub.mydomain.com” as an addon