All of lore.kernel.org
 help / color / mirror / Atom feed
From: Doug Ledford <dledford@redhat.com>
To: brian.foster@emc.com
Cc: mpower@dodtsair.com, rm@romanrm.ru, linux-raid@vger.kernel.org
Subject: Re: RAID 1 using SSD and 2 HDD
Date: Thu, 28 Jul 2011 14:31:10 -0400	[thread overview]
Message-ID: <4E31AAEE.30601@redhat.com> (raw)
In-Reply-To: <24EACA6AC4B506428C92FE7C172FEF4E02084CF0@MX16A.corp.emc.com>

On 07/20/2011 08:59 AM, brian.foster@emc.com wrote:
>> -----Original Message-----
>> From: linux-raid-owner@vger.kernel.org [mailto:linux-raid-
>> owner@vger.kernel.org] On Behalf Of Mike Power
>> Sent: Tuesday, July 19, 2011 3:14 PM
>> To: Roman Mamedov
>> Cc: linux-raid@vger.kernel.org
>> 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@dodtsair.com>   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.


  reply	other threads:[~2011-07-28 18:31 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-19 18:15 RAID 1 using SSD and 2 HDD Mike Power
2011-07-19 18:27 ` Roberto Spadim
2011-07-28 18:32   ` Doug Ledford
     [not found]     ` <CABYL=To6GFBwsHi_2y6Rzgvr3LbP2Z9hUN8QjYP5Wf+vJtKsXw@mail.gmail.com>
2011-07-29 13:30       ` Doug Ledford
2011-07-29 14:55         ` David Brown
2011-07-29 15:30           ` Doug Ledford
2011-07-29 15:51             ` Roberto Spadim
2011-07-19 18:32 ` Roman Mamedov
2011-07-19 19:13   ` Mike Power
2011-07-20 12:59     ` brian.foster
2011-07-28 18:31       ` Doug Ledford [this message]
2011-07-28 23:53         ` Xavier Brochard
2011-07-29  9:32           ` John Robinson
2011-07-29 13:38             ` Doug Ledford
2011-07-29 17:50             ` Xavier Brochard
2011-07-29 18:31               ` Doug Ledford
2011-07-29 16:20 ` Failures Rates Using SSD maurice

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4E31AAEE.30601@redhat.com \
    --to=dledford@redhat.com \
    --cc=brian.foster@emc.com \
    --cc=linux-raid@vger.kernel.org \
    --cc=mpower@dodtsair.com \
    --cc=rm@romanrm.ru \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.