Alessandro walks you through
expanding the root volume of
an EC2 instance running Windows

expand-ebs-root-volume-windows-alessandro

I have run out of space on my Amazon Elastic Compute Cloud (Amazon EC2) Windows instance. How can I dynamically expand the Amazon Elastic Block Store (Amazon EBS) volumes of my Windows instances?

By default, you have 30 GB gp2 (General Purpose SSD) Amazon EBS volume as a root volume when using an Amazon EC2 Windows instance from an Amazon AMI.

Expand the root volume using the Amazon EC2 console

1.    From the Amazon EC2 console, choose Instances from the left navigation pane.

2.    Choose the instance you want to expand, choose the Description tab, and then choose the volume listed for Block devices.

3.    Choose the EBS ID.

4.    Choose the volume, choose Actions, and then choose Modify Volume.

5.    Choose the Volume Type, enter the Size, and, in the case of an io1 volume, enter the desired Iops, choose Modify, and then choose Yes.

6.    Refresh the console page. The expanded volume is immediately available for the OS. You can check this by choosing the Description tab, and choosing the information icon next to the State. This shows the Original Size and the Target Size. Note: Windows root volumes are the Master Boot Record (MBR) by default, and they can be extended up to 2TB. See Amazon EBS Volume Types for other considerations.

7.    Open the remote desktop protocol (RDP) session for the instance, launch the Disk Management view by using the diskmgmt.msc command, choose Action, and then choose Refresh.

8.    Open the context (right-click) menu, and then choose Extend Volume.

9.    Accept the default options by choosing Next, and then choosing Finish.

10.    Perform these steps for any additional volumes.

Expand the root volume using the AWS CLI

You can also perform these steps by using the AWS Command Line Interface (AWS CLI):

1.    Run a command similar to the following:

ec2-modify-volume-attribute --volume <volumeId> --size <newSize> --iops <newIops> --type <newType> 

2.    Check the progress of your task using a command similar to the following:

ec2-describe-volumes --volume <volumeId> 

The expanded volume is immediately available.

3.    Use the diskmgmt.msc command to open the RDP session for the instance in Disk Manager view, choose Action, and then choose Refresh.

4.    Open the context (right-click) menu, and choose Extend Volume.

5.    Confirm the task is complete by running a command similar to the following:

ec2-describe-volumes --volume <volumeId> 

Did this page help you? Yes | No

Back to the AWS Support Knowledge Center

Need help? Visit the AWS Support Center

Published: 2016-08-17

Updated: 2018-08-31