Unable to delete VNet due to AppServiceLink

Jackson Pedrini 51 Reputation points
2022-12-08T11:28:58.167+00:00

Hi,I am having issue removing a Vnet. The subnet had a serviceAssociationLinks/AppServiceLink. However, that AppService is long gone. Each time I try to delete the subnet or vnet, I get the following error:

Failed to delete virtual network 'jpedrini-dcc8982ad5-vnet'. Error: Subnet jpedrini-dcc8982ad5-appsubnet is in use by /subscriptions/710f60ea-8116-4aa0-be0c-f3894b0e5302/resourceGroups/RG_WORDPRESS/providers/Microsoft.Network/virtualNetworks/jpedrini-dcc8982ad5-vnet/subnets/jpedrini-dcc8982ad5-appsubnet/serviceAssociationLinks/AppServiceLink and cannot be deleted. In order to delete the subnet, delete all the resources within the subnet. See aka.ms/deletesubnet.

How can I remove this resource?

Thank you,

Azure Virtual Network
Azure Virtual Network
An Azure networking service that is used to provision private networks and optionally to connect to on-premises datacenters.
2,752 questions
Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
8,883 questions
{count} votes

2 answers

Sort by: Most helpful
  1. GitaraniSharma-MSFT 50,011 Reputation points Microsoft Employee Moderator
    2022-12-22T17:41:58.897+00:00

    Hello @Jackson Pedrini ,

    I understand that you were unable to delete an Azure VNet due to an existing AppServiceLink and you don't remember the previous App service plan name to recreate the link for further troubleshooting.

    We created a support request to delete the AppServiceLink from the backend.

    The support team engaged the backend team and they deleted the Orphaned Service Association Link, post which you were able to delete the Vnet successfully.

    Kindly let us know if the above helps or you need further assistance on this issue.

    ----------------------------------------------------------------------------------------------------------------

    Please "Accept the answer" if the information helped you. This will help us and others in the community as well.

    1 person found this answer helpful.

  2. Andriy Bilous 11,816 Reputation points MVP Volunteer Moderator
    2022-12-08T12:05:58.247+00:00

    Hello @Jackson Pedrini

    Here is a similar issue answered by me earlier. Please go through this and let us know if you still need more help with this.

    https://learn.microsoft.com/en-us/answers/questions/140197/unable-to-delete-vnet-due-to-serviceassociationlin.html

    If you think your question has been answered, click "Mark as Accept Answer" if just helped click "Vote as helpful". This can be beneficial to other community members reading this forum thread.


Your answer

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