[Nottingham] LVM and load balancing and ReiserFS

Duncan John Fyfe djf at star.le.ac.uk
Fri Oct 26 20:55:25 BST 2007


On Fri, 2007-10-26 at 18:06 +0100, Martin wrote:
> OK Folks,
> 
> Anyone know the fine detail of LVM...?
> 
Some...
> 
> Rather than blindly use a mirrored RAID setup, and rather than
> (laboriously) manually spread frequently accessed directory trees across
> multiple physical HDDs...
> 
> Can LVM be used whereby directory trees are 'sensibly' spread across 2
> or 3 HDDs?

LVM has two mapping modes - linear (fill physical volumes sequentially)
and striped (interleave chunks of data between physical volumes).
Remember that LVM is not a filesystem and it is the filesystem that will
arrange the data on the logical volume and it will do it with no
knowledge of the underlying physical volumes - because you are using LVM
to hide them!
So, no LVM will(can)not "sensibly" spread directories (of which it knows
nothing) across the physical disks but it will interleave the data
stream across the disks (without any thought for what that data is).

> Or is LVM 'dumb' and just provides an extended linear LBA address range?
> 
> What happens if you have 3 HDDs and you remove one of the HDDs?
> 

As for unplugging a disk with no redundancy configured into the system
the data on that disk will be lost to the logical volume.  In linear
mode you may be able to recover data from the remaining volume.  In
striped mode I wouldn't swear to getting anything sensible out of it.

> 
> What is the ReiserFS strategy for physically placing directory trees and
> files across a disk?
> 

I wouldn't use Reiserfs but that is because it has problems which can
ruin (certain) data.  I would use ext2/3 or XFS with a bias towards XFS
for all but the root filesystem (and a caveat that a large XFS
filesystem can demand > 1GB memory per 1 TB of filesystem to do a
filesystem check).

> 
> (Or have I got lots of reading to do??? :-( )
> 
> Or do I play dumb and submit to a RAID mirror...?
> 
Put LVM on top of RAID.  Then you can merge additional RAID (or not RAID
if you like living dangerously) devices into the logical volume at a
later date and grow the existing filesystem into the new space.

What are you trying to achieve ?


Have fun,
Duncan
> Cheers,
> Martin





More information about the Nottingham mailing list