• Article for your preferred language does not exist. Below is international version of the article.

Article ID: 120516, created on Mar 12, 2014, last review on Dec 18, 2015

  • Applies to:
  • Odin Business Automation Standard
  • Plesk Automation

Symptoms

  1. While provisioning a subscription in Odin Business Automation - Standard (OBAS), the following error is shown:

    subscription activating failed: failure response: status: -1, module_id: PleskIntegration, extype_id: 12, error_message: Webspace with primary domain name already exists.

  2. Attempting to transfer a domain from Plesk to Plesk Automation (PA) fails with the following error:

    [2014-03-10 15:05:49] [INFO] restore/example.com| Create webspace 'example.com' in subscription #33
    [2014-03-10 15:05:50] [ERROR] restore| Failed to perform an action on subscription 'example.com': Failed to create webspace in PPA. Exception message: [None] Webspace with primary domain name example.com already exists.
    

    or

    [ERROR]  | An internal error occurred in POA XML-RPC: [2006] Subscription #1111 does not exist
    
  3. When attempting to create webspace, the Control Panel shows an error:

    Webspace with primary domain name example.com already exists.
    
  4. A domain with the same name is present in the Websites section. However, there is no webspace in the existing subscriptions with this name.

Cause

Orphaned database records prevent the operation from finishing. This issue is caused when webspace with the same name has been created earlier and then removed, but some tasks failed during the removal process and were canceled. As a result, the subscription was not fully removed.

Resolution

  1. Log in to the Plesk Automation (PA) Management Node as root.

  2. Make sure that the required domain exists in the PA database:

    [root@ppa ~]# psql -U plesk -h `hostname` plesk -c "select * from plesk_webspaces where domain='<domain_name>';"
     webspace_id | account_id | sub_id |       domain       | is_enabled | is_brand
    -------------+------------+--------+--------------------+------------+----------
             988 |        866 |   1143 | <domain_name>      | y          | n
    (1 row)
    
  3. Check the related records in the 'subscriptions' and 'plesk_hosts' tables (they will be empty if the subscription does not exist in PA):

    plesk=> select * from plesk_hosts where webspace_id=988;
    webspace_id | referer | host_id | ipv4 | ipv6
    -------------+---------+---------+------+------
    (0 rows)
    
    plesk=> select * from subscriptions where sub_id=1143;
     webspace_id | referer | host_id | ipv4 | ipv6
    -------------+---------+---------+------+------
    (0 rows)
    
  4. Make sure that the Plesk database does not contain any records for the domain:

    mysql> select * from domains where name='<domain_name>';
    Empty set (0.00 sec)
    
  5. Go to PA control Panel > Operations > Tasks > Canceled Tasks and filter tasks by Subscription ID (the sub_id from step 2). Find the canceled task 'Remove the webspace #988' and re-run it (the task should finish successfully). Afterwards, log into the OBAS Control Panel and restart the failed task.

  6. If the canceled tasks were removed, create a backup of the PPA database using the following article, then remove the orphaned domain record from the PA database:

    [root@ppa ~]# psql -U plesk -h `hostname` plesk -c "delete from plesk_webspaces where domain='<domain_name>';
    

    NOTE:* The tables "plesk_counters", "plesk_hosts", "plesk_resource_usage", "plesk_webspace_resources" are referenced by the 'webspace_id' field on the delete cascade. As a result, removing the record from the "plesk_webspaces" table will cause the corresponding record to be removed from the other tables.

  7. Execute the 'domain' utility to make sure that there are no leftovers in the Plesk database for the corresponding domain:

    # /usr/local/psa/bin/domain --remove <domain_name>
    

    If you encounter a message that the domain does not exist, remove the corresponding entry from the database manually:

        # mysql -uadmin -p`cat /etc/psa/.psa.shadow ` psa -e"delete from domains where name='example.com'"
    
  8. If the issue is related to provisioning in OBAS, log into the OBAS Control Panel and restart the failed task.

Search Words

subscription activating failed

unable to add subscription

Unable to create domain

subscription

Webspace with primary domain name mineandprojects.com already exists

No subscription for the domain

try to delete websites

Cannot delete website

"Webspace with primary domain name wwwbkp.com already exists

cannot delete website

Webspace with primary domain name

domain already exists

subscription allready exists

primary domain already exist

domain cannot be created

Process provisioning for document; subscription activating failed: failure response: status: -1, module_id: PleskIntegration, extype_id: 12, error_message: Webspace with primary domain name fundacioncapacitar.org already exists

Webspace with primary domain name babybootcamp.com already exist

Webspace with primary domain name resources.nex-tech.com already exists.

Unable to add deleted domains

cannot add domain

Adding new subscription with dedicated IP

cannot create subscription

primary domain name already exists

Webspace with primary domain name already exists

cannot remove domain

delete website

fkfikwr

http://kb.odin.com/en/120516

Webspace with primary domain name dicarve.id already exists.

400e18f6ede9f8be5575a475d2d6b0a6 caea8340e2d186a540518d08602aa065 e0aff7830fa22f92062ee4db78133079

Email subscription for changes to this article
Save as PDF