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

Re: how can I add disk space?



On Fri, 6 Oct 2000, Adam Scriven wrote:

> RAID stands for Redundant Array of Inexpensive Drives (Disks?)
> LVM stands for Logical Volume Management (IIRC).

I've always heard 'Disks' but I suppose, sooner or later someone will come
up with a drive which isn't a disk that is still suitable for RAID, and
then it will mean 'Drives'. :}

> RAID combines multiple partitions (not necessarily full drives) into
> one single drive.  Depending on the type of RAID that you use, you can
> have some sort of redundancy (RAID 5), or just combining your drives
> (RAID 0 is Striping, which is what does this, IIRC), or you can get
> pure backup with mirroring (RAID 1, again IIRC).

You're quite right.  However we should distinguish, between RAID
and the Linux multiple-disk driver.  RAID defines a method for spreading
data over multiple disks, the multiple-disk driver actually implements
this, along with some other things like linear concatenation (in which
data is stored on multiple partitions "in order" without any special
handling at all - this is the best solution for multiple partitions on
the same disk, or very often for two IDE drives on the same controller).

RAID doesn't protect against data corruption from system crash or power
failure.  For that you need to use a journaling filesystem such as
ReiserFS, ext3fs, or IBM-JFS.  In fact, in some cases it can actually make
this damage worse.  RAID only prevents damage from disk failure.

Note that the use of the multiple-disk driver to apply to partitions is
something of a Linux thing.  RAID is not required to work on partitions by
its nature.  In fact, the only time you really want to use RAID on a disk
partition is if you have got other data in other partitions on that disk
that you can't or don't want to relocate (for example, maybe it is your
root disk).  You normally do not want to make two partitions on the same
disk part of the same MD virtual device, except using linear
concatenation, as it will be extremely slow.

LVM is similar to the multiple-disk driver, and duplicates some of the
functionality, but really operates at a higher level.  Both systems allow
disks to be used as logical devices which are more flexible and capable
than the plain physical disks.  But instead of providing RAID features,
LVM allows you to dynamically allocate and resize logical volumes.  Disk
devices are put into volume groups and then logical volumes are allocated
from the volume groups.

It's usually much easier to add space to a logical volume than to shrink
one, so space is generally left unallocated until used.

LVM doesn't provide any of RAID's redundancy, but you can add MD virtual
devices to an LVM volume group.  There is currently some debate about
whether this is actually safe to do yet, although it should be safe in the
released 2.4 kernel.  For best efficiency the physical disks should all be
part of the MD virtual device and then that MD virtual device should be
the only thing in the volume group.



Reply to: