SYMPTOMS
During new domain creation, doman is not created and the following error is shown:DNS records for domain with such name already exist
or
The subdomain with such name already exists
CAUSE
DNS record for the domains you are trying to add already exist in Plesk database, so new domain with the same name cannot be added.RESOLUTION
Try to find the record in DNS settings of existing domains with similar name. If it is difficult to find, use the following shell command to know exact DNS record that prevents new domain creation (replace YOUR-DOMAIN with a real name):# mysql -uadmin -p`cat /etc/psa/.psa.shadow` -Dpsa \
-e"select z.name, r.host, r.type, r.val from dns_zone z, dns_recs r where z.id=r.dns_zone_id and r.host like '%YOUR-DOMAIN%';" for example:
You try to create a domain "support.mydomain.com", but this error appears. The above shell command returns:
mysql> select z.name, r.host, r.type, r.val from dns_zone z, dns_recs r where z.id=r.dns_zone_id and r.host like '%support.mydomain.com%';
+-------------+-----------------------+------+----------------+
| name | host | type | val |
+-------------+-----------------------+------+----------------+
| mydomain.com| support.mydomain.com. | A | 192.168.45.200 |
+-------------+-----------------------+------+----------------+ So, open the corresponded domain (mydomain.com in our example) in Plesk CP and examine it's DNS zone for the records that contains name of the domain you tried to add. If you wish to create "support.mydomain.com" as a separate domain in Plesk, then existing record have to be removed from the "mydomain.com" DNS zone.
If the DNS records exist in the dns_recs table but the is no domain in Plesk they belong to, you can remove them directly from the dns_recs table. Make 'psa' database dump before Plesk database modification.