In Azure Portal->Dashboard->All Resources-> Check 'show hidden types' and make sure that no filters are applied. Check, if there are some resources as reported in the error message while deleting the PIP. Delete those, if listed there and try deleting the PIP again
Unable to delete public ip resource

HI,
I have a public ip resource got stuck in azure, getting following errros:
Failed to delete public IP address 'pip-agw-prod0-001'. Error: Public IP address rg-dms-prod0/providers/Microsoft.Network/publicIPAddresses/pip-agw-prod0-001'>pip-agw-prod0-001 can not be deleted since it is still allocated to resource Microsoft.Network/loadBalancers/appgwLoadBalancer/frontendIPConfigurations/appGwPublicFrontendIp001. In order to delete the public IP, disassociate/detach the Public IP address from the resource.
However, the associated resource is already deleted, there is no way for me to delete it myself.
Please help, thanks.
3 answers
Sort by: Most helpful
-
Manu Philip 14,361 Reputation points MVP
2021-07-12T19:16:56.29+00:00 Manu Philip 14,361 Reputation points MVP2021-07-12T19:48:09.457+00:00 Looks like a permission issue. To perform the deletion, you need to be at least a network contributor on the subscription level or on the needed resource level.
Manu Philip 14,361 Reputation points MVP2021-07-12T19:57:38.927+00:00 Have you tried from PS?
Remove-AzPublicIpAddress -Name $publicIpName -ResourceGroupName $rgName
Hi Jianhuang,
Can you try re-create the resource(exact same name and same resource group) and associate it with the Public IP? Then you can delete the resource first and delete the Public IP.
Hope this might be helpful.
Best Regards,
Wenjian Xu
hi Wenjian Xu,
I had contacted microsoft support, the the support engineer was able to delete the public ip for me in the back end. Thank you.
Jian