Space on VM

Justine Yamane 0 Reputation points
2026-06-16T20:48:46.5633333+00:00

How do I see how much storage I have used in the virtual machine?

Azure Disk Storage
Azure Disk Storage

A high-performance, durable block storage designed to be used with Azure Virtual Machines and Azure VMware Solution.


3 answers

Sort by: Most helpful
  1. Anonymous
    2026-06-16T22:16:44.8366667+00:00

    Hello Justine,

    To check how much storage space is being used on your Azure VM, you can check it directly from the VM or use Azure Monitor if you want to keep track of disk usage regularly.

    If this is a Windows VM, you can check the available and used space by connecting to the VM through RDP and opening: File Explorer → This PC

    You will see all the drives with the total size, used space, and free space available.

    You can also check it using PowerShell: Get-PSDrive -PSProvider FileSystem

    This will show the disk usage details for the VM drives.

    For a Linux VM, connect to the VM using SSH and run: df -h

    This will show the disk capacity, used space, and available free space.

    If you are looking for continuous monitoring or want to get alerts when the disk space is running low, Azure Monitor for Virtual Machines can help with this.

    You can use the below KQL query in Azure Monitor → Logs to check free disk space:

    
    InsightsMetrics
    | where Computer in ("DC10.na.contosohotels.com") // Windows
    | where Namespace == "LogicalDisk"
    | where Name == "FreeSpacePercentage"
    | extend Disk=tostring(todynamic(Tags)["vm.azm.ms/mountId"])
    | summarize arg_max(TimeGenerated, *) by Disk, Computer
    | project TimeGenerated, Disk, Computer, Val
    | where Val > 90
    

    Please replace Your_VM_Name with your VM name. This will return the latest free space percentage for the disks monitored by Azure Monitor.

    If you want to configure alerts:

    Open Azure Portal → Virtual Machines

    Select your VM

    Go to Monitoring → Alerts

    Create a new alert rule

    Select the disk usage metric

    Configure the threshold (for example, alert when disk usage reaches 90%)

    Add an Action Group to receive notifications

    This way, you don't need to manually check the disk space every time. Azure will notify you when the disk is close to running out of space.

    You can refer to the below Microsoft documentation for more details:

    Azure Monitor VM Insights overview: Azure Monitor VM Insights documentation

    Expand Azure VM managed disk when more storage is required: Expand Azure managed disk documentation

    Reference thread: https://learn.microsoft.com/en-us/answers/questions/2263855/disk-c-is-full-on-an-azure-vm

    Was this answer helpful?

    0 comments No comments

  2. Jose Benjamin Solis Nolasco 12,281 Reputation points Volunteer Moderator
    2026-06-16T21:32:48.8966667+00:00

    Welcome to Microsoft Q&A

    Hello @Justine Yamane I hope you are doing well,

    Method 1: Operating System Level (Direct)

    The fastest and most accurate way to check disk space is to log directly into the Virtual Machine, as the guest OS manages the file system natively.

    For Windows VMs: Connect via RDP or Bastion. Open File Explorer and click on This PC to view the capacity and used space of your C:\ drive and any attached data disks.

    For Linux VMs: Connect via SSH or Bastion. Execute the command df -h in the terminal to view human-readable disk space usage across all mounted file systems.

    Method 2: Azure Monitor & VM Insights (At Scale)

    If you want to view disk space from the Azure Portal without logging into the VM, you must enable Guest-level monitoring.

    Navigate to your Virtual Machine in the Azure Portal.

    Scroll down the left menu to the Monitoring section and select Insights.

    If not already configured, click Enable to install the Azure Monitor Agent (AMA).

    Once data is flowing, click the Performance tab within VM Insights.

    1. In the metric dropdown, select Logical Disk Space Used %. This will display the exact volume utilization from the perspective of the guest OS.

    😊 If my answer helped you resolve your issue, please consider marking it as the correct answer. This helps others in the community find solutions more easily. Thanks!

    Was this answer helpful?


  3. AI answer

    2026-06-16T20:48:53.5333333+00:00

    On a Windows virtual machine, storage usage can be checked from within the guest OS just like on a physical PC:

    1. Right-click Start and select Settings.
    2. Go to System > Storage.
    3. View Storage to see how much space is used and free on the OS disk.
    4. If there are multiple disks, select Advanced storage settings > Storage used on other drives to see usage per drive.

    For more detailed system information, use the tools described in System configuration tools in Windows from the same article.


    References:

    AI-generated content may be incorrect. Read our transparency notes for more information.

    Was this answer helpful?

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.