# Budget Sata Raid1 card

## PietdeBoer

Hey folks,

Iam looking for a budget sata raid1 card...

I've searched through a lot of webshops only finding devices wich do a fake raid... and a lot where iam not sure wether they do it or not.

So anyone knows of a decent sata raid1 card? pci-e or pci?

thx in advance!

----------

## Jake

AFAIK, there's no point in doing RAID1 (or 0) in hardware.

----------

## PietdeBoer

OK, this is my issue,,

i tried several raid cards wich do a fake raid and tried to install gentoo on them.

After creating the arrays gentoo always shows seperate hdds instead of one array during the install

----------

## DrAgOnTuX

 *PietdeBoer wrote:*   

> OK, this is my issue,,
> 
> i tried several raid cards wich do a fake raid and tried to install gentoo on them.
> 
> After creating the arrays gentoo always shows seperate hdds instead of one array during the install

 

why fake raids? do you wanna build a dualboot sys with windows & gentoo on it?

if no, try this: http://www.gentoo-wiki.com/HOWTO_Gentoo_Install_on_Software_RAID

- much better performance

- device arch independent (mix ide, sata, scsi, usb, ramdrive   :Laughing:  )

----------

## PietdeBoer

i want to setup my os on a raid1 array, using a decent controller

----------

## DrAgOnTuX

 *PietdeBoer wrote:*   

> i want to setup my os on a raid1 array, using a decent controller

 

which os? gentoo?

why a decent crap-fake-raid when your linux kernel can manage all this without troubles.

-> a simple 

```
cat /proc/mdstat
```

 and you get the status of your raids

----------

## PietdeBoer

ok, you convinced me...

but now.. shall i use raid1 or raid5 for my os?

----------

## DrAgOnTuX

 *PietdeBoer wrote:*   

> ok, you convinced me...

  May the force be with you   :Very Happy: 

 *PietdeBoer wrote:*   

> but now.. shall i use raid1 or raid5 for my os?

 

depends on what you want to do with your os: http://www.sql-server-performance.com/faq/raid_1_raid_5_p1.aspx

you do not define a raid level over the hole disk.

you define a raid level for each partition:

 *Quote:*   

> 
> 
> /dev/sda1 + /dev/sdb1 + /dev/sdc1 -> raid1 -> /dev/md0 --> /boot
> 
> /dev/sda2 + /dev/sdb2 + /dev/sdc2 -> raid0 -> /dev/md1 --> /
> ...

 

----------

## PietdeBoer

hmm

should i not use raid1 for / and /boot ?

i read in the toturial i have to create a raid1 for boot.. to make my kernel readable to the bios

----------

## gentoo-dev

 *PietdeBoer wrote:*   

> ok, you convinced me...
> 
> but now.. shall i use raid1 or raid5 for my os?

 Your choice. raid-5 works with 3 disks, but better use 4 or more.

See http://www.gentoo.org/doc/en/gentoo-x86+raid+lvm2-quickinstall.xml for the install process, just replace raid-* with raid-5 where you want.

Only /boot needs raid-1 (or no raid at all).

BTW, link posted above seems to imply that raid-1 spreads reads over two disks while raid-5 spreads them on more disks. Not quite so, raid-1 does not spread reads at all which gives you the same read speed as a single disk. Besides, you do not have to choose between raid-5 and raid-1, you can also use raid-0 where reliability is not important but speed is, i.e. /usr/portage, temp files, log files maybe... Anything you can afford to lose or rebuild easily can go in a raid-0

BTW, I don't get why people use /dev/md0=/dev/sda1+/dev/sdb1...

/dev/md1=/dev/sda1+/dev/sdb1

/dev/md2=/dev/sda2+/dev/sdb2

/dev/md3=/dev/sda3+/dev/sdb3

/dev/md5=/dev/sda5+/dev/sdb5

....

Would seem so much more logical and easier to remember should you reassemble your raid manually.

Good luck

----------

## Jake

 *gentoo-dev wrote:*   

> BTW, link posted above seems to imply that raid-1 spreads reads over two disks while raid-5 spreads them on more disks. Not quite so, raid-1 does not spread reads at all which gives you the same read speed as a single disk. Besides, you do not have to choose between raid-5 and raid-1, you can also use raid-0 where reliability is not important but speed is, i.e. /usr/portage, temp files, log files maybe... Anything you can afford to lose or rebuild easily can go in a raid-0

 

I can't say if RAID1 actually does spread out reads, but theoretically it can. You have multiple copies of the same data, so it can read half from one disk and half from another. It's writes that see no benefit since you have to write all data to both disks. RAID0 does the converse. Writes are doubled since they can go to either disk, but reads don't benefit because you have to read from the single disk the data you're interested in resides on. An interesting way to get the best of both worlds is to have a stripe of mirrors or mirror of stripes. See http://en.wikipedia.org/wiki/Nested_RAID_levels.

Personally, I use software RAID5 for my fileserver (actually I'm using RAIDZ in ZFS on Solaris, but it's basically RAID5). I have enough spare CPU power with a dual-core Athlon64 that I don't notice the overhead.

----------

## PietdeBoer

ok,

this box is going to be a fileserver.. so the best setup for me would be:

raid1 for boot

raid1 for swap?

raid5 for /

raid5 for /home ???

----------

## alex.blackbit

if you don't want to have a raid setup that does not affect your cpu load, than you have to buy a real raid controller, and those are not cheap.

i personally would prefer one from 3ware/amcc like the "escalade 9650se-2lp" (for a simple 2 drive raid1 setup) which has a driver in the vanilla kernel, so it works right away and a nice cmd line tool (sys-block/tw_cli).

----------

## neysx

 *Jake wrote:*   

> I can't say if RAID1 actually does spread out reads, but theoretically it can.

 Practically, it does not.

 *PietdeBoer wrote:*   

> This box is going to be a fileserver.. so the best setup for me would be

 a mix of raid-0 1 and 5, see gentoo-dev's post above. For instance, it makes no sense to store the portage tree in raid-5, a raid-0 volume with a small block size would be much faster.

 *alex.blackbit wrote:*   

> if you don't want to have a raid setup that does not affect your cpu load, than you have to buy a real raid controller, and those are not cheap.
> 
> i personally would prefer one from 3ware/amcc like the "escalade 9650se-2lp" (for a simple 2 drive raid1 setup) which has a driver in the vanilla kernel, so it works right away and a nice cmd line tool (sys-block/tw_cli)

 3ware are nice and not cheap unless you can get one on ebay. My 9500 is configured with JBOD because I'd like to be able to reassemble the same array on another machine if the card goes belly up.

HTH

----------

## Cyker

The only non-FakeRAID RAID1/0 cards I've seen have been the generic Adaptecs and LSI Logics that Dell bundle with their servers (And they use backplane SAS connectors  :Sad: )

It would be much easier to install and boot from a real hardware RAID card than fakeRAID or software RAID 'tho.

Still, there is a workaround 'kludge' for Linux SW RAID1 which you can use as someone posted above.

According to the kernel docs and some other docs, Linux RAID1 is supposed to spread reads over disks, but it doesn't in practice.  :Sad: 

----------

## alex.blackbit

i did not have much fun with the adaptec raid cards in the past, the drivers and their packaging is a mess, although my experiences are about 2 years old, maybe something changed in this time. i had a lsi sas non-raid-adapter once that worked quite well.

but still, i believe the 3wares are best.

----------

## DrAgOnTuX

 *gentoo-dev wrote:*   

> 
> 
> BTW, I don't get why people use /dev/md0=/dev/sda1+/dev/sdb1...
> 
> /dev/md1=/dev/sda1+/dev/sdb1
> ...

 

Right   :Wink: 

PS: mdadm --assemble --scan   :Twisted Evil: 

----------

## DrAgOnTuX

@alex.blackbit there are no cheap real raid controller which are able to run as fast as a pure linux sw raid   :Cool: 

cpu load doesn't matter normaly, because it's so small  :Smile:  (in my case... except rebuild a raid5 over 7 disks   :Razz:  )

++ for linux sw raid: if your mobo/controller is dead, just switch your disks to another computer "et voilà" .. your data is still available.

this scenario is quite harder and vendor dependend if your real raid controller is dead...

----------

## PietdeBoer

iam now setting up a gentoo box on 3 250GB sata drives with the following layout:

software raid:

boot = raid1 2 disks

swap = raid5 3disks

root = raid5 3 disks

since iam now not using one disk... for boot.. shall i use it as a hot backup drive?

----------

