Disk images of virtual machines usually contain a parition table that contains one or more file systems. Resizing that is a bit painful, as you need to carefully rewrite the partition table before you can resize the. Inside a Linux VM, the changed partition table can't be read-in on the fly, so you need one more reboot of the VM.
I'd love to have the disk image contain the file system directly, without any partitions. This would allow for easy resizing from within as well as outside the VM. However, in such an installation the Grub bootloader so no longer reliable, because it needs to point to its stage2 via hard-coded block position, which makes the VM unbootable every few months when the file system moves stuff around. (With a DOS partition table, it uses the unallocatable space between MBR and first partition to put its stage2 into. With other partition tables, you create a separate bootloader partition for that.)
Is there any way around this?
How should I organize a VM disk image so it is as simple as possible to resize?
First ideas are:
Using two disk images per VM, one disk of fixed size just for the bootloader (MBR+stage2) and a second disk containing directly the filesystem.
Using a different bootloader. But don't have LILO and Syslinux the same problem? The first 512 bytes of a disk are simply too small to contain a file system driver.
Is there any other, perhaps simpler, way to achieve this?