Resize Ubuntu Linux system to smaller disk inside VMware ESXi

Posted by mlambie on Server Fault See other posts from Server Fault or by mlambie
Published on 2010-06-07T17:23:22Z Indexed on 2010/06/07 17:32 UTC
Read the original article Hit count: 365

Filed under:
|
|
|

I have several Ubuntu Linux virtual machines running on VMware ESXi hosts that have all been allocated disks much larger than their required capacity. As space is now becoming an issue on our SAN, I'd like to investigate downsizing the allocated disk space on these machines.

All systems will be completely backed up imaged before I begin making changes, and I will always retain a pristine backup in case the partition resizing does not work.

Is there an easier way than the following procedure, or is their a better solution entirely?

  1. Shutdown and assign a second disk to the virtual machine
  2. Boot using the SystemRescueCD
  3. Use GParted to resize the original (source) partition, making it smaller
  4. Clone the new, smaller partition to the second disk
  5. Shutdown and remove initial disk from the virtual machine
  6. Reboot and force fsck to check the filesystem

© Server Fault or respective owner

Related posts about linux

Related posts about vmware