On 17/09/2009, at 4:27 PM, Jeffrey C. Smith wrote:
quoted text > Paul M wrote:
>> On 16/09/2009, at 10:46 AM, Jeffrey C. Smith wrote:
>>> I am trying to add a new drive to replace a failed drive on my RAID1
>>> OpenBSD system. I have read the available documentation but can't
>>> get the drive added permanently. Here's what I've done so far-
>>>
>>> ...
>>>
>>> Any feedback would be most appreciated...
>> You did not state what the failed disk was - was it also wd1d?
>
> Sorry. Yes it is...
>
>> So, you replaced the failed drive, then configured this new drive as
>> a spare, and then reconstructed onto it. Is that correct?
>
> Yes. And as a spare the array is up and healthy:
>
> # raidctl -s raid0
> raid0 Components:
> /dev/wd0d: optimal
> component1: spared
> Spares:
> /dev/wd1d: used_spare
> Parity status: clean
> Reconstruction is 100% complete.
> Parity Re-write is 100% complete.
> Copyback is 100% complete.
>
>> I think this is wrong because the new disk is not a spare, it is one
>> of the components.
>> I think what you need is the -R option to raidctl, rather than the -F
>> option.
>
> OK. So I rebooted and the status is now failed:
>
> # raidctl -s raid0
> raid0 Components:
> /dev/wd0d: optimal
> component1: failed
> No spares.
> Parity status: clean
> Reconstruction is 100% complete.
> Parity Re-write is 100% complete.
> Copyback is 100% complete.
>
> I try the -R option:
>
> # raidctl -v -R component1 raid0
> Reconstruction status:
>
> It doesn't complain and comes back almost immediately (strange). I
> check status again:
>
> # raidctl -s raid0
> raid0 Components:
> /dev/wd0d: optimal
> component1: failed
> No spares.
> Parity status: clean
> Reconstruction is 100% complete.
> Parity Re-write is 100% complete.
> Copyback is 100% complete.
>
> Says reconstruction is complete but the device is still failed? Maybe
> it wants the device name:
>
> #raidctl -v -R wd1d raid0
> raidctl: wd1d is not a component of this device
>
> Nope. Seems "component1" is the correct name.
>
> So, it does not complain when I run the reconstruct command (raidctl
> -v -R component1 raid0) and it even starts the reconstruction progress
> indicator. But, it quickly returns after that and does not seem to do
> anything?
>
> To recap, seems the only way I can get the drive into the array is to
> add it as a spare and us the -F option to reconstruct it. After that
> the array is up and healthy. If I reboot the wd1 drive (component1)
> fails and I'm back to where I started.
>
> Any ideas out there???
>
> Thanks much,
> Jeff
>
According to the man page (if my memory is correct), the name
"component1" is a placeholder used by raidctl when it is unable to
access the drive - in other words this component is bad. Remove the
drive completely and it will still list it as "component1". So
"component1" is not the name.
You need to use (again, if my memory is correct):
# raidctl -v -R /dev/wd1d raid0
paulm