Article ID: 119160, created on Dec 15, 2013, last review on Sep 6, 2015

  • Applies to:
  • Operations Automation 6.0
  • Operations Automation 5.5
  • Operations Automation 5.4
  • Business Automation 5.5
  • Business Automation 5.4
  • Plesk Automation 11.5

Symptoms

A subscription cancellation order fails:

Removing of Service of Subscription #XXXXXX is failed. Deletion service of Subscription #XXXXXX failed.

In PEMGATE.log and in poa.log, an error can be seen:

Parallels Operations Automation error #extype_id #120, module_id #db_service, Foreign key 'domain_hosting_bindings_fk2' violation while executing ' DELETE FROM subscriptions WHERE sub_id ? AND sub_id !  1 AND NOT EXISTS (SELECT 1 FROM st_resources st JOIN subs_resources sr ON (st.src_rt_instance_id   sr.rt_instance_id) WHERE sr.sub_id ? )'..

The same error may also occur when trying to destroy a terminated/stopped subscription by clicking the "Destroy" button in Business Automation (BA).

Cause

The DNS hosting resource usage on the Operations Automation (OA) side is incorrect:

plesk=> SELECT s.curr_usage FROM subs_resources s JOIN resource_types rt ON s.rt_id = rt.rt_id WHERE rt.restype_name = 'DNS hosting' AND s.sub_id = <SUB_ID>;
curr_usage
------------
0

One of the possible reasons is bug POA-81039/POA-81477 (The resource usage data becomes incorrect if the addDomain is executed for the existing domain with DNS hosting).

Resolution

Adjust a resource usage to 1 (please contact Odin Support for assistance) and retry the attempt to provision an order or destroy a subscription.

Search Words

Removal of susbcription results in error

destroy subscription

Cannot terminate external DNS subscription

An unexpected error has occurred during subscription termination: 'PleskAutomation module: Foreign key 'domain_hosting_bindings_fk2' violation while executing ' DELETE FROM subscriptions WHERE sub_id = ? AND sub_id != 1 AND NOT EXISTS (SELECT 1 FROM st_resources st JOIN subs_resources sr ON (st.src_rt_instance_id = sr.rt_instance_id) WHERE sr.sub_id = ? )'. at removeSubscription call'

Other

subscription destruction error

Removing subscription results in error

Cancellation of Subscription #1024587.

domain_hosting_bindings_fk2

foreign key violation destroy subscription

failed cancellation orders where the Complete Operation Manually steps were performed

Destroying service of Subscription #10112069 failed: Parallels Operations Automation error #extype_id #120, module_id #db_service, Foreign key 'domain_hosting_bindings_fk2' violation while executing ' DELETE FROM subscriptions WHERE sub_id ? AND sub_id ! 1 AND NOT EXISTS (SELECT 1 FROM st_resources st JOIN subs_resources sr ON (st.src_rt_instance_id sr.rt_instance_id) WHERE sr.sub_id ? )'..

-

domain not removed from CCP

Удалить доменное имя из ccp

whmcs

domain remove

delete webhosting domain

removing subscription

Cannot delete 1 customer account(s). Reason: Foreign key > 'domain_hosting_bindings_fk2' violation while executing ' DELETE FROM > subscriptions WHERE sub_id = ? AND sub_id != 1 AND NOT EXISTS (SELECT 1 > FROM st_resources st JOIN subs_resources sr ON (st.src_rt_instance_id = > sr.rt_instance_id) WHERE sr.sub_id = ? )

ac82ce33439a9c1feec4ff4f2f638899 caea8340e2d186a540518d08602aa065 5356b422f65bdad1c3e9edca5d74a1ae 2554725ed606193dd9bbce21365bed4e 5b048d9bddf8048a00aba7e0bdadef37 198398b282069eaf2d94a6af87dcb3ff 210d017ddc3a076d22f0f865b1cf0730 92711db0799e8aefe8e51f12dace0496 e12cea1d47a3125d335d68e6d4e15e07 801221f8cd76fba7300d1e6817c8e08b 33a70544d00d562bbc5b17762c4ed2b3 e0aff7830fa22f92062ee4db78133079 956c448bddc7e1f3585373687602379f 6f1456866eed87488c0f02b298a741c0

Email subscription for changes to this article
Save as PDF