Posts

Showing posts with the label Resize-Partition

Windows 2012 R2 and Windows 8.1 Partition Resize

Unlike on their predecessors, on Windows Server 2012 R2 and Windows 8.1 (and later), you can resize the system partition online without having to shut the OS down. And since I've got a thing for Powershell, I'll suggest a couple of cmdlets that will get the job done. First of all, you have to make sure that there is unpartitioned space on the disks. In most cases you'll be expanding a virtual machine's partition so you'll have to resize the virtual disk first. The cmdlet we're going to use is Resize-Partition and you can find the definition here.  Before we start resizing we have to identify the disk number of the disk and the partition number. The Get-Disk cmdlet will help you with the disk numbers and the Get-Partition with the partition number. When you have the partition and disk number, you have to decide the new partition size and you're ready to resize. If you want the partition to take up all the free space l...