How to Add and Initialize a Data Disk in a Windows 11 VM on Azure


When creating a Windows 11 Virtual Machine (VM) on Azure, you may need to attach a data disk to store additional files and applications separately from the operating system disk. This guide walks you through adding and initializing a data disk at the time of VM creation.
It is important to know that there is a difference between an (operating system) OS disk and a data disk. Azure documentation explains that every virtual machine is equipped with a single (operating system) OS disk that is directly attached to it. This disk comes with a pre-installed operating system that was chosen during the creation of the virtual machine. It serves as the primary storage for the boot volume, essential for initiating the system. On the other hand, data disk is a managed disk that is attached to a virtual machine to store application data or other data you need to keep.
STEP 1: CREATE A WINDOWS 11 VM WITH A DATA DISK Sign in to Azure Portal
Go to Azure Portal and log in with your credentials. Navigate to Virtual Machines
Click Create a resource > Virtual Machine. Choose Windows 11 as the image for your VM. Configure the Basic Settings
Enter a Virtual Machine Name. Select a Region and Size based on your needs. Configure Authentication (Username and Password). Also choose the connection type to be RDP.
Go to the "Disks" TabUnder the OS disk type, select your preferred storage type (e.g., Premium SSD, Standard SSD). Scroll to Data Disks and click Create and Attach a New Disk. Configure the Data Disk
Create a new Data Disk
Enter a Disk Name. Choose Storage Type (Premium SSD, Standard SSD, or Standard HDD). Select Size based on your storage requirements.
Configure your Networking and other requirement, then Click Review + Create and then Create to deploy your VM.
STEP 2: INITIALIZE THE DATA DISK IN WINDOWS 11
Once the VM is deployed, you must initialize and format the newly attached data disk within Windows 11.
Connect to the VM
Go to Azure Portal > Virtual Machines.
Select your VM and click Connect (with RDP).
Log in using your credentials.
Open Disk Management
Right Click on the Windows button on your VM’s Home screen and select Disk Management OR
Press Win + X and select Disk Management OR
Search for RUN on you window dialogue box and type diskmgmt.msc
The new disk should appear as Unallocated.
- Click ok
Initialize the Disk
Right-click the unallocated disk and choose Initialize Disk.
Select GPT (GUID Partition Table) as the partition style.
Click OK.
Create a New Volume
Right-click the unallocated space and select New Simple Volume.
Follow the wizard to assign a drive letter, choose a file system (NTFS recommended), and format the disk.
Click Finish to complete the setup.
Verify the Disk
Open File Explorer to confirm that the new disk is available and ready for use.
CONCLUSION
By following these steps, you can successfully add and initialize a data disk while creating a Windows 11 VM on Azure. This ensures your additional storage is immediately available for use, streamlining data management for your virtual machine.
For further custom configurations, you can explore Azure Disk Encryption, Backup Options, and Performance Optimization Settings in the Azure Portal.
Subscribe to my newsletter
Read articles from Bukunmi Samson Okunola directly inside your inbox. Subscribe to the newsletter, and don't miss out.
Written by
