Hi!
(Note: This is on a Synology DS209J, running 10.0 of NetBSD/sandpoint!)
After a power failure I got a problem with the /dev/wd1a component
of my /dev/wd0a + /dev/wd1a RAID-1 and the parity couldn't be
rewritten:
raid0: Error re-writing parity (1)!
# raidctl -s raid0
Components:
/dev/wd0a: optimal
/dev/wd1a: failed
No spares.
Component label for /dev/wd0a:
Row: 0, Column: 0, Num Rows: 1, Num Columns: 2
Version: 2, Serial Number: 2024073001, Mod Counter: 253
Clean: No, Status: 0
sectPerSU: 128, SUsPerPU: 1, SUsPerRU: 1
Queue size: 100, blocksize: 512, numBlocks: 134209408
RAID Level: 1
Autoconfig: Yes
Root partition: Force
Last configured as: raid0
/dev/wd1a status is: failed. Skipping label.
Parity status: DIRTY
Reconstruction is 100% complete.
Parity Re-write is 100% complete.
Copyback is 100% complete.
I tried to reconstruct the failed component from wd0, but raidctl
insists that it doesn't know wd1a:
# raidctl -f /dev/wd1a raid0
raidctl: no match for `wd1a'
# raidctl -a /dev/wd1a raid0
raidctl: no match for `wd1a'
# raidctl -F /dev/wd1a raid0
raidctl: no match for `wd1a'
Then I deleted the MBR and diskabel from wd1 and rebooted.
Now "raidctl -s raid0" shows "component1" instead of wd1a, but the
problem is similar. After restoring (and verifying!) the MBR and
the disklabel I still cannot add wd1a as a spare:
# raidctl -f component1 raid0
# raidctl -a /dev/wd1a raid0
raidctl: no match for `wd1a'
# disklabel wd1
[...]
5 partitions:
# size offset fstype [fsize bsize cpg/sgs]
a: 134209536 4096 RAID # (Cyl.
4*- 133148*)
c: 4294967295 0 unused 0 0 # (Cyl. 0
- 4294967295*)
I'm confused. Because I definitely followed a similar approach when
I initially created the RAID. And that worked.
The rest of that 4TB disk is managed via a wedge and GPT. In case
it is related, the wedge and a second RAID is added in /etc/rc.local:
[...]
/sbin/dkctl wd0 addwedge NASwd0 134220240 7679816928 raidframe
/sbin/dkctl wd1 addwedge NASwd1 134220240 7679816928 raidframe
/sbin/raidctl -c /etc/raid1.conf raid1
/bin/sleep 1
# NASdata wedge should now exist via GPT from raid1
/sbin/fsck NAME=NASdata
/sbin/mount NAME=NASdata
Any ideas?