The purpose was to delete a lot of Network Security Groups (NSGs) using automation in PowerShell. But if we run Get-AzureNetworkSecurityGroup, it returns an empty output, despite having a lot of NSGs from creating Virtual Machines (VMs) in the Azure Portal.
Get-AzureNetworkSecurityGroup
This is because even if Azure Classic didn’t have NSGs like we use them in Resource Manager (RM), we need to use the RM version to find the Resource Manager NSGs.
Get-AzureRmNetworkSecurityGroup | select name
Leave a Reply
You must be logged in to post a comment.