Discussion:
[linux-lvm] Combine multiple physical volumes onto a larger device
Greg Zartman
2015-02-22 03:05:23 UTC
Permalink
I'm sure this has been asked and answered before, but after a fair bit of
googleing I'm not coming up with an answer.

I have a fairly old volume group that is made of 9 x 620GB PVs. I'd like
to move this volume group off these devices onto a couple larger drives.
What is the best way to do this? I've read that you can vgextend the new
drives into the volume group and the use pvmove to move data off one PV to
another, but I don't know if you can pvmove smaller pvs onto a larger disk
and they will all be combined.

Maybe there is a better way to move the entire VG? I want to maintain
the current VG and LV names from my old setup, this my desire to just move
the entire lot at once instead of rsyncing or something.

Thanks,

Greg
emmanuel segura
2015-02-23 10:07:34 UTC
Permalink
yes, you can move the smaller in larger drives.
Post by Greg Zartman
I'm sure this has been asked and answered before, but after a fair bit of
googleing I'm not coming up with an answer.
I have a fairly old volume group that is made of 9 x 620GB PVs. I'd like to
move this volume group off these devices onto a couple larger drives. What
is the best way to do this? I've read that you can vgextend the new drives
into the volume group and the use pvmove to move data off one PV to another,
but I don't know if you can pvmove smaller pvs onto a larger disk and they
will all be combined.
Maybe there is a better way to move the entire VG? I want to maintain the
current VG and LV names from my old setup, this my desire to just move the
entire lot at once instead of rsyncing or something.
Thanks,
Greg
_______________________________________________
linux-lvm mailing list
https://www.redhat.com/mailman/listinfo/linux-lvm
read the LVM HOW-TO at http://tldp.org/HOWTO/LVM-HOWTO/
--
esta es mi vida e me la vivo hasta que dios quiera
John Stoffel
2015-02-23 21:00:30 UTC
Permalink
Greg> I'm sure this has been asked and answered before, but after a
Greg> fair bit of googleing I'm not coming up with an answer.

You want to use 'pvmove' to get the LVs off the PV(s) you want to
evacuate. Now are these PVs stripped or mirrored or RAID'd in any
way? Then you don't want to just blindly move things around because
you'll run into performance issues.

Basically, it depends. Can you provide more details of your setup so
w can help?

Greg> I have a fairly old volume group that is made of 9 x 620GB PVs. 

Are these 9 seperate 1Tb drives?

Greg> I'd like to move this volume group off these devices onto a
Greg> couple larger drives.  What is the best way to do this?  I've
Greg> read that you can vgextend the new drives into the volume group
Greg> and the use pvmove to move data off one PV to another, but I
Greg> don't know if you can pvmove smaller pvs onto a larger disk and
Greg> they will all be combined.

So it sounds like you have your PVs striped together into a single
volume, correct?

Greg> Maybe there is a better way to move the entire VG?    I want to
Greg> maintain the current VG and LV names from my old setup, this my
Greg> desire to just move the entire lot at once instead of rsyncing
Greg> or something.

It might make sense to build new PVs, and then mirror the existing
volume(s) onto the new disks, then you can remove the old mirrors.
This would let you take 9 x 10g LVs that are striped together and
mirror them with say 3 x 30g LVs so that your data gets laid out
properly.

But it all depends on your setup details. Please post them so we can
comment on this.

John

Continue reading on narkive:
Loading...