SELECT Shift the focus to an object.
DISK=N DiskPart disk index number (origin 0)
DISK=Path location path
DISK=SYSTEM On BIOS machines, BIOS disk 0 .
On EFI machines, the disk containing the ESP partition used for the current boot will receive focus. On EFI machines, if there is no ESP, or there is more than one ESP present, or the machine is booted from Windows PE, the command will fail.
DISK=NEXT Once a disk is selected, iterate over all disks in the disk list.
If no options are specified, the select command lists the disk that currently has the focus.
view the DiskPart index numbers for all disks on the computer by using the LIST DISK command.
Examples:
SELECT DISK=1
SELECT DISK=SYSTEM
SELECT DISK=NEXT
SELECT DISK=PCIROOT(0)#PCI(0100)#ATA(C00T00L01)
PARTITION - to a partition. For example, SELECT PARTITION.
VOLUME - to a volume. For example, SELECT VOLUME.
VDISK - to a virtual disk. For example, SELECT VDISK.
| LIST Display a list of objects.
| DISK | Display a list of disks.
Disk ### Status Size Free Dyn Gpt
-------- ------------- ------- ------- --- ---
Disk 0 Online 111 GB 0 B *
Disk 1 Online 465 GB 38 GB
| PARTITION Display a list of partitions on the selected disk.
Partition ### Type Size Offset
------------- ---------------- ------- -------
Partition 1 Primary 100 MB 1024 KB
Partition 2 Primary 58 GB 102 MB
Partition 3 Unknown 53 GB 58 GB
| VOLUME |
| VDISK | Displays a list of virtual disks.
| | | |
| FILESYSTEMS| Display current and supported file systems on the volume.
| RESCAN | Rescan the computer looking for disks and volumes.
| |
| ACTIVE | Mark the selected partition as active.
| ASSIGN | Assign a drive letter or mount point to the selected volume.
| ATTRIBUTES | Manipulate volume or disk attributes.
| AUTOMOUNT | Enable and disable automatic mounting of basic volumes.
| |
| CLEAN Clear the configuration information, or all information, off the disk.
No warning, no confirm!
Note: Disk manager will request disk binitalized with MBR or GPT.
GPT will create a reserve partition Partition ### Type Size Offset
------------- ---------------- ------- -------
Partition 1 Reserved 128 MB 17 KB
| COMPACT | Attempts to reduce the physical size of the file.
| CONVERT | Convert between different disk formats.
| CREATE | Create a volume, partition or virtual disk.
| DELETE | Delete an object.
| EXTEND | Extend a volume.
| FORMAT | Format the volume or partition.
| GPT | Assign attributes to the selected GPT partition.
| IMPORT | Import a disk group.
| INACTIVE | Mark the selected partition as inactive.
| MERGE | Merges a child disk with its parents.
| ONLINE | Online an object that is currently marked as offline.
| OFFLINE | Offline an object that is currently marked as online.
| RECOVER Refreshes the state of all disks in the selected pack.
Attempts recovery on disks in the invalid pack, and
resynchronizes mirrored volumes and RAID5 volumes that have stale plex or parity data.
| REMOVE | Remove a drive letter or mount point assignment.
| RETAIN | Place a retained partition under a simple volume.
| SAN | Display or set the SAN policy for the currently booted OS.
| SETID | Change the partition type.
| SHRINK | Reduce the size of the selected volume.
| UNIQUEID | Displays or sets the GUID partition table (GPT) identifier or
master boot record (MBR) signature of a disk.
| |
| ADD | Add a mirror to a simple volume.
| BREAK | Break a mirror set.
| REPAIR | Repair a RAID5 volume with a failed member.
| |
| ATTACH | Attaches a virtual disk file.
| DETACH | Detaches a virtual disk file.
| EXPAND | Expands the maximum size available on a virtual disk.
| REM | Remark used to comment scripts.
| HELP | Display a list of commands.
| EXIT | Exit DiskPart.
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |