Monday, May 15, 2017

partition - LVM can I extend a logical volume across 2 volume groups?



I resized my /opt which was the only logical vol in vg2 but I want to give that freed space back to / which is on vg1. Is this possible? pvscan output below. I want to grow my / partition which is on vg1 by 200 GB.



PV /dev/sda3   VG vg2   lvm2 [212.40 GiB / 202.40 GiB free]
PV /dev/sda2 VG vg1 lvm2 [537.10 GiB / 0 free]

Answer



Unfortunately no.




You cannot extend LV's across multiple Volume Groups.



Instead, you should have added all PV's to the same VG. This gives you way more flexibility when it comes to managing the disk space allocation.


No comments:

Post a Comment

linux - How to SSH to ec2 instance in VPC private subnet via NAT server

I have created a VPC in aws with a public subnet and a private subnet. The private subnet does not have direct access to external network. S...