Shrink a Basic Volume
Applies To: Windows Server 2008, Windows Vista
You can decrease the space used by primary partitions and logical drives by shrinking them into adjacent, contiguous space on the same disk. For example, if you discover that you need an additional partition but do not have additional disks, you can shrink the existing partition from the end of the volume to create new unallocated space that can then be used for a new partition.
When you shrink a partition, any ordinary files are automatically relocated on the disk to create the new unallocated space. There is no need to reformat the disk to shrink the partition.
Backup Operator or Administrator is the minimum membership required to complete the actions below.
Warning
If the partition is a raw partition (that is, one without a file system) that contains data (such as a database file), shrinking the partition may destroy the data.
Shrinking a basic volume
Using the Windows interface
Using a command line
To shrink a basic volume using the Windows interface
In Disk Manager, right-click the basic volume you want to shrink.
Click Shrink Volumeā¦.
Follow the instructions on your screen.
Note
You can only shrink basic volumes that have no file system or use the NTFS file system.
Additional considerations
When you shrink a partition, unmovable files (for example, the page file or the shadow copy storage area) are not automatically relocated and you can not decrease the allocated space beyond the point where the unmovable files are located. If you need to shrink the partition further, see move the page file to another disk, delete the stored shadow copies, shrink the volume, and then move the page file back to the disk.
If the number of bad clusters detected by dynamic bad-cluster remapping is too great, you cannot shrink the partition. If this occurs, you should consider moving the data and replacing the disk.
Do not use a block-level copy to transfer the data. This will also copy the bad sector table and the new disk will treat the same sectors as bad even though they are normal.
You can shrink primary partitions and logical drives on raw partitions (those without a file system) or partitions using the NTFS file system.
To shrink a basic volume using a command line
Open a command prompt and type
diskpart
.At the DISKPART prompt, type
list volume
. Make note of the number of the simple volume you want to shrink.At the DISKPART prompt, type
select volume <volumenumber>
. Selects the simple volume volumenumber you want to shrink.At the DISKPART prompt, type
shrink [desired=<desiredsize>] [minimum=<minimumsize>]
. Shrinks the selected volume to desiredsize in megabytes (MB) is possible, or to minimumsize if desiredsize is too large.
Value | Description |
---|---|
list volume |
Displays a list of basic and dynamic volumes on all disks. |
select volume |
Selects the specified volume, where volumenumber is the volume number, and gives it focus. If no volume is specified, the select command lists the current volume with focus. You can specify the volume by number, drive letter, or mount point path. On a basic disk, selecting a volume also gives the corresponding partition focus. |
shrink |
Shrinks the volume with focus to create unallocated space. No data loss occurs. If the partition includes unmovable files (such as the page file or the shadow copy storage area), the volume will shrink to the point where the unmovable files are located. |
desired=desiredsize |
The amount of space, in megabytes (MB) to recover to the current partition. |
minimum=minimumsize |
The minimum amount of space, in megabytes (MB), to recover to the current partition. If you do not specify a desired or minimum size, the command will reclaim the maximum amount of space possible. |
Additional considerations
When you shrink a partition, unmovable files (for example, the page file or the shadow copy storage area) are not automatically relocated and you cannot decrease the allocated space beyond the point where the unmovable files are located. If you need to shrink the partition further, see move the page file to another disk, delete the stored shadow copies, shrink the volume, and then move the page file back to the disk.
If the number of bad clusters detected by dynamic bad-cluster remapping is too great, you cannot shrink the partition. If this occurs, you should consider moving the data and replacing the disk.
Do not use a block-level copy to transfer the data. This will also copy the bad sector table and the new disk will treat the same sectors as bad even though they are normal.
You can shrink primary partitions and logical drives on raw partitions (those without a file system) or partitions using the NTFS file system.