All of lore.kernel.org
 help / color / mirror / Atom feed
* raid1 mirror optimizations
@ 2011-01-25 18:56 Roberto Spadim
  2011-01-25 20:19 ` Oliver Brakmann
  2011-01-26  9:49 ` David Brown
  0 siblings, 2 replies; 7+ messages in thread
From: Roberto Spadim @ 2011-01-25 18:56 UTC (permalink / raw)
  To: Linux-RAID

hi guys... i have a damaged disk...
i´m using raid1
the computer crashed with the floor :P hihiih sorry, but the disks are
damaged at the same position
check: http://www.spadim.com.br/hd%20agra.zip
the problem: since raid1 (mirror) is done with real mirror, the disk
position are the same...
if i was using a mirror but on disk 1 i write from beggining to end,
and disk 2 from end to beggining , i don´t crash the disk at the same
position, for disk 1 i crash it some bytes, for disk 2 i crash some
others bytes, since beggining is a small cilinder and end a bigger, i
could loose less information than mirror
could we implement a 'inverted' mirror? just for hard disks (for ssd
it´s a small loss of cpu/memory)
thanks

-- 
Roberto Spadim
Spadim Technology / SPAEmpresarial
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: raid1 mirror optimizations
  2011-01-25 18:56 raid1 mirror optimizations Roberto Spadim
@ 2011-01-25 20:19 ` Oliver Brakmann
  2011-01-26 15:39   ` Roberto Spadim
  2011-01-26  9:49 ` David Brown
  1 sibling, 1 reply; 7+ messages in thread
From: Oliver Brakmann @ 2011-01-25 20:19 UTC (permalink / raw)
  To: linux-raid

Hi,

On 2011-01-25 19:56, Roberto Spadim wrote:
> could we implement a 'inverted' mirror? just for hard disks (for ssd
> it´s a small loss of cpu/memory)

If I understood that correctly, this is exactly what the raid10 'far'
layout does.

Regards,
Oliver

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

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

* Re: raid1 mirror optimizations
  2011-01-25 18:56 raid1 mirror optimizations Roberto Spadim
  2011-01-25 20:19 ` Oliver Brakmann
@ 2011-01-26  9:49 ` David Brown
  2011-01-26 14:18   ` Roberto Spadim
  1 sibling, 1 reply; 7+ messages in thread
From: David Brown @ 2011-01-26  9:49 UTC (permalink / raw)
  To: linux-raid

On 25/01/2011 19:56, Roberto Spadim wrote:
> hi guys... i have a damaged disk...
> i´m using raid1
> the computer crashed with the floor :P hihiih sorry, but the disks are
> damaged at the same position
> check: http://www.spadim.com.br/hd%20agra.zip
> the problem: since raid1 (mirror) is done with real mirror, the disk
> position are the same...
> if i was using a mirror but on disk 1 i write from beggining to end,
> and disk 2 from end to beggining , i don´t crash the disk at the same
> position, for disk 1 i crash it some bytes, for disk 2 i crash some
> others bytes, since beggining is a small cilinder and end a bigger, i
> could loose less information than mirror
> could we implement a 'inverted' mirror? just for hard disks (for ssd
> it´s a small loss of cpu/memory)
> thanks
>

If you are worried about the disks being in the same position, then I 
assume you mean the heads were in the same position when they crashed 
into the disk.  If that's the case, then it doesn't really matter too 
much if the same bytes on the disk were hit - your disks are trashed 
anyway, and you'll need expensive professional recovery services to deal 
with it.

If you are not talking about head crashes, and merely about corruption 
because the disks were being written to in the same place on both disks, 
then the layout on the disk will make little difference - the same data 
will be written to the same logical place at roughly the same time.  It 
doesn't matter where this data is located physically on the disk, since 
it is the data that matters.  The same thing actually applies to head 
crashes too.

If you really want an "inverted" mirror, there is an easy way to get 
much of the same effect.  Instead of setting up raid1, use raid10 with 
"far 2" positioning.  The effect is roughly like this:

disk1 (stripe 1) (mirror of stripe 2)
disk2 (stripe 2) (mirror of stripe 1)

So the two copies of the data are in different physical positions on 
each disk.  It's not a full reversal, but you can think of disk 2 as 
being split in two and its two halves swapped.


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

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

* Re: raid1 mirror optimizations
  2011-01-26  9:49 ` David Brown
@ 2011-01-26 14:18   ` Roberto Spadim
  0 siblings, 0 replies; 7+ messages in thread
From: Roberto Spadim @ 2011-01-26 14:18 UTC (permalink / raw)
  To: David Brown; +Cc: linux-raid

nice :) i never read about it on raid 10, maybe i could use, thanks!

2011/1/26 David Brown <david@westcontrol.com>:
> On 25/01/2011 19:56, Roberto Spadim wrote:
>>
>> hi guys... i have a damaged disk...
>> i惴 using raid1
>> the computer crashed with the floor :P hihiih sorry, but the disks are
>> damaged at the same position
>> check: http://www.spadim.com.br/hd%20agra.zip
>> the problem: since raid1 (mirror) is done with real mirror, the disk
>> position are the same...
>> if i was using a mirror but on disk 1 i write from beggining to end,
>> and disk 2 from end to beggining , i don愒 crash the disk at the same
>> position, for disk 1 i crash it some bytes, for disk 2 i crash some
>> others bytes, since beggining is a small cilinder and end a bigger, i
>> could loose less information than mirror
>> could we implement a 'inverted' mirror? just for hard disks (for ssd
>> it愀 a small loss of cpu/memory)
>> thanks
>>
>
> If you are worried about the disks being in the same position, then I assume
> you mean the heads were in the same position when they crashed into the
> disk.  If that's the case, then it doesn't really matter too much if the
> same bytes on the disk were hit - your disks are trashed anyway, and you'll
> need expensive professional recovery services to deal with it.
>
> If you are not talking about head crashes, and merely about corruption
> because the disks were being written to in the same place on both disks,
> then the layout on the disk will make little difference - the same data will
> be written to the same logical place at roughly the same time.  It doesn't
> matter where this data is located physically on the disk, since it is the
> data that matters.  The same thing actually applies to head crashes too.
>
> If you really want an "inverted" mirror, there is an easy way to get much of
> the same effect.  Instead of setting up raid1, use raid10 with "far 2"
> positioning.  The effect is roughly like this:
>
> disk1 (stripe 1) (mirror of stripe 2)
> disk2 (stripe 2) (mirror of stripe 1)
>
> So the two copies of the data are in different physical positions on each
> disk.  It's not a full reversal, but you can think of disk 2 as being split
> in two and its two halves swapped.
>
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-raid" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>



-- 
Roberto Spadim
Spadim Technology / SPAEmpresarial
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: raid1 mirror optimizations
  2011-01-25 20:19 ` Oliver Brakmann
@ 2011-01-26 15:39   ` Roberto Spadim
  2011-01-26 16:37     ` Oliver Brakmann
  0 siblings, 1 reply; 7+ messages in thread
From: Roberto Spadim @ 2011-01-26 15:39 UTC (permalink / raw)
  To: Oliver Brakmann; +Cc: linux-raid

i don't know what layout does, but, does raid1 have layout?

2011/1/25 Oliver Brakmann <obrakmann@gmx.net>:
> Hi,
>
> On 2011-01-25 19:56, Roberto Spadim wrote:
>> could we implement a 'inverted' mirror? just for hard disks (for ssd
>> it´s a small loss of cpu/memory)
>
> If I understood that correctly, this is exactly what the raid10 'far'
> layout does.
>
> Regards,
> Oliver
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-raid" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>



-- 
Roberto Spadim
Spadim Technology / SPAEmpresarial
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: raid1 mirror optimizations
  2011-01-26 15:39   ` Roberto Spadim
@ 2011-01-26 16:37     ` Oliver Brakmann
  2011-01-26 21:08       ` David Brown
  0 siblings, 1 reply; 7+ messages in thread
From: Oliver Brakmann @ 2011-01-26 16:37 UTC (permalink / raw)
  To: linux-raid

On 2011-01-26 16:39, Roberto Spadim wrote:
> i don't know what layout does, but, does raid1 have layout?

No, only raid10 has different layouts.  For an explanation, see David's
mail, or take a look at the Wikipedia entry for non-standard RAID
levels, it illustrates the idea of the different layouts quite well,
IMO: http://en.wikipedia.org/wiki/Non-standard_RAID_levels#Linux_MD_RAID_10



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

* Re: raid1 mirror optimizations
  2011-01-26 16:37     ` Oliver Brakmann
@ 2011-01-26 21:08       ` David Brown
  0 siblings, 0 replies; 7+ messages in thread
From: David Brown @ 2011-01-26 21:08 UTC (permalink / raw)
  To: linux-raid

On 26/01/11 17:37, Oliver Brakmann wrote:
> On 2011-01-26 16:39, Roberto Spadim wrote:
>> i don't know what layout does, but, does raid1 have layout?
>
> No, only raid10 has different layouts.  For an explanation, see David's
> mail, or take a look at the Wikipedia entry for non-standard RAID
> levels, it illustrates the idea of the different layouts quite well,
> IMO: http://en.wikipedia.org/wiki/Non-standard_RAID_levels#Linux_MD_RAID_10
>

There are also different layouts for raid5 and raid6, though I don't 
think they make much difference unless you are doing something odd like 
trying to make your mdadm raid5/6 layout exactly match that of some 
hardware raid controller.  There are also special layouts that are used 
as intermediary steps in converting between raid5 and raid6 - you won't 
want to touch these.

So raid10 is the only level with /useful/ layout options.  The different 
options can make a measurable speed difference, with the best choice 
depending on the load.  The "far 2" layout is, I think, the best choice 
for common ready-heavy loads.



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

end of thread, other threads:[~2011-01-26 21:08 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-01-25 18:56 raid1 mirror optimizations Roberto Spadim
2011-01-25 20:19 ` Oliver Brakmann
2011-01-26 15:39   ` Roberto Spadim
2011-01-26 16:37     ` Oliver Brakmann
2011-01-26 21:08       ` David Brown
2011-01-26  9:49 ` David Brown
2011-01-26 14:18   ` Roberto Spadim

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.