Increase Data Disk Size In Azure

Introduction

Retaining data in the same VM requires us to increase the disk space when the utilization of allocated space is full. Increasing the disk space in Azure is quite easy with a few clicks.

There may be some challenges faced by the administrators if the desired details are not provided. For example, the VM owner would need to increase the size of the data disk, but not be aware about the details which need to be provided or how these can be gathered. So the request would be “Increase the E drive space with 500 GB.” This creates a difficult situation for the Azure administrators, as they must find out the exact disk when the VM has multiple data disks.

There are 2 phases involved in increasing the disk space.

  • Identifying the Disk
  • Increasing the Disk Space

IDENTIFYING THE DISK

Step 1

Disk

  • Log in to the Azure VM.
  • Open the “Device Manager” and expand ‘Disk drives’.

2 types of disk drives will be displayed.

  • “Virtual HD ATA Device”: These are the OS drives and the temporary drives.
  • “Msft Virtual Disk SCSI Disk Device”: These are the Data disk drives.

Right-click on the “Data Disk Drives” and open properties.

Step 2. Note LUN Value.

LUN Value

In the ‘General’ Tab of the disk property, note the Location (Specifically LUN value).

Step 3. Note Volume Label (Drive Name).

Volume Label

  • Select the ‘Volumes’ tab.
  • Initially, the values for each volume will be empty. Click Populate to see the Volume details of the selected drive.
    Volumes
  • Note the Volume Label (drive name) from the displayed result.

Once the LUN value and the Volume Label (Drive name) is noted, shut down the virtual machine.

From the above steps, we understand the ‘E Drive’ is associated with the Data disk with the LUN value ‘0’.

The Drive Label will not be available in the Azure portal. Hence the disk identification will be through the LUN value.

INCREASING THE DISK SPACE

DISK SPACE

  • Login to Azure Portal.
  • Navigate to the Virtual Machines page in Azure Portal.

Here we can see that the VM is in a Stopped state, which means that the VM is turned off through the Power Option available in the VM.

Power Option

Increasing the Disk space requires the VM to be in a “deallocated” state. Shutting down the VM through the VM’s power option will put the VM in the Stopped state. In order to deallocate the VM, ‘Stop’ the VM from the Azure portal.

Deallocated

  • Select “Stop” from the VM’s Overview pane.
  • Confirm the VM stop by selecting ‘Yes’.
    Yes
    Virtual machine
  • Once the stop request is successfully completed, we can see the VM status as “Stopped (deallocated)”.
    VM status
  • Select “Disks” from the VM settings.
  • Click on the Data disk which has the LUN value as “0”.
    VM Setting
  • Specify the total size (Existing + additional) in GB.
  • Click “Save”.
    Save
  • Azure Portal will notify the status of the request.
     Status
  • Once the successful notification is displayed, we shall check the increased size in the Disk tab of the VM Settings.
    VM Settings
  • Start the VM from the Azure Portal.
    Azure Portal
  • Login to the VM and navigate to Disk Management.
  • Here we shall see the newly added space in the respective disk.
  • Right-click on the Disk and select “Extend Volume”.
    Extend Volume
  • Click ‘Next’ in the Welcome window of the Extend Volume Wizard
    Volume Wizard
  • By default, the allocated space on the disk will be selected.

Modify the value of “Select the amount of space in MB” if you wish to have some allocated space to be utilized in the future.

Allocated Space

Click Finish on the Completion Window of the Extend Volume Wizard.

Azure

The newly increased space is allocated with the existing disk space.

Summary

In this article, I have explained about increasing the disk space through the Azure Portal.

Below are the highlights that need to be considered while increasing the Disk space.

  1. The Virtual Machine should be in a “deallocated” state.
  2. Increased space should be included in the primary partition by extending the volume on the respective disk.
  3. The Disk shouldn’t be detached during this process, as detaching the disk might result in formatting the disk which in turn leads to data loss.


Similar Articles