Kindly let us know if you need any further assistance on this issue from our end.
----------------------------------------------------------------------------------------------------------------
Thanks for the response
Below is the error message I am getting when I tried to delete the NIC
"error": {
"code": "NicInUse",
"message": "Network Interface /subscriptions/ef4b4581-7ba0-4490-94ee-f33d39fb61cb/resourceGroups/River-Dale/providers/Microsoft.Network/networkInterfaces/desktop729 is used by existing resource /subscriptions/ef4b4581-7ba0-4490-94ee-f33d39fb61cb/resourceGroups/River-Dale/providers/Microsoft.Compute/virtualMachines/Desktop. In order to delete the network interface, it must be dissociated from the resource. To learn more, see aka.ms/deletenic.",
"details": []
Power shell cmd: Get-AzVm -Name "Desktop" -ResourceGroupName "River-Dale"
PS /home/deepak> Get-AzVm -Name "Desktop" -ResourceGroupName "River-Dale"
Get-AzVM: The Resource 'Microsoft.Compute/virtualMachines/Desktop' under resource group 'River-Dale' was not found. For more details please go to
https://aka.ms/ARMResourceNotFoundFix
ErrorCode: ResourceNotFound
ErrorMessage: The Resource 'Microsoft.Compute/virtualMachines/Desktop' under resource group 'River-Dale' was not found. For more details please go to
https://aka.ms/ARMResourceNotFoundFix
ErrorTarget:
StatusCode: 404
ReasonPhrase: Not Found
OperationID : fa3c963a-9c71-46fb-9c64-1f553338c8c0
Thank you for the update
@Deepak sundaram
.
It looks like the VM is deleted but the NIC association is still in place and it may require an investigation from the backend team. Hence, if you have a support plan, I request you to file a support ticket, else please do let us know, we will try and help you get a one-time free technical support. In this case, could you send an email to azcommunity@microsoft.com referencing this thread as well as your subscription ID. Please mention "ATTN gishar" in the subject field.
Thank you for your cooperation on this matter and look forward to your reply.
"name": "Solution_Unit-vnet",
"id": "/subscriptions/7890e344-be6a-46e3-b94c-70a01769770c/resourceGroups/Solution_Unit/providers/Microsoft.Network/virtualNetworks/Solution_Unit-vnet",
"etag": "W/\"1f8a7af7-4469-453b-9d80-2801831f58ac\"",
"type": "Microsoft.Network/virtualNetworks",
"location": "eastus",
"tags": {},
"properties": {
"provisioningState": "Succeeded",
"resourceGuid": "f51ac8d2-9a8d-4730-ab9f-bb273b85f863",
"addressSpace": {
"addressPrefixes": [
"10.0.0.0/24",
"(String)"
"subnets": [
"name": "default",
"id": "/subscriptions/7890e344-be6a-46e3-b94c-70a01769770c/resourceGroups/Solution_Unit/providers/Microsoft.Network/virtualNetworks/Solution_Unit-vnet/subnets/default",
"etag": "W/\"1f8a7af7-4469-453b-9d80-2801831f58ac\"",
"properties": {
"provisioningState": "Succeeded",
"addressPrefix": "10.0.0.0/24",
"serviceAssociationLinks": [
"name": "default-service-association-link",
"id": "/subscriptions/7890e344-be6a-46e3-b94c-70a01769770c/resourceGroups/Solution_Unit/providers/Microsoft.Network/virtualNetworks/Solution_Unit-vnet/subnets/default/serviceAssociationLinks/default-service-association-link",
"etag": "W/\"1f8a7af7-4469-453b-9d80-2801831f58ac\"",
"type": "Microsoft.Network/virtualNetworks/subnets/serviceAssociationLinks",
"properties": {
"provisioningState": "Succeeded",
"linkedResourceType": "",
"enabledForArmDeployments": false,
"allowDelete": false,
"locations": []
"serviceEndpoints": [],
"delegations": [
"name": "Microsoft.DBforMySQL.flexibleServers",
"id": "/subscriptions/7890e344-be6a-46e3-b94c-70a01769770c/resourceGroups/Solution_Unit/providers/Microsoft.Network/virtualNetworks/Solution_Unit-vnet/subnets/default/delegations/Microsoft.DBforMySQL.flexibleServers",
"etag": "W/\"1f8a7af7-4469-453b-9d80-2801831f58ac\"",
"properties": {
"provisioningState": "Succeeded",
"serviceName": "",
"actions": [
"Microsoft.Network/virtualNetworks/subnets/join/action"
"type": "Microsoft.Network/virtualNetworks/subnets/delegations"
"privateEndpointNetworkPolicies": "Disabled",
"privateLinkServiceNetworkPolicies": "Enabled"
"type": "Microsoft.Network/virtualNetworks/subnets"
"id": "(String)",
"properties": {
"addressPrefix": {},
"addressPrefixes": {},
"networkSecurityGroup": {},
"routeTable": {},
"natGateway": {},
"serviceEndpoints": {},
"serviceEndpointPolicies": {},
"privateEndpoints": {},
"ipConfigurations": {},
"ipConfigurationProfiles": {},
"ipAllocations": {},
"resourceNavigationLinks": {},
"serviceAssociationLinks": {},
"delegations": {},
"purpose": {},
"provisioningState": {},
"privateEndpointNetworkPolicies": {},
"privateLinkServiceNetworkPolicies": {},
"applicationGatewayIpConfigurations": {}
"name": "(String)",
"etag": "(String)",
"type": "(String)"
"virtualNetworkPeerings": [
"id": "(String)",
"properties": {
"allowVirtualNetworkAccess": {},
"allowForwardedTraffic": {},
"allowGatewayTransit": {},
"useRemoteGateways": {},
"remoteVirtualNetwork": {},
"remoteAddressSpace": {},
"remoteVirtualNetworkAddressSpace": {},
"remoteBgpCommunities": {},
"peeringState": {},
"peeringSyncLevel": {},
"provisioningState": {},
"doNotVerifyRemoteGateways": {},
"resourceGuid": {}
"name": "(String)",
"etag": "(String)",
"type": "(String)"
"enableDdosProtection": false,
"dhcpOptions": {
"dnsServers": [
"(String)"
"flowTimeoutInMinutes": "(Integer)",
"enableVmProtection": "(Boolean)",
"ddosProtectionPlan": {
"id": "(String)"
"bgpCommunities": {
"virtualNetworkCommunity": "(String)",
"regionalCommunity": "(String)"
"ipAllocations": [
"id": "(String)"
"extendedLocation": {
"name": "(String)",
"type": "(String)"
After trying to delete it getting the below error.
"error": {
"code": "InUseSubnetCannotBeDeleted",
"message": "Subnet default is in use by /subscriptions/7890e344-be6a-46e3-b94c-70a01769770c/resourceGroups/Solution_Unit/providers/Microsoft.Network/virtualNetworks/Solution_Unit-vnet/subnets/default/serviceAssociationLinks/default-service-association-link and cannot be deleted. In order to delete the subnet, delete all the resources within the subnet. See aka.ms/deletesubnet.",
"details": []
Hello
@Deepak Bhardwaj
,
I have added the below comment to your original post:
It looks like your subnet still has a delegation to "Microsoft.DBforMySQL.flexibleServers".
I would request you to try and remove the subnet delegation by following the steps in the below article:
https://learn.microsoft.com/en-us/azure/virtual-network/manage-subnet-delegation#remove-subnet-delegation-from-an-azure-service
If that doesn't help, we may need to raise a support ticket to get the Service Association Link (SAL) deleted from the backend as this is a known issue from MySQL server.
So if you have a support plan, I request you file a support ticket, else please do let us know, we will try and help you get a one-time free technical support.
Regards,