text
stringlengths
0
4.23k
Parameters
Parameter
Description
file=<full path>
Specifies the full path and file name of an existing VHD file.
noerr
Used for scripting only. When an error is encountered, DiskPart continues to process commands as if the error did not occur. Without this parameter, an error causes DiskPart to exit with an error code.
<full path>
Examples
To shift the focus to the VHD named c:\test\test.vhd, type:
select vdisk file=c:\test\test.vhd
select volume
Applies to: Windows Server 2022, Windows Server 2019, Windows Server 2016, Windows Server 2012 R2, Windows Server 2012
Selects the specified volume and shifts the focus to it. This command can also be used to display the volume that currently has the focus in the selected disk.
Syntax
select volume={<n>|<d>}
Parameters
Parameter
Description
<n>
The number of the volume to receive the focus. You can view the numbers for all volumes on the disk currently selected by using the list volume command in DiskPart.
<d>
The drive letter or mount point path of the volume to receive the focus.
<n>
<d>
Remarks
If no volume is specified, this command displays the volume that currently has the focus in the selected disk.
On a basic disk, selecting a volume also gives the focus to the corresponding partition.
If a volume is selected with a corresponding partition, the partition will be automatically selected.
If a partition is selected with a corresponding volume, the volume will be automatically selected.
Examples
To shift the focus to volume 2, type:
select volume=2
To shift the focus to Drive C, type:
select volume=c
To shift the focus to the volume mounted on a folder named c:\mountpath, type:
select volume=c:\mountpath
To display the volume that currently has the focus in the selected disk, type:
select volume
select commands
Shifts the focus to a disk, partition, volume, or virtual hard disk (VHD).
Syntax
select disk
select partition
select vdisk
select volume
Parameters
Parameter
Description
Select disk
Shifts the focus to a disk.
Select partition
Shifts the focus to a partition.
Select vdisk
Shifts the focus to a VHD.
Select volume
Shifts the focus to a volume.
Remarks
If a volume is selected with a corresponding partition, the partition will be automatically selected.
If a partition is selected with a corresponding volume, the volume will be automatically selected.
serverceipoptin