Unlock Limitless Possibilities: Supercharge Your Azure Virtual Machine with Additional Disk Space!
Tags: devops, cloud, azure, help
Published: 2023-08-28 20:52:33

When you create a new virtual machine in Azure, it typically comes with at least one disk, which is the operating system (OS) disk. The OS disk contains the operating system and associated files necessary for the virtual machine to run. However, by default, a new virtual machine does not come with an attached data disk.

If you need additional storage space for your virtual machine beyond what the OS disk provides, you would need to add a separate data disk. Data disks are used to store data, applications, files, and other information. They can be attached to a virtual machine to provide extra storage capacity and help improve performance, especially for scenarios that involve a lot of data processing or storage.

So, while a new virtual machine includes an OS disk by default, any additional data disks need to be added manually.

The Steps involved in adding a data disk to a virtual machine are highlighted below.

Once a Virtual Machine has been created, you can go ahead and add a data disk

**1. The Virtual machine named "SamVm" has just been created.** 

a. Open the Virtual Machine's overview to display all the information about it.

b. Select "Disks" and click "Create and attach a new disk". **You can either create and attach a new disk or attach an existing disk**

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/wy2zr5g8m5v8o4mg5hyw.png)
2. Properly configuring and managing **_LUNs_**, **_naming disks_** descriptively, understanding and meeting _**IOPS**_ needs, and selecting appropriate _**storage types**_ can lead to better resource utilization, improved application performance, and streamlined management of your virtual machine storage.

Considering these factors collectively can significantly impact the performance, scalability, and efficiency of your virtual machine environment. 


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0qygi41et1zpcqbshazr.png)

3. Once all the parameters above have been properly configured, Click **"Save"**


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/gjb7as6do3vm2wmz69pe.png)

4. Connect the Vm via the local RDP


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/1b6d3b37sf688x0lvw0i.png)

5. Download the RDP file


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/p25ninslkizonm8lvnkk.png)

6. Save the RDP file on your local PC


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ul7vnh5kbp5atg48nds0.png)

7. Click on Connect on the Remote Desktop Protocol(RDP) pop-up.


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0vtwrnavl11c6zfvdb94.png)

8. Enter the Administrator's details; username and password.


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/h4npeycr9g6r3m8i3rai.png)

9. Click **_YES_**


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9ngms9rjmmi2xse4txsg.png)

10. The Virtual machine is fully created and connected.


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/a6xnrlwdfaeay53belkp.png)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/d88h9zfw9aiuqizzc1ja.png)


11. Format and configure the storage for the new Virtual machine.

a. Check the GPT (GUID Partition Table) and click OK


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/wg8mbfp97qzv0vzugtju.png)

Checking the **GPT (GUID Partition Table)** option while configuring disks in a new virtual machine is an important decision that affects how your **storage is organized and managed**.

 The choice between using **GPT or MBR** (Master Boot Record) for partitioning your disks has significant implications for your virtual machine's **performance, scalability, and compatibility**. 

**Advantages of checking GPT over MBR**

**a. Disk Capacity Utilization:**

GPT supports larger disk capacities compared to MBR. If you're using large virtual disks or have plans to scale up your storage needs, GPT is essential to ensure that you can fully utilize the available space without limitations.

**b. Support for More Partitions:**

GPT allows for a larger number of primary partitions compared to MBR. This is beneficial if your virtual machine requires multiple partitions, such as separate partitions for the operating system, data, and applications.

**c. UEFI Compatibility:**

GPT is the recommended partitioning scheme for modern systems using UEFI (Unified Extensible Firmware Interface) instead of the traditional BIOS. UEFI provides improved security, faster boot times, and support for larger disks.

**d. Data Integrity and Redundancy:**

GPT includes a backup of the partition table at the end of the disk, enhancing data recovery in case of corruption or errors in the primary table. This redundancy contributes to data integrity and reliability.

**e. Security and Protection:**

GPT includes a feature called "Protective MBR" that helps prevent older, MBR-based utilities from accidentally damaging or overwriting GPT disks.

**f. Compatibility with Modern Operating Systems:**

GPT is better suited for modern operating systems, including recent versions of Windows, Linux, and macOS. If you plan to install or migrate to newer OS versions, GPT is the more compatible choice.

**g. Alignment and Performance:**

GPT partitions are aligned more optimally on modern storage devices, leading to potential performance improvements, especially on SSDs and advanced storage technologies.

12. The Data Disk has 32G unallocated storage. Right-click on the unallocated storage to configure the **"New Simple Volume"**


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/57bt5nalseix595s8fyh.png)

Follow the **"New Simple Volume"** Wizard until **Finish**


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xxiozq6hr1ytcvu0jrtl.png)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/a8c36g5nwq1ov8xtx9g8.png)

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/7kyux23vx1l3kjc89wyw.png)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/5k50vcv9vm6zd4lw5iwa.png)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jntwog1lc2uwhqoc70qk.png)

A brand new Disk named G with 32G storage space has been successfully added to the new Virtual Machine.  


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/e6xsegs4ien3cs0ob6om.png)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9qh3tluld3p7yxvvxtrk.png)



![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9ivxureo5xt91mm4at4f.png)

In conclusion, with this step-by-step guide, I have officially added a massive 32GB Data Disk to my brand-new virtual machine, setting the stage for limitless scalability and performance.