Wednesday, 14 March 2007

ext2online is not always online

If you are running a system with ext3/ext2 on top of a LVM partition, or just when you made the partition bigger, you obviously want the file system to grow, too.

Easy, ext2online is the answer:

ext2online /dev/mapper/hdapool-homefilesystem

Unless you run into an error like:
ext2online v1.1.19 - 2001/03/18 for EXT2FS 0.5b
ext2online: group 0, block 2 not reserved

ext2online: unable to resize /dev/mapper/hdapool-homefilesystem

That's when you start googling and find that ext2online is not that online and needs the file system to be unmounted you need to run first:

/dev/mapper/hdapool-homefilesystem 23G

Note that the size there is the desired new target for the filesystem.
So you log off, go to a console, umount the file system (unlucky you if is the root file system, in that case you'll need the rescue mode - does D-I have ext2prepare?), run the command.

Now fsck.ext3 the device, mount it and try again ext2online. Now it should work.

1 comment:

Anonymous said...

ext2prepare is not available on all platforms. So try resize2fs when the volume is not mounted.