Resize Partition??

Dick Davies rasputnik at
Tue Jul 19 00:53:56 UTC 2005

* Hugh Crissman <hcrissman at> [0734 02:34]:
> * Dick Davies <rasputnik at> [2005-07-14 22:31:00]:
> > The only snag is that the kernel needs to know WTF a LVM volume is to mount
> > root :) - generally that means having LVM modules in your initrd, or building
> > it into the kernel.
> > 
> > Linux LVM (plus reiserfs) is a *big* plus in my book, the flexibility of not
> > having to know in advance how big /home will ever need to be is much appreciated :)
> I agree. LVM is what needs to be done. Now the problem is the logistics.
> I just installed a machine from scratch w/ LVM. Not to bad. But the
> question is...
> What steps do I need to take to setup LVM on an existing production system
> w/ minimal downtime? Here is what I have gleaned from docs I have read.
> Step:
> 	1. Backup Data
> 	2. Boot off LiveCD(knoppix) and partition(100mb for /boot and
> 	the rest for LVM) hard drive.

2a. select some disk partitions (logical or physical) and format as LVM physical volumes,
to build the volume group.

> 	3. Create and Initialize Volume Group
> 	4. Create Logical Volumes(LV)
> 	5. Apply filesystem to LVs (ReiserFS) seems to be a strong
> 	contender.

Yeah, reiser looks good. only downer is the need to umount it if you want to shrink a
partition, but that's not a showstopper in my case.

> 	6. Mount filesystem and restore backed up files.
> 	7. Edit fstab to mount appropriately at boot.

Mine looks like:

/dev/mapper/toadvg-rootlv /               reiserfs defaults        0       1
/dev/mapper/toadvg-homelv /home           reiserfs defaults        0       2
/dev/mapper/toadvg-tmplv /tmp            reiserfs defaults        0       2
/dev/mapper/toadvg-usrlv /usr            reiserfs defaults        0       2
/dev/mapper/toadvg-varlv /var            reiserfs defaults        0       2

(I left /boot and swap on physical devices, since they don't need resizing).

> 	8. Edit initrd to include LVM modules (not so sure on this one)

I'm guessing man mkinitrd, or build a kernel with LVM built-in.
Though the default ubuntu install seems to find mine easily enough.
> How does that sound. Am I leaving anything out?

Nothing I can see. Good luck!
'MUMS! when clearing up after a children's party, always burst balloons
before throwing them away. This way you use far fewer dustbin liners.' -- Top Tips
Rasputin :: Jack of All Trades - Master of Nuns

More information about the ubuntu-users mailing list