select volumeselect volume

适用于: Windows Server (半年通道) ,Windows Server 2019,Windows Server 2016,Windows Server 2012 R2,Windows Server 2012Applies to: Windows Server (Semi-Annual Channel), 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>}

parametersParameters

参数Parameter 说明Description
<n> 要接收焦点的卷的编号。The number of the volume to receive the focus. 可以通过使用 DiskPart 中的 " 列出卷 " 命令,查看当前所选磁盘上的所有卷的编号。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.

注解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

若要将焦点转移到 第2卷,请键入:To shift the focus to volume 2, type:

select volume=2

若要将焦点转移到 驱动器 C,请键入:To shift the focus to Drive C, type:

select volume=c

若要将焦点移动到名为 c:\mountpath的文件夹中的卷,请键入: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

其他参考Additional References