I am trying to expand the root partition on a VM which is not using LVM and I do not have (nor want to try and create then use) a disk to boot from. As such I followed what I felt was the logical series of actions (which multiple guides agree with me on):
- Resize the first partition in the partition table (using fdisk delete partition 1 and remake it with the same start point but a latter end point).
- Use resize2fs to extend the fs (it's ext4)
However, upon deleting and recreating the partition (maintaining id as 83, bootable flag as true and start point as 1) my system will not boot properly, it immediately goes to a grub command line.
So does anyone know what it is I'm doing wrong, and how I can fix it?
My fdisk looks like this:
Disk /dev/sda: 48.3 GB, 48318382080 bytes 255 heads, 63 sectors/track, 5874 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x000520da Device Boot Start End Blocks Id System /dev/sda1 * 1 1913 15360000 83 Linux /dev/sda4 4000 5874 15060937+ 83 Linux
And my fstab:
/dev/sda1 / ext4 defaults 1 1 tmpfs /dev/shm tmpfs defaults 0 0 devpts /dev/pts devpts gid=5,mode=620 0 0 sysfs /sys sysfs defaults 0 0 proc /proc proc defaults 0 0 /dev/sda4 /home/dbkats/rpmbuild ext4 defaults 0 0