
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Delete All Tags of Azure Resource Using PowerShell
To delete all the tags of the Azure VM using PowerShell, we need to use the Remove-AZTag command.
To delete the azure resource tags, we need its resource ID but before that, it is always better to take azure resource tags backup. You can search the question on the TutorialPoints site or google,
Site − TutorialsPoint.com How to Export the Azure VM tags using PowerShell?
To delete the azure Resource Tags,
PS C:\> $vm = Get-AzVM -Name Testmachine2k16 PS C:\> Remove-AzTag -ResourceId $vm.Id -Verbose
To remove the azure resourceGroup tags,
PS C:\> $rg = Get-AzResourceGroup AnsibleTestRG PS C:\> Remove-AzTag -ResourceId $rg.ResourceId -Verbose
To remove the individual tag, you can directly apply the tag name but be cautious as it will remove the given tag name across all the subscriptions.
The below command will remove the tag from the entire subscription if it is not associated with multiple resources.
Remove-AzTag -Name 'Owner' -Value 'Chirag' -Verbose
If you have done something wrong while removing tags and if you have already a TAGS backup, you can search on the google article to import the tags again.
Site − TutorialsPoint.com How to import tags in Azure?