Re: RAID 1 using SSD and 2 HDD

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

 



Le jeudi 28 juillet 2011 20:31:10 Doug Ledford, vous avez écrit :
> On 07/20/2011 08:59 AM, brian.foster@xxxxxxx wrote:
> >> -----Original Message-----
> >> From: linux-raid-owner@xxxxxxxxxxxxxxx [mailto:linux-raid-
> >> owner@xxxxxxxxxxxxxxx] On Behalf Of Mike Power
> >> Sent: Tuesday, July 19, 2011 3:14 PM
> >> To: Roman Mamedov
> >> Cc: linux-raid@xxxxxxxxxxxxxxx
> >> Subject: Re: RAID 1 using SSD and 2 HDD
> >> 
> >> Thanks for the link.  That is the kind of thing I am looking for.
> >> 
> >> On 07/19/2011 11:32 AM, Roman Mamedov wrote:
> >>> On Tue, 19 Jul 2011 11:15:22 -0700
> >>> 
> >>> Mike Power<mpower@xxxxxxxxxxxx>   wrote:
> >>>> Is it possible to implement a RAID 1 array using two equal size HDD
> >>>> and one smaller and faster SSD.  The idea being that the resulting
> >>>> RAID would have the same size of the HDD while picking up the speed
> >>>> benefits of the SSD.
> >>> 
> >>> See http://bcache.evilpiepirate.org/
> > 
> > Also, Roberto referred to the facebook flashcache implementation. It is
> > based on device-mapper and last I tried bcache, probably a bit more
> > production-worthy at the moment (though bcache looks intriguing long
> > term, so I'd suggest to try both and draw your own conclusion):
> > 
> > https://github.com/facebook/flashcache
> 
> Having not looked at those two, I can say that an md raid1 with two hard
> drives and one SSD works *very* well.  It's blazing fast.  Here's how I
> set mine up:
> 
> SSD: three partitions, one for boot, one for /, and one for ~/repos
> (which is where all my git/cvs/etc. checkouts reside)
> hard disks: four partitions, one for boot, one for /, one for /home, one
> for ~/repos
> 
> Then I created four raid1 arrays like so:
> 
> mdadm -C /dev/md/boot -l1 -n3 -e1.0 --bitmap=internal --name=boot
> /dev/sda1 --write-mostly --write-behind=128 /dev/sdb1 /dev/sdc1
> mdadm -C /dev/md/root -l1 -n3 -e1.2 --bitmap=internal --name=root
> /dev/sda2 --write-mostly --write-behind=1024 /dev/sdb2 /dev/sdc2
> mdadm -C /dev/md/home -l1 -n2 -e1.2 --bitmap=internal --name=home
> /dev/sdb3 /dev/sdc3
> mdadm -C /dev/md/repos -l1 -n3 -e1.2 --bitmap=internal --name=repos
> /dev/sda4 --write-mostly --write-behind=1024 /dev/sdb4 /dev/sdc4
> 
> Works for me with stellar performance.  Treats the SSD as the only
> device that matters on the three arrays it participates in with the hard
> drives there merely as a backing store for safety in case the SSD blows
> chunks some day.  Obviously, if you need some other aspect of your home
> directory to have the SSD benefit then modify to your tastes, but all my
> scratch builds happen under ~/repos and the thing flies when compiling
> stuff compared to how it used to be.


One thing you didn't said is the respective size of the SSD and HD partitions. 
How did you determine them?

Xavier
xavier@xxxxxxxxxxxxxx
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux