You can resize a system disk or a data disk to extend its capacity. If your Windows Elastic Compute Service (ECS) instance does not support online resizing of disks, you can resize the disks on the instance offline. After you resize a disk on an instance offline, you must restart the instance for the change to take effect. The restart operation interrupts services that run on the instance for a short period of time. We recommend that you resize disks offline during off-peak hours.

Prerequisites

The requirements described in the following table are met before you can resize a disk offline for a Windows instance.
Resource Requirement
Instance
  • The instance is in the Running (Running) or Stopped (Stopped) state.
  • If the instance runs a Windows Server 2003 operating system, only data disks of the instance can be resized and the system disk cannot.
Disk
  • The disk is in the In Use (In Use) state.
  • The disk is an enhanced SSD (ESSD), a standard SSD, or an ultra disk.
  • The disk is formatted with a New Technology File System (NTFS) file system.
  • After you renew a subscription instance and downgrade its configurations, you cannot resize the subscription disks on the instance for the remainder of the current billing cycle.
  • When you resize a disk of a specific category, the specified new disk capacity cannot exceed the maximum single-disk capacity allowed for the disk category. For more information, see the "Elastic Block Storage (EBS) limits" section in Limits.
Notice
A disk in the master boot record (MBR) partition format cannot be resized to 2 TiB or larger. To resize an MBR disk to larger than 2 TiB, you can use one of the following methods:

Step 1: Create a snapshot

Before you resize a disk online, you must create a snapshot for the disk to back up the data stored in the disk.

  1. Log on to the ECS console.
  2. In the left-side navigation pane, choose Instances & Images > Instances.
  3. In the top navigation bar, select a region.
  4. Find the instance whose disk you want to resize and click the instance ID.
  5. On the Instance Details page, click the Cloud Disk tab.
  6. Find the disk that you want to resize and click Create Snapshot in the Actions column.
  7. In the Create Snapshot dialog box, enter a snapshot name, configure tags, and then click Create.
  8. Click the Snapshot tab to view the snapshot.
    When the snapshot is created, 100% appears in the Progress column that corresponds to the snapshot. You can proceed to perform subsequent operations.

Step 2: Resize the disk and start or restart the instance in the ECS console

  1. On the Instance Details page, click the Cloud Disk tab.
  2. Find the disk that you want to resize and choose More > Resize Disk in the Actions column.
    If you want to batch resize disks, log on to the ECS console by using your Alibaba Cloud account and choose Storage & Snapshots > Disks in the left-side navigation pane. On the Disks page, select the disks that you want to resize and click Resize Disk in the lower part of the page. Disks that are attached to the same instance cannot be resized together.
    Note Alibaba Cloud accounts are permitted to batch resize disks but Resource Access Management (RAM) users are not. Log on to the ECS console by using your Alibaba Cloud account.
  3. On the Resize Disks page, set the Size after Resize parameter.
    The specified Size after Resize value must be greater than the current disk capacity.
  4. Verify the price. Read and select ECS Service Terms, and then click Confirm.
  5. Read the notes, click I have read the notes. Resize, and then complete the payment.
  6. Start or restart the instance in the ECS console.
    Note
    • If your instance is in the Running (Running) state, you must restart the instance in the ECS console. If your instance is in the Stopped (Stopped) state, you must start the instance in the ECS console.
    • The disk resizing operation takes effect only after you start or restart the instance by using the console or by calling the RebootInstance operation. If you restart the instance from within the operating system, the disk resizing operation does not take effect.

    The following procedure describes how to restart an instance.

    1. In the left-side navigation pane, choose Instances & Images > Instances.
    2. On the Instances page, find the instance that you want to restart and choose More > Instance Status > Restart in the Actions column.
    3. In the Restart Instance dialog box, click OK.

Step 3: Resize the file system of the system disk or data disk partition

After you resize a disk of an instance in the ECS console, the file systems of the disk partitions are not resized. You must connect to the instance to extend the file systems. The system and data disks are resized from 40 GiB to 60 GiB and are formatted with NTFS file systems. The following steps describes how to resize the file system of a system disk partition.

  1. Log on to the instance. For more information, see Connect to a Windows instance by using a password or key.
  2. On the Windows Server desktop, right-click the Start icon and select Disk Management.
    Disk Management
  3. In the Disk Management dialog box, choose Action > Rescan Disks to view the unallocated disk capacity.
    caozuo1

    Disk 0 is the system disk and Disk 1 is a data disk.

  4. Right-click the blank space in the Disk 0 section and select Extend Volume...
    Note If you resize the file system of a data disk partition, right-click the blank space in the data disk (such as Disk 1) section. If your disk has multiple partitions, we recommend that you resize the partition that is adjacent to the left of the unallocated partition. Otherwise, Windows changes the selected basic disk into a dynamic disk.
    kuozhan
  5. Extend the volume as instructed in Extend Volume Wizard.
    The new space is automatically added to the original volume, as shown in the following figure. kuozhan2
    After the disk is resized, check whether the new capacity of the disk is consistent with the specified capacity.
    • If the file system size is increased to the specified value and business programs on the instance can run normally, the file system is resized.
    • If the file system size is not increased to the specified value, use the snapshot that you created in Step 1 to roll back the disk.

Step 4: (Optional) Create a partition on the data disk

If you want to create a partition in the new disk space, perform the following steps:

  1. Log on to the instance. For more information, see Connect to a Windows instance by using a password or key.
  2. On the Windows Server desktop, right-click the Start icon and select Disk Management.
  3. In the Disk Management dialog box, choose Action > Rescan Disks to view the unallocated disk capacity.
    caozuo1

    Disk 0 is the system disk and Disk 1 is a data disk.

  4. Right-click the blank space in the Disk 1 section and select New Simple Volume...
    jiandan1
  5. Extend the volume as instructed in New Simple Volume Wizard.
    A partition is created in the new disk space.