"anchoring" the logical volumes to physical volumes
Hello!
I have two SCSI harddisks of 4.5 GB each and I want to install Linux on them on top of LVM.
I want to put / /boot /var /home /usr/local on the first disk and /usr on the second one. At the same time I want to have all partitions (except /boot) on LVM so I can extend/snapshot them.
I can take the obvious route of creating a PV on each of the harddisks and putting them in the same VG and then splitting the VG into LV. But I want to make sure /usr gets on the second disk and all /usr and / get allocated at the beginning of the PV.
I can simulate this by creating the first LVs than a LV that will fill up the first PV then the LV for /usr... But this is ugly and I am not sure is guaranteed to work.
Any "smart" solution to this problem? Any plans to implement such a feature in lvcreate?
Thank you,
florin
Signature · 3 lines
"If it's not broken, let's fix it till it is." 41A9 2BDE 8E11 F1C5 87A6 03EE 34B3 E075 3B90 DFE4
Quoted 12 lines · Florin Iucha
Hello!
I have two SCSI harddisks of 4.5 GB each and I want to install Linux on them on top of LVM.
I want to put / /boot /var /home
/usr/localon the first disk and /usr on the
second one.At the same time I want to have all partitions (except /boot) on LVM so I can extend/snapshot them.I can take the obvious route of creating a PV on each of the harddisks and putting them in the same VG and then splitting the VG into LV. But I want to make sure /usr gets on the second disk and all /usr and / get allocated
at the beginning of the PV.
Quoted 7 lines
I can simulate this by creating the first LVs than a LV that will fill up the first PV then the LV for /usr... But this is ugly and I am not sure is guaranteed to work.
Any "smart" solution to this problem? Any plans to implement such a feature in lvcreate?
i think it's already implemented, there should be an option which tells lvcreate which PV's to use for the LV you are creating . see the man page to lvcreate or lvcreate --help
Quoted 4 lines
Thank you,
florin