All of lore.kernel.org
 help / color / mirror / Atom feed
* Speeding up reading with RAID1 and --write-mostly
@ 2014-09-13  6:01 martin f krafft
  2014-09-13 11:56 ` Ethan Wilson
       [not found] ` <CAH3kUhGEaon77fpNm2mjRwPbNMZe9BLK3eA6LTB4xQeg0hMF-Q@mail.gmail.com>
  0 siblings, 2 replies; 5+ messages in thread
From: martin f krafft @ 2014-09-13  6:01 UTC (permalink / raw)
  To: linux-raid

[-- Attachment #1: Type: text/plain, Size: 1075 bytes --]

Hello,

my laptop still has a rotational disk, and also a MMC reader, which
I never use. Having seen some SSD laptops do things blazingly fast,
I wondered if I couldn't use the MMC to help.

Assuming there is a MMC fast enough out there, how about creating
a RAID1 across MMC and parts of the rotational disk, with the
rotational disk flagged --write-mostly? This RAID would then hold
the system, while the data would sit on the rotational disk.

The theory here is that writing is going to be expensive either way,
but most of system use is reading anyway.

Does this sound like an idea worth pursuing? I am asking because
I don't really want to experiment using this laptop, which is
currently my only machine. Have you done this? Have you any
thoughts? Or is this just a bad idea?

I would appreciate CCs on replies.

-- 
@martinkrafft | http://madduck.net/ | http://two.sentenc.es/
 
"without a god, life is only a matter of opinion."
                                                    -- douglas adams
 
spamtraps: madduck.bogus@madduck.net

[-- Attachment #2: Digital signature (see http://martin-krafft.net/gpg/sig-policy/999bbcc4/current) --]
[-- Type: application/pgp-signature, Size: 1107 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Speeding up reading with RAID1 and --write-mostly
  2014-09-13  6:01 Speeding up reading with RAID1 and --write-mostly martin f krafft
@ 2014-09-13 11:56 ` Ethan Wilson
       [not found] ` <CAH3kUhGEaon77fpNm2mjRwPbNMZe9BLK3eA6LTB4xQeg0hMF-Q@mail.gmail.com>
  1 sibling, 0 replies; 5+ messages in thread
From: Ethan Wilson @ 2014-09-13 11:56 UTC (permalink / raw)
  To: linux-raid

On 13/09/2014 08:01, martin f krafft wrote:
> Assuming there is a MMC fast enough out there, how about creating
> a RAID1 across MMC and parts of the rotational disk, with the
> rotational disk flagged --write-mostly? This RAID would then hold
> the system, while the data would sit on the rotational disk.

1) Firstly, MMC, SD etc are all very slow in random access. They are 
optimized for physical size and not for speed.

2) Secondly, in order to use --write-mostly, you need two devices of the 
same size, so you need an MMC as big as your HDD.

Something different from (2) is called SSD-caching, and in Linux kernel 
there are two approaches to do that, one is dm-cache and the other is 
bcache. Both are very young and I don't know how much stable.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Speeding up reading with RAID1 and --write-mostly
       [not found] ` <CAH3kUhGEaon77fpNm2mjRwPbNMZe9BLK3eA6LTB4xQeg0hMF-Q@mail.gmail.com>
@ 2014-09-13 16:23   ` martin f krafft
  2014-09-15  4:11     ` NeilBrown
  2014-09-15  7:44   ` martin f krafft
  1 sibling, 1 reply; 5+ messages in thread
From: martin f krafft @ 2014-09-13 16:23 UTC (permalink / raw)
  To: linux-raid

[-- Attachment #1: Type: text/plain, Size: 600 bytes --]

also sprach Roberto Spadim <roberto@spadim.com.br> [2014-09-13 13:56 +0200]:
> Try a bcache or something like it

The problem with a cache is that the data have to be read once from
the slow disk anyway, whereas I am proposing to keep a shadow copy
on rotational disk, really, just in case the MMC may need to be
removed at some point.

-- 
@martinkrafft | http://madduck.net/ | http://two.sentenc.es/
 
"a fundamentalist is someone who hates sin more than he loves virtue."
                                                     -- john h. schaar
 
spamtraps: madduck.bogus@madduck.net

[-- Attachment #2: Digital signature (see http://martin-krafft.net/gpg/sig-policy/999bbcc4/current) --]
[-- Type: application/pgp-signature, Size: 1107 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Speeding up reading with RAID1 and --write-mostly
  2014-09-13 16:23   ` martin f krafft
@ 2014-09-15  4:11     ` NeilBrown
  0 siblings, 0 replies; 5+ messages in thread
From: NeilBrown @ 2014-09-15  4:11 UTC (permalink / raw)
  To: martin f krafft; +Cc: linux-raid

[-- Attachment #1: Type: text/plain, Size: 795 bytes --]

On Sat, 13 Sep 2014 18:23:01 +0200 martin f krafft <madduck@madduck.net>
wrote:

> also sprach Roberto Spadim <roberto@spadim.com.br> [2014-09-13 13:56 +0200]:
> > Try a bcache or something like it
> 
> The problem with a cache is that the data have to be read once from
> the slow disk anyway, whereas I am proposing to keep a shadow copy
> on rotational disk, really, just in case the MMC may need to be
> removed at some point.
> 

It is a persistent cache though.  So it only needs to be read once.
If the cache SD is the same sizes as the main device then it should never
ever need to read again.

But I suspect you will find that SD cards aren't really fast enough for your
needs.  It wouldn't hurt to experiment on just an SD card and see how it
performs.

NeilBrown

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 828 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Speeding up reading with RAID1 and --write-mostly
       [not found] ` <CAH3kUhGEaon77fpNm2mjRwPbNMZe9BLK3eA6LTB4xQeg0hMF-Q@mail.gmail.com>
  2014-09-13 16:23   ` martin f krafft
@ 2014-09-15  7:44   ` martin f krafft
  1 sibling, 0 replies; 5+ messages in thread
From: martin f krafft @ 2014-09-15  7:44 UTC (permalink / raw)
  To: Roberto Spadim, NeilBrown; +Cc: linux-raid

[-- Attachment #1: Type: text/plain, Size: 921 bytes --]

also sprach Roberto Spadim <roberto@spadim.com.br> [2014-09-13 13:56 +0200]:
> Try a bcache or something like it

also sprach NeilBrown <neilb@suse.de> [2014-09-15 06:11 +0200]:
> It is a persistent cache though.

Oh cool, and it optimises writing too, I'll definitely will check it
out, thank you!

> But I suspect you will find that SD cards aren't really fast
> enough for your needs.  It wouldn't hurt to experiment on just an
> SD card and see how it performs.

Sure, and this will be much easier to set up. However, even my cheap
camera SD outperforms my rotational disk, especially with dmcrypt…

-- 
@martinkrafft | http://madduck.net/ | http://two.sentenc.es/
 
an egg has the shortest sex-life of all: if gets laid once; it gets
eaten once. it also has to come in a box with 11 others, and the
only person who will sit on its face is its mother.
 
spamtraps: madduck.bogus@madduck.net

[-- Attachment #2: Digital signature (see http://martin-krafft.net/gpg/sig-policy/999bbcc4/current) --]
[-- Type: application/pgp-signature, Size: 1107 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2014-09-15  7:44 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-13  6:01 Speeding up reading with RAID1 and --write-mostly martin f krafft
2014-09-13 11:56 ` Ethan Wilson
     [not found] ` <CAH3kUhGEaon77fpNm2mjRwPbNMZe9BLK3eA6LTB4xQeg0hMF-Q@mail.gmail.com>
2014-09-13 16:23   ` martin f krafft
2014-09-15  4:11     ` NeilBrown
2014-09-15  7:44   ` martin f krafft

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.