AWS/Azure/OpenShift

Remove Azure VM: How to delete a Virtual Machine via the Azure Portal

Azure Portal

Azure Virtual Machines (VM) is one of several types of on-demand, scalable computing resources that Azure offers. An Azure VM gives you the flexibility of virtualization without having to buy and maintain the physical hardware that runs it. In this guide, I will be showing you how to delete a virtual machine (VM) if you no longer need it. Please see How to use the built-in Azure Active Directory Connect tool, Azure VM Backup: Easy Steps from VM Settings, and Install and configure Ansible on Azure Virtual Machine.

Azure Virtual Machines gives you the flexibility of virtualization for a wide range of computing solutions with support for Linux, Windows Server, SQL Server, Oracle, IBM, SAP, and more. All current-generation Virtual Machines include load balancing and auto-scaling at no cost. 

Kindly refer to these related guides: How to use the Azure Cloud Shell, Azure CLI, and Azure PowerShell, how to uninstall Azure AD Connect, and how to configure Azure Monitor for VMs on Azure Stack Hub.

Method 1: Delete a Virtual Machine via the Azure Portal

You can remove an Azure Virtual Machine using the Azure portal as shown below. This is the easiest way to remove a VM from Azure.

Login to https://portal.azure.com/ and search for Azure Virtual Machines. As you can see below, this is already clearly visible under the list of Azure Services. Moreover, I will proceed and click on it.

Delete Virtual Machine

Furthermore, Upon clicking on “Virtual Machine,” this will reveal a list of VMs that are created and available within your Azure subscription. As you can see below, this will show the VM name, Type, Status, Size, Operating System, ResourceGroup, and Location, etc.

To delete a specific VM, kindly check the button close to the VM as shown in the image below and click on delete. This will walk you through the process of deleting your VM.

Now in the Delete Resources window, type Yes in the Confirm delete option and then select the Delete button.

Remove Azure VM

Method 2: Delete Azure Virtual Machine

However, If you aren’t so careful with the method described above, you may click on a different VM and have it deleted. Nonetheless, I have seen customers complain about this. To avoid this error, I have decided to show you a different method on how to delete your VM in Azure.

Here are some more interesting guides: How to prepare Azure and on-premises virtual networks using Azure CLI commands, how to setup Veeam Backup for Microsoft Azure [Part 1], and how to create, list, lock, deploy and delete Azure Resource Group via Azure CLI.

Click on the Virtual Machine, this will open the Azure Virtual Machine Overview blade. Next, click on the Delete button as shown below.

In this method, we are sure we are on the right VM and can proceed to have it deleted.

How to

Upon accessing the delete resources window, you’ll observe that it doesn’t pre-select all resources for removal. Therefore, you can choose which resources you want to retain or delete, including the option to keep valuable assets intact.

However, Paying close attention to the confirmation query presented is crucial to ensure a deliberate choice in managing your resources. Mainly when aiming to delete a Virtual Machine via the Azure Portal.

Azure Portal

As you can see, the VM is currently being deleted!

Screenshot-2021-12-02-at-16.58.44

The process to delete a Virtual Machine via the Azure Portal has been completed successfully, as demonstrated below.

Screenshot-2021-12-02-at-16.59.09

Nonetheless, As you can see below, the Virtual Machine has vanished. It is no longer present in the list of available VMs in Azure.

Screenshot-2021-12-02-at-16.59.36

Bulk delete a VM

The process of how to delete a Virtual Machine via the Azure Portal is equally uncomplicated. Just mark the VMs you intend to remove. In the example below, I display a lone screenshot.

Furthermore, If your environment houses numerous VMs you want to delete them collectively. Click the button adjacent to the Virtual Machines and opt to “delete a Virtual Machine via the Azure Portal”.

Screenshot-2021-12-02-at-16.55.53

I trust you discovered this blog post to be informative. Feel free to ask in the comment section if you have any inquiries. We’re here to assist you in your journey to delete a Virtual Machine via the Azure Portal.

Subscribe
Notify of
guest

0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x