[linux-lvm] which files, which physical volumes?

Michael T. Babcock mtb at mikebabcock.ca
Sun Sep 26 23:49:34 UTC 2004

Steve Wray wrote:

> Well then its bogus; the physical volume I am trying to pvmove has a 
> capacity of around 9G whereas the volume group of which it is a part 
> has a nice 42G free.
> So how does that work out to not enough extents?

Does the Volume Group in question have 42GB of unallocated extents, or 
42GB free on the allocated Logical Volumes?

If you had VG main with 60GB total containing LVs lv1 and lv2 each 20GB 
then you'd have 2GB unallocated on the VG.

If you want more unallocated space on e.g. /dev/hdc1 (a member of VG 
main) to move part of lv1 onto (from /dev/hda1), you'd have to do 
something like:

resize_filesystem /dev/main/lv2 (down to smaller size)
lvresize -L (new size) /dev/main/lv2 # to resize the logical volume 
using the space
pvmove -n /dev/main/lv2 /dev/hdc1 # to move as much as possible of lv2 
off this PV
pvmove -n /dev/main/lv1 /dev/hda1 /dev/hdc1

Does that make sense to you?
Michael T. Babcock

More information about the linux-lvm mailing list