Hi,
I have VMware ESXi (the free version) hosting an Ubuntu Server 12.04 guest. The guest was stupidly (by me) installed onto a too-small disk.
I've resized the disk but the partition table is still too small. So instead I want to create a new virtual disk, create partitions, mount them and then do a file-by-file copy to the new setup.
Rather than the ridiculous default partition scheme I want to set up something reasonable. Since the default is MBR partition table I'll stick with that to avoid hassles, but there's no way I'm going to use an extended partition when there are only 3 partitions.
So I want / and /boot and swap, and what I was thinking is this:
Then chroot into /mnt/new, re-run grub and reboot.
Any problems with this approach?
Thanks.
Afterthought: What I would rather do is make a GPT partition table, set up LVM and go that route. I somehow think that's going to turn into a lot of problems.
Thanks.
I have VMware ESXi (the free version) hosting an Ubuntu Server 12.04 guest. The guest was stupidly (by me) installed onto a too-small disk.
I've resized the disk but the partition table is still too small. So instead I want to create a new virtual disk, create partitions, mount them and then do a file-by-file copy to the new setup.
Rather than the ridiculous default partition scheme I want to set up something reasonable. Since the default is MBR partition table I'll stick with that to avoid hassles, but there's no way I'm going to use an extended partition when there are only 3 partitions.
So I want / and /boot and swap, and what I was thinking is this:
- Boot from system rescue cd
- mkdir /mnt/old
- mkdir /mnt/new
- mount /dev/whatever-root-is /mnt/old
- mount /dev/whatever-boot-is /mnt/old/boot
- mount /dev/whatever-newroot-is /mnt/new
- mount /dev/whatever-newboot-is /mnt/new/boot
- cd /mnt/old
- cp -rax . /mnt/new/
Then chroot into /mnt/new, re-run grub and reboot.
Any problems with this approach?
Thanks.
Afterthought: What I would rather do is make a GPT partition table, set up LVM and go that route. I somehow think that's going to turn into a lot of problems.
Thanks.