After you attach a new data disk (empty data disk) to a Windows Elastic Compute Service (ECS) instance, you cannot directly use the disk to store data. To use the disk, you must initialize the disk for the Windows operating system to recognize the disk. If the size of the data disk does not exceed 2 TiB and you want to store and manage data of various categories in different partitions, you can perform the initialization operations in this topic. The initialization operations include partitioning the disk and mounting file systems on the disk.
Only new data disks (empty data disks) can be initialized. For more information, see the Scenarios section of the "Overview" topic.
Prerequisites
A data disk is attached to a Linux ECS instance. For more information, see Attach a data disk.
Background information
In the examples, an ECS instance and a data disk that have the configurations described in the following table are used. Operations may vary based on the actual condition.
Operating system | Resource | Description |
Windows | Image used by the instance | Windows Server 2016 64-bit |
Data disk |
|
Procedure
Connect to the ECS instance.
For more information, see Connect to a Windows instance by using a password or key.
On the Windows desktop, right-click the icon and select Disk Management.
Find the data disk in the Offline state that you want to initialize. In this example, Disk 1 is used.
Right-click a blank area around Disk 1 and select Online.
When Disk 1 comes online, the disk enters the Not Initialized state.
Right-click a blank area around Disk 1 and select Initialize Disk.
In the Initialize Disk dialog box, select the disk, select a disk partition format, and then click OK.
ImportantThe size of a disk that uses the master boot record (MBR) partition format is capped at 2 TiB. If your disk is larger than 2 TiB in size or the disk may be resized to larger than 2 TiB, use the GUID partition table (GPT) partition format.
Right-click the Unallocated section of Disk 1 and select New Simple Volume.
In the New Simple Volume Wizard window, click Next and follow the wizard to perform initialization operations.
In the Specify Volume Size step, configure the Simple volume size in MB parameter and then click Next.
If you want to create only a single primary partition on the disk, use the default value. You can also specify a simple volume size based on your business requirements to divide Disk 1 into multiple partitions.
In the Assign Drive Letter or Path step, select Assign the following drive letter, select a drive letter, and then click Next. In this example, the drive letter D is selected.
In the Format Partition step, select Format this volume with the following settings, configure formatting settings, and then click Next.
View the information about the new simple volume and click Finish to close the New Simple Volume Wizard window.
Result
The following figure shows the state of Disk 1 in the Disk Management window after the disk is initialized.
In This PC, you can find a new drive named New Volume (D:). The data disk is ready for use.
References
If your disk is larger than 2 TiB in size and you want to store and manage data of various categories in different partitions, initialize the disk. For more information, see the Initialize a data disk that is larger than 2 TiB on a Windows instance section of the "Initialize a data disk whose size exceeds 2 TiB" topic.
If you want to use a disk as a raw disk without partitioning the disk, you need to only create a file system on the raw disk during the initialization process. For more information, see Create a file system on a raw disk.
If the storage space of a disk is insufficient, you can extend the capacity of the disk to increase the storage space. For more information, see Overview.