[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: creating a logical volume with a disk with existing data



Hi,

I followed [1] two days ago and it suited me. I had a non-LVM 160GB
disk with / and /home (ext3), plus a blank 1TB. What i did was
partition the whole 1TB as a "Linux LVM" partition, then set up the vg
and a -home (ext4) partition.

Then i mounted the LVM -home as /mount/tmp and copied my non-LVM /home
from the 160GB to the 1TB. I don't think it's feasible to turn a
non-LVM partition into an LVM one, you'd definitely lose data, so you
do need to copy.

So right now i have my old 160GB as it was, plus an LVM 1TB with a
-home partition (i wanna make sure it copied everything right before i
change fstab). The plan is to dump the partitions in the 160GB (which
include a rarely-if-ever used 15GB for XP (thanks to virtualbox)) and
to a fresh reinstall, using the installer's lvm-manager to set up both
drives. Hopefully it'll recognise one already has LVM, so i can add
everything to the same volume group.

Then i'll be able to set / as LVM (and /boot out of it apparently), as
well as other partitions for multimedia, vbox disks and maybe
something for public access like /var/www

Question 0: won't extending an existing lvm partition fragment it?

Question 1: is it feasable under linux (and an Asus m2npv-vm) to use
RAID as well? I was considering RAIDing 160GB since the drives are of
different sizes, maybe RAID 0 or 1, but i'm not sure such complexity
is worth it and even though the mb supports it, i think it's more sw
than hw-raid. But this is highjaking already.

Question 2: In order to add the 160GB drive, do i also format is as an
160GB "Linux LVM" partition and add that to the volume group? Will i
then have two drives under /dev/mapper? Is the split still there or
could i expand the existing LVM partition onto the 160GB and create
logical vlumes for / and what not in it?

HTH and TIA and some other acronym,
Nuno

[1] http://www.linux.com/learn/tutorials/306352-weekend-project-migrate-from-direct-partitions-to-lvm-volumes


Reply to: