All of lore.kernel.org
 help / color / mirror / Atom feed
* Scrub?
@ 2004-08-06 18:07 Derek Listmail Acct
  2004-08-06 20:29 ` Scrub? Tim Moore
  0 siblings, 1 reply; 17+ messages in thread
From: Derek Listmail Acct @ 2004-08-06 18:07 UTC (permalink / raw)
  To: linux-raid

Many of the hardware raid controllers I've used have the ability to run a
'scrub' on an array.  Is there a way to do this on a linux software raid 5
array?



^ permalink raw reply	[flat|nested] 17+ messages in thread
* RE: Scrub?
@ 2004-08-06 18:26 Salyzyn, Mark
  2004-08-06 19:02 ` Scrub? Kanoa Withington
  2004-08-06 19:07 ` Scrub? Derek Listmail Acct
  0 siblings, 2 replies; 17+ messages in thread
From: Salyzyn, Mark @ 2004-08-06 18:26 UTC (permalink / raw)
  To: Derek Listmail Acct, linux-raid

dd if=/dev/zero of=/dev/md0 bs=200b

-----Original Message-----
From: linux-raid-owner@vger.kernel.org
[mailto:linux-raid-owner@vger.kernel.org] On Behalf Of Derek Listmail
Acct
Sent: Friday, August 06, 2004 2:07 PM
To: linux-raid@vger.kernel.org
Subject: Scrub?

Many of the hardware raid controllers I've used have the ability to run
a
'scrub' on an array.  Is there a way to do this on a linux software raid
5
array?


-
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] 17+ messages in thread
* RE: Scrub?
@ 2004-08-06 19:24 Salyzyn, Mark
  2004-08-06 19:41 ` Scrub? Mark Watts
  2004-08-06 19:44 ` Scrub? Kanoa Withington
  0 siblings, 2 replies; 17+ messages in thread
From: Salyzyn, Mark @ 2004-08-06 19:24 UTC (permalink / raw)
  To: Kanoa Withington; +Cc: Derek Listmail Acct, linux-raid

We have two RAID cards of different heritage over here with differing
definitions. One defines scrub as a means of erasing any content and
ensuring all blocks have correct parity or redundancy information; the
other defines it solely for RAID-5 to rebuild all the parity blocks. The
action in the second case resolves itself as a result of reading the bad
block.

Just reading the entire array should correct the bad blocks, so reverse
the sense of the dd:

	dd if=/dev/md0 of=/dev/null bs=200b

to find and replace the bad blocks (making the assumption that md works
like the H/W RAID cards).

Sincerely -- Mark Salyzyn

-----Original Message-----
From: Kanoa Withington [mailto:kanoa@cfht.hawaii.edu] 
Sent: Friday, August 06, 2004 3:03 PM
To: Salyzyn, Mark
Cc: Derek Listmail Acct; linux-raid@vger.kernel.org
Subject: RE: Scrub?

Eh, that would delete the contents of the array, including the
filesystem. Is that what you meant by "scrub"? I thought "scrubbing"
meant looking for unreadable blocks and pro-actively replacing them
from parity. The latter would be very useful for a software raid 5
array since there is currently no facility in software raid for doing
this on-the-fly. I imagine it would be possible to write such a
utility in user space. I, too, wonder if anyone out there has
something that works.

-Kanoa

On Fri, 6 Aug 2004, Salyzyn, Mark wrote:

> dd if=/dev/zero of=/dev/md0 bs=200b
>
> -----Original Message-----
> From: linux-raid-owner@vger.kernel.org
> [mailto:linux-raid-owner@vger.kernel.org] On Behalf Of Derek Listmail
> Acct
> Sent: Friday, August 06, 2004 2:07 PM
> To: linux-raid@vger.kernel.org
> Subject: Scrub?
>
> Many of the hardware raid controllers I've used have the ability to
run
> a
> 'scrub' on an array.  Is there a way to do this on a linux software
raid
> 5
> array?
>
>
> -
> 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
> -
> 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] 17+ messages in thread
* RE: Scrub?
@ 2004-08-07 14:48 Salyzyn, Mark
  2004-08-07 20:04 ` Scrub? Kanoa Withington
  2004-08-07 20:12 ` Scrub? dean gaudet
  0 siblings, 2 replies; 17+ messages in thread
From: Salyzyn, Mark @ 2004-08-07 14:48 UTC (permalink / raw)
  To: dean gaudet, Kanoa Withington; +Cc: Derek Listmail Acct, linux-raid

Problem with running the relocation is that the RAID-5 will now be
corrupt. The RAID-5 algorithm needs to be in-touch with disk block
relocation so that it can correct the parity and the data.

Sincerely -- Mark Salyzyn

-----Original Message-----
From: dean gaudet [mailto:dean-list-linux-raid@arctic.org] 
Sent: Friday, August 06, 2004 5:59 PM
To: Kanoa Withington
Cc: Salyzyn, Mark; Derek Listmail Acct; linux-raid@vger.kernel.org
Subject: RE: Scrub?

On Fri, 6 Aug 2004, Kanoa Withington wrote:

> On Fri, 6 Aug 2004, Salyzyn, Mark wrote:
> > Just reading the entire array should correct the bad blocks, so
reverse
> > the sense of the dd:
> >
> > 	dd if=/dev/md0 of=/dev/null bs=200b
> >
> > to find and replace the bad blocks (making the assumption that md
works
> > like the H/W RAID cards).
>
> In this case software RAID does not work like the H/W cards. Finding
> an unreadable block that way in a software array would cause it to go
> into a degraded state.

if the disks support SMART (i.e. they're less than a few years old) then
try running the smart long selftest... it can be done online and on many
disks it will force sector reallocation (and produce a SMART log event
so
you know it happenned).

get smartmontools and run "smartctl -a" to see info on your drive, and
"smartctl -t long" to launch the long test.  man page has more examples.

i run smart long tests on each my disks once a week (staggerred over
many
nights)... see /etc/smartd.conf.

-dean

^ permalink raw reply	[flat|nested] 17+ messages in thread
* RE: Scrub?
@ 2004-08-07 21:03 Salyzyn, Mark
  2004-08-08  0:51 ` Scrub? dean gaudet
  0 siblings, 1 reply; 17+ messages in thread
From: Salyzyn, Mark @ 2004-08-07 21:03 UTC (permalink / raw)
  To: dean gaudet; +Cc: Kanoa Withington, Derek Listmail Acct, linux-raid

As long as the relocation contains the original information; which is
only the case if the relocation is done on a write to the disk.

A RAID-5 generated relocation allows the data to be reconstructed on a
media failure on erad, and the relocation (triggered by a re-write)
would contain the correct information preventing corruption.

Sincerely -- Mark Salyzyn

-----Original Message-----
From: dean gaudet [mailto:dean-list-linux-raid@arctic.org] 
Sent: Saturday, August 07, 2004 4:13 PM
To: Salyzyn, Mark
Cc: Kanoa Withington; Derek Listmail Acct; linux-raid@vger.kernel.org
Subject: RE: Scrub?

no, that's not how it works.  i'm referring to the hard disk itself
relocating a sector -- it's transparent to the host/raid.  the only
thing
the raid software might see is that the disk will be less snappy while
it's running the SMART long test.  (mind you i do this on live busy
systems and i don't really tend to notice it -- although on particularly
busy weeks, some disks can take several days to complete their self test
in the few spare cycles they find.)

-dean

On Sat, 7 Aug 2004, Salyzyn, Mark wrote:

> Problem with running the relocation is that the RAID-5 will now be
> corrupt. The RAID-5 algorithm needs to be in-touch with disk block
> relocation so that it can correct the parity and the data.
>
> Sincerely -- Mark Salyzyn
>
> -----Original Message-----
> From: dean gaudet [mailto:dean-list-linux-raid@arctic.org]
> Sent: Friday, August 06, 2004 5:59 PM
> To: Kanoa Withington
> Cc: Salyzyn, Mark; Derek Listmail Acct; linux-raid@vger.kernel.org
> Subject: RE: Scrub?
>
> On Fri, 6 Aug 2004, Kanoa Withington wrote:
>
> > On Fri, 6 Aug 2004, Salyzyn, Mark wrote:
> > > Just reading the entire array should correct the bad blocks, so
> reverse
> > > the sense of the dd:
> > >
> > > 	dd if=/dev/md0 of=/dev/null bs=200b
> > >
> > > to find and replace the bad blocks (making the assumption that md
> works
> > > like the H/W RAID cards).
> >
> > In this case software RAID does not work like the H/W cards. Finding
> > an unreadable block that way in a software array would cause it to
go
> > into a degraded state.
>
> if the disks support SMART (i.e. they're less than a few years old)
then
> try running the smart long selftest... it can be done online and on
many
> disks it will force sector reallocation (and produce a SMART log event
> so
> you know it happenned).
>
> get smartmontools and run "smartctl -a" to see info on your drive, and
> "smartctl -t long" to launch the long test.  man page has more
examples.
>
> i run smart long tests on each my disks once a week (staggerred over
> many
> nights)... see /etc/smartd.conf.
>
> -dean
>

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

end of thread, other threads:[~2004-08-08  0:51 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-08-06 18:07 Scrub? Derek Listmail Acct
2004-08-06 20:29 ` Scrub? Tim Moore
  -- strict thread matches above, loose matches on Subject: below --
2004-08-06 18:26 Scrub? Salyzyn, Mark
2004-08-06 19:02 ` Scrub? Kanoa Withington
2004-08-06 19:07 ` Scrub? Derek Listmail Acct
2004-08-06 19:14   ` Scrub? Mark Watts
2004-08-06 19:24 Scrub? Salyzyn, Mark
2004-08-06 19:41 ` Scrub? Mark Watts
2004-08-06 20:03   ` Scrub? Mikael Abrahamsson
2004-08-06 19:44 ` Scrub? Kanoa Withington
2004-08-06 21:58   ` Scrub? dean gaudet
2004-08-07 14:48 Scrub? Salyzyn, Mark
2004-08-07 20:04 ` Scrub? Kanoa Withington
2004-08-07 20:19   ` Scrub? dean gaudet
2004-08-07 20:12 ` Scrub? dean gaudet
2004-08-07 21:03 Scrub? Salyzyn, Mark
2004-08-08  0:51 ` Scrub? dean gaudet

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.