linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Austin S. Hemmelgarn" <ahferroin7@gmail.com>
To: matianfu@gmail.com, linux-btrfs@vger.kernel.org
Subject: Re: mix ssd and hdd in single volume
Date: Mon, 3 Apr 2017 08:23:24 -0400	[thread overview]
Message-ID: <d35eb3bd-02f7-c6be-e3de-2ebbb911a378@gmail.com> (raw)
In-Reply-To: <CAEgruXvAEBfpQaAxCi42Vq6v8w7v1dqthpn9TpE3FDDHoTWRcw@mail.gmail.com>

On 2017-04-01 02:06, UGlee wrote:
> We are working on a small NAS server for home user. The product is
> equipped with a small fast SSD (around 60-120GB) and a large HDD (2T
> to 4T).
>
> We have two choices:
>
> 1. using bcache to accelerate io operation
> 2. combining SSD and HDD into a single btrfs volume.
>
> Bcache is certainly designed for our purpose. But bcache requires
> complex configuration and can only start from clean disk. Also in our
> test in Ubuntu 16.04, data inconsistence was observed at least once,
> resulting total HDD data lost.
>
> So we wonder if simply putting SSD and HDD into a single btrfs volume,
> in whatever mode, the general read operation (mostly readdir and
> getxattr) will also be significantly faster than a single HDD without
> SSD.

Have you tried dm-cache?  The general idea is similar to bcache, but 
it's been much more reliable in my experience, and it's possible to add 
it to an existing device without any need for reprovisioning  (although 
the existing device can't have any pending writes, otherwise you might 
get some data corruption).

Additionally, given what you've said, write-through mode should cover 
what you need in terms of performance, and may be more reliable on 
bcache than writeback mode.


      parent reply	other threads:[~2017-04-03 12:23 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-01  6:06 mix ssd and hdd in single volume UGlee
2017-04-02  0:13 ` Duncan
2017-04-03  8:30   ` Marat Khalili
2017-04-03  8:41     ` Roman Mamedov
2017-04-07  3:12       ` Duncan
2017-04-03 12:23 ` Austin S. Hemmelgarn [this message]

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=d35eb3bd-02f7-c6be-e3de-2ebbb911a378@gmail.com \
    --to=ahferroin7@gmail.com \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=matianfu@gmail.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).