[linux-lvm] LVM Problems :)

Ken Fuchs kfuchs at winternet.com
Fri Feb 13 16:14:01 UTC 2004

Heinz Mauelshagen wrote:

>the size of your filesystem and logical volume differs already.
>That's why e2fsadm fails.
>Did you eventually run resize2fs in order to shrink the filesystem ?

>Your logical volume size is 1091456MB (32MB/PE * 34108 PE) but your
>filesystem size is 963584GB (941GB * 1024MB/GB; check with
>"tune2fs -l" and look for the block count and block size to calculate
>this correctly).

>In case the result shows, that your filesystem is already smaller than the LV,
>lvreduce the logical volume appropriately.

>Use the block count * block size result and round it up to the next PE!

To avoid an error in calculating the correct number of logical extents,
and possibly doing an lvreduce(8) to a size smaller than the filesystem:

Use resize_ext2(8) without a size argument.  This will resize the ext2
or ext3 filesystem to be the same size as the logical volume containing
it.  After doing this, e2fsadm(8) can be used to resize the filesystem
and logical volume "simultaneously" to any desired size (that can
contain the filesystem's data).


Ken Fuchs <kfuchs at winternet.com>

More information about the linux-lvm mailing list