You are not logged in.

#1 2012-03-02 07:50:11

jamgood96
Member
Registered: 2012-01-09
Posts: 42

RAID and LVM

Hey All,

I've been doing a far amount of reading on RAID and LVM. I've gotten things setup, but don't quite have a full understanding of how I want to or should setup things for our office server.

I've got one 150G HDD for the OS and things, then I have two 2TB HDDs that I want to setup in RAID1. That part I can figure out. But then how does LVM tie into this, or is it not necessary at this point? I'm also confused as to if I should being setting up the LVM with the 150G HDD as well.

Sorry if my post is a little scattered, but it's how my head is with the RAID and LVM config, even after reading a bunch.

Thanks!

Offline

#2 2012-03-02 13:48:23

jakobm
Member
Registered: 2008-03-24
Posts: 132

Re: RAID and LVM

lvm will provide you with easy creation, resizing and deletion of partitions. You can use any block device (e.g. your raid1 array) for the physical volume of lvm.

I think the blog post "LVM on LUKS on Raid1 on Arch Linux" and the nice figure in it will help you.

Hint: Try to visualize your disk setup in a similar manner.

Last edited by jakobm (2012-03-02 13:49:00)

Offline

#3 2012-03-02 17:56:25

jamgood96
Member
Registered: 2012-01-09
Posts: 42

Re: RAID and LVM

jakobm wrote:

lvm will provide you with easy creation, resizing and deletion of partitions. You can use any block device (e.g. your raid1 array) for the physical volume of lvm.

I think the blog post "LVM on LUKS on Raid1 on Arch Linux" and the nice figure in it will help you.

Hint: Try to visualize your disk setup in a similar manner.

Nice article. Thanks!

Im still a bit lost on how to handle a setup with a sible smaller drive and two setup in RAID. My reasoning for a smaller drive for the OS is for speed. Then I'd leave the 2tb drives for storage. However, how would I implement the single 150gb into things? Am I going about this all wrong?

Offline

#4 2012-03-02 20:42:14

Jasonvw
Member
From: Detroit, Michigan
Registered: 2011-12-23
Posts: 22

Re: RAID and LVM

I think you are going about it the right way. The first thing is that I think your OS drive should be independent of anything done on the 1Tb drives, unless of course you wanted to back up your OS to the RAID1 array. The other big question is if you have hardware RAID. This is obviously preferred if your motherboard supports it or you have a RAID card (even better). If you don't you'll need to use LVM for software RAID. If you are doing soft RAID, check out this article:
     https://wiki.archlinux.org/index.php/So … ID_and_LVM
If you have a hardware RAID card i think the question you should ask yourself if how you are going to have your partitions setup on the array. If you are only going to have one big partition and don't think you'd ever have reason to change that then i would recommend not using LVM for simplicity. If you might want to resize partitions on the fly or create disk snapshots then LVM is for you. Does that clear things up at all?


RAID !=backup

Offline

#5 2012-03-03 23:57:14

fukawi2
Ex-Administratorino
From: .vic.au
Registered: 2007-09-28
Posts: 6,224
Website

Re: RAID and LVM

jamgood96 wrote:

Im still a bit lost on how to handle a setup with a sible smaller drive and two setup in RAID. My reasoning for a smaller drive for the OS is for speed. Then I'd leave the 2tb drives for storage. However, how would I implement the single 150gb into things? Am I going about this all wrong?

Create 2 Volume Groups (eg, "OS" and "RAID")
"OS" == the 150gb drive.
"RAID" == the 2 x 2tb drives after they've been RAID'ed (eg, /dev/md0)

They can then be managed for the separate purposes without crossing over, but still have the benefits of LVM (ie, adding another 2 x 2tb drives in the future and adding them to the RAID VG)

Offline

Board footer

Powered by FluxBB