LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 04-13-2008, 05:10 AM   #1
bennethos
Member
 
Registered: Aug 2003
Location: Belgium
Distribution: -- Slackware for servers -- Debian for desktops --
Posts: 124

Rep: Reputation: 16
full soft raid 1 with slackware


Hi,

I got a server with 2 sata disks that I want to put in a bootable soft raid...

I want the following partition scheme

/ primary part 1
/home primary part 2
swap primary part 3
extended part
/usr extended 1
/tmp ...
/var ...
/opt ...

- set all the flags to FD (raid autodetect) with fdisk
- copy the part scheme using sfdisk to my 2nd disk

Got couple of questions concerning this setup...

* I read I have to put all the partition flags to FD (raid autodetect) but what about the swap partition ?

* I can't seem to put my extended partition in the raid 1 using mdadm, skipping it might give probs when a disk fails I guess ? Or should I use LVM for more than 4 partitions ?

* when creating the arrays I do :
mdadm --create /dev/md0 --level=1 --raid-devices=2 /dev/sda1 /dev/sdb1
mdadm --create /dev/md1 --level=1 --raid-devices=2 /dev/sda2 /dev/sdb2
mdadm --create /dev/md2 --level=1 --raid-devices=2 /dev/sda3 /dev/sdb3
and so on...

Is this correct or can I just do :
mdadm --create /dev/md0 --level=1 --raid-devices=2 /dev/sda /dev/sdb and create all the partitions under /dev/md0 ...

thx, i'm a bit confused here ;-)
 
Old 04-13-2008, 11:24 PM   #2
dkm999
Member
 
Registered: Nov 2006
Location: Seattle, WA
Distribution: Fedora
Posts: 407

Rep: Reputation: 35
It's not too surprising that you are a bit confused by all this, because there is seriously contradictory information floating about on the 'Net concerning this point. When I tried the same thing using Fedora, I found that, even though the mdadm stuff seems to say that you can have multiple partitions under a single RAID set, it doesn't actually work. The best I was able to come up with was to configure things so that each partition ran as a separate RAID set, though I later learned that (theoretically) a single LVM that contains several partitions can run under one RAID set.

So in your case, I see 3 RAID sets: one for the root and boot stuff; one for the swap partition, and one for a LVM containing everything else (/home, /usr, /tmp, ...). In addition, you might want to do some more reading to decide if you really want the swap partition to be RAIDed. There appear to be arguments both ways about this.

Good luck.
 
Old 04-17-2008, 10:03 AM   #3
bennethos
Member
 
Registered: Aug 2003
Location: Belgium
Distribution: -- Slackware for servers -- Debian for desktops --
Posts: 124

Original Poster
Rep: Reputation: 16
thx, also read some people put the swap partition in striping instead of mirror...
1 problem, if a disk fails you dont have a swap anymore... But it seems there's a workaround for that.

Anyways, i'll try to read up a bit more, happy to know i'm not the only one confused about the subject, cant even find a decent book about software raid (recent one, explaining mdadm for 2.6 kernels etc..)
 
Old 04-17-2008, 04:19 PM   #4
mRgOBLIN
Slackware Contributor
 
Registered: Jun 2002
Location: New Zealand
Distribution: Slackware
Posts: 999

Rep: Reputation: 231Reputation: 231Reputation: 231
I never bother putting my swap on raid I just add them to fstab with the same priority.

Code:
/dev/sda3        swap             swap        pri=1         0   0
/dev/sdb3        swap             swap        pri=1         0   0
/dev/sdc3        swap             swap        pri=1         0   0
Might find some useful info here

http://www.userlocal.com/articles/ra...ackware-12.php
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to install Fedora 7/soft RAID-1 on a MB with built-in HW(fake) RAID-1? bozhulich Fedora - Installation 3 08-15-2007 08:04 AM
How to install Fedora 7 on soft raid on VT6420 SATA RAID bozhulich Fedora 3 08-14-2007 01:08 AM
SuSE 9.3 - Soft Raid WL7JA Linux - Newbie 3 09-01-2005 03:14 PM
Soft Raid for dummies? jbj SUSE / openSUSE 1 12-12-2004 06:39 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 05:45 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration