Unable to delete the azure resource virtualNetworks/test-dspm-connectivi

Ravi Kumar, Rayani V 0 Reputation points
2026-03-31T11:08:53.6466667+00:00

I have attempted to delete the subnet thorugh CLI & from Portal, but the deletion failed with the following error :

-------- Failed to save subnet 'subnet-bastion'.
Error: 'Subnet /subscriptions/6e9bd615-be90-4590-8bce-a2fa1813e82f/resourceGroups/PublicCloudManaged-ComputeScan-Dev/providers/Microsoft.Network/virtualNetworks/test-dspm-connectivity/subnets/subnet-bastion requires any of the following delegation(s) [Microsoft.Web/serverFarms] to reference service association link /subscriptions/6e9bd615-be90-4590-8bce-a2fa1813e82f/resourceGroups/PublicCloudManaged-ComputeScan-Dev/providers/Microsoft.Network/virtualNetworks/test-dspm-connectivity/subnets/subnet-bastion/serviceAssociationLinks/AppServiceLink. Those delegations are either missing or getting deleted from subnet.'


Observation : Checked and confirmed that there is no VNet integration or delegation configured on the subnet. Also tried below approach, but no luck
User's image

Next Action : Since the Service Association Link (SAL) is an internal Azure object that tracks the connection between an Azure service and a subnet, our internal operation team recommended/asked to create a ticket with Microsoft to have the SAL removed.

Azure App Service
Azure App Service

Azure App Service is a service used to create and deploy scalable, mission-critical web apps.


1 answer

Sort by: Newest
  1. AI answer

    2026-03-31T11:09:18.1633333+00:00

    The subnet is blocked by an orphaned App Service serviceAssociationLink (AppServiceLink). Because the linked App Service plan no longer exists, the SAL can’t be cleaned up automatically and prevents subnet deletion.

    Use one of the following approaches.

    1. Purge the orphaned Service Association Link (preferred)
    • Run the Azure CLI purge command for unused App Service VNet integration (from Cloud Shell or local CLI) targeting the affected subnet and virtual network.
    • The purge operation removes the unused virtual network integration and its SAL from the subnet.
    • After the purge completes successfully, retry deleting or modifying the subnet.
    1. Re-create and cleanly disconnect the App Service integration (workaround) If the purge command doesn’t work or isn’t available in the environment:
    2. Re-create an App Service plan and App Service using the same web app name that originally had VNet integration (if known).
    3. In the Azure portal, open the App Service → Networking → configure VNet integration to the problematic subnet (subnet-bastion).
    4. After integration is established, go back to VNet integration and select Disconnect to remove the integration cleanly.
    5. Delete the App Service and App Service plan if they are no longer needed.
    6. Delete or modify the subnet again; the SAL should now be removed.
    7. Contact Microsoft Support If both approaches fail or the purge API isn’t accessible, open a support request with Microsoft and reference that the subnet is blocked by an orphaned App Service serviceAssociationLink (AppServiceLink) with allowDelete=false. Support can remove the SAL on the backend.

    After the SAL is removed, the subnet should delete normally, following the usual order (VM NICs, private endpoints, service deployments, service association links, service endpoints, delegations, then subnet).


    References:

    AI-generated content may be incorrect. Read our transparency notes for more information.

    Was this answer helpful?

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.