[ale] Question: to LVM or not LVM

Greg Freemyer greg.freemyer at gmail.com
Sat Feb 10 19:08:01 EST 2007


On 2/10/07, cfowler at outpostsentinel.com <cfowler at outpostsentinel.com> wrote:
> On Sat, Feb 10, 2007 at 01:04:06PM -0500, Robert Reese wrote:
> > I have a question I hope y'all can help me with...
> >
> > I am installing openSUSE 10.2 on my laptop and want to use the Xen virtualization or the VMWare solution to run XP Pro inside a virtual machine.  Looking at LVM, which I found is different than a VM, the prospect intrigues me as I have a growing number of spare harddrives and external harddrives.
> >
> > The question is whether I should install openSUSE with LVM or will I find a much more difficult time ahead than without LVM?
>
> Good question.  I don't really care for it personally.  I used LVM on AIX
> and had good reason to.  We would install systems and they of course would
> have small disks.  Using LVM we were able to add a new hard disk(s) and
> we could grow the AIX FS into those disks.  Need more pagging space?  That was
> under LVM too.  We would just grow that into new disks.  With Linux I've had
> decent size disks and have never had to use LVM for any reason.  I guess
> you could grow the LVM to use more space but what about ext3?  Does
> ext3 support growth or shrinkage?  I've never used it enough to know.
>
> LVM to me is good when you have more than one disk or plan on it
> in the future and want to grow your file systems into new space.  It
> is easier to grow the FS then to tar it up, re-format, and un tar it
> back on the newly formated FS.  Other than that I don't really see the
> benefit of using LVM.  Especially if you only have one drive to begin
> with.
>
> >
> > TIA,
> > Robert Reese~

First, I would never boot dom0 off of LVM.  If you have a problem it
makes it hard to fix.

Other than that LVM is a good fit with any VM if you are going to
creating / deleting VM setups.  OTOH, if it is a one time thing you
don't need it.

There are 2 big advantages to LVM; flexibility and snapshots.

Flexibility is the ability to easily create Volumes on the fly or to
resize them.  Yes ext3 can at a minimum grow on the fly.  I don't
remember if they have shrink at all.  Reiserfs, JFS, XFS can also all
grow on the fly.  At least one of the above can shrink, but again I
don't remember.

The 2nd advantage does not sound like it applies, but maybe.  With a
LVM you can snapshot a volume.  I have not kept up with LVM in the 2.6
kernel.  In the 2.4 kernel all you could do is use that snapshot as a
source for tape backups, or manual file by file restores.

More capable LVMs allow you to restore the entire snapshot at one
whack.  ie. I was at a clients a couple weeks ago and they were using
Netapp filers to hold their Oracle DBs.  They would snapshot them as a
backup.  The they would retain numerous snapshots going back 4 days or
so as their main backup strategy.  (Netapp supports 255 snapshots per
volume AIUI).

Hope that helps,
Greg
-- 
Greg Freemyer
The Norcross Group
Forensics for the 21st Century



More information about the Ale mailing list