# Disk

For the Azure, a disk can be a separate computing resource (created separately, billed separately, managed separately, etc.) and can be integrated into a VM as a component.

There are several special concepts in Azure's disk management, explained in advance:

  • Managed Disk: Hosted by Azure Public Store
  • Unmanaged disk: The disk can only be managed by the storage account under the account, not as an independent resource.
  • Storage account: Azure provides a storage account function, the so-called storage account, which is an entry that can manage the disk.

# Data Disk

We know that a data disk is different from the system disk and is mainly used to store data.

# Add Data Disk

  1. Login Azure Portal, select the VM and Stop it
  2. Open the Setting->Disks of Stopped VM, click the button "Add data disk" img
  3. Set the disk name,size and other information setting datadisk
  4. Connect to OS to initialize disk
  5. Finish adding data disk

# Detach Data Disk

  1. Login Azure Portal, select the VM and Stop it
  2. Open the Setting->Disks of Stopped VM
  3. Click the "Edit" on the top of Disks page img
  4. Then, click the detach icon like below img
  5. Once detach disk, please save it
  6. Start VM

The disk detach didn't deleted, it remain in the storage account

# Change Size

You can change the Size or change the Account type of Data Disk when the disk is not mounted to VM

img

In most times, the disk can only increase size, not reduce size.