Subject: Re: mount a raidframe partition
To: None <netbsd-help@netbsd.org>
From: Pierre-Philipp Braun <pbraun@nethence.com>
List: netbsd-help
Date: 02/27/2005 19:14:24
Hi fellows,

     when trying boot any working NetBSD 2.0 /sparc64 with this attached 
RAIDframe partitioned harddrive (wd1), I get into kernel debugger.

This attached HD comes from a netbsd/sparc64 box, which freezed, hence 
didn't umount the partitions, which were in activity and mounted with 
async (yes, bad idea).

However, I shouldn't enter into kernel debugger when trying to recover 
the data. Here's the output and backtrace,

[snip]
atabus0 at cmdide0 channel 0
cmdide0: secondary channel configured to native-PCI mode
atabus1 at cmdide0 channel 1
ppb1 at pci0 dev 1 function 0: Sun Microsystems, Inc. Simba PCI bridge 
(rev. 0x)
pci2 at ppb1 bus 2
pci2: i/o space, memory space enabled
pcons at mainbus0 not configured
No counter-timer -- using %tick at 360MHz as system clock.
Kernelized RAIDframe activated
wd0 at atabus0 drive 0: <ST38420A>
wd0: drive supports 16-sector PIO transfers, LBA addressing
wd0: 8223 MB, 16708 cyl, 16 head, 63 sec, 512 bytes/sect x 16841664 sectors
wd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 2 (Ultra/33)
wd0(cmdide0:0:0): using PIO mode 4, DMA mode 2 (using DMA data transfers)
wd1 at atabus1 drive 0: <ST3120023A>
wd1: drive supports 16-sector PIO transfers, LBA addressing
wd1: 111 GB, 232581 cyl, 16 head, 63 sec, 512 bytes/sect x 234441648 sectors
wd1: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 5 (Ultra/100)
wd1(cmdide0:1:0): using PIO mode 4, DMA mode 2 (using DMA data transfers)
raid0: RAID Level 1
raid0: Components: /dev/wd1a component1[**FAILED**]
raid0: Total Sectors: 234441472 (114473 MB)
root on raid0a dumps on raid0b
WARNING: clock gained 17 days -- CHECK AND RESET THE DATE!
root file system type: ffs
Sun Feb 27 11:57:57 CET 2005
swapctl: adding /dev/raid0b as swap device at priority 0
swapctl: setting dump device to /dev/wd0b
Checking for botched superblock upgrades: done.
Starting file system checks:
1042308216 BAD I=9205
/dev/rraid0a: UNEXPECTED INCONSISTENCY; RUN fsck_ffs MANUALLY.
Automatic file system check failed; help!
Feb 27 11:57:58 init: /bin/sh on /etc/rc terminated abnormally, going to 
singlee
Feb 27 11:58:00 init: fatal signal: Segmentation fault
Sun Feb 27 11:58:32 CET 2005
swapctl: /dev/raid0b: Device busy
swapctl: setting dump device to /dev/wd0b
Checking for botched superblock upgrades: done.
Starting file system checks:
1042308216 BAD I=9205
/dev/rraid0a: UNEXPECTED INCONSISTENCY; RUN fsck/dev/raid0a: file system 
not cl)
/dev/raid0a: lost blocks 0 files 0
_ffs MANUALLY.
Automatic file system check failed; help!
dev = 0x1900, block = 1501958, fs = /
panic: blkfree: freeing free frag
kdb breakpoint at 1335d58
Stopped in pid 177.1 (rm) at    netbsd:cpu_Debugger+0x4:        nop
db> continue
syncing disks... panic: lockmgr: locking against myself
kdb breakpoint at 1335d58
Stopped in pid 177.1 (rm) at    netbsd:cpu_Debugger+0x4:        nop
db> bt
lockmgr(5ef0ff0, 10, 5ef0f30, 11, fffffffffffffffc, 1816c00) at 
netbsd:lockmgr+0
x1e4
VOP_LOCK(5ef0f30, 10012, 1497740, 0, 5ef0f30, 9e0) at netbsd:VOP_LOCK+0x28
vn_lock(5ef0f30, 10012, 5ef1e10, 0, 700, 1) at netbsd:vn_lock+0x88
vget(0, 10012, 0, 5ef24e0, 0, 18178d8) at netbsd:vget+0xb8
ffs_sync(1f38a00, 2, 1e4df00, 5ef24e0, 0, 11) at netbsd:ffs_sync+0x1cc
sys_sync(1817800, 0, 0, 8000000000000000, 121a52c, 0) at 
netbsd:sys_sync+0xdc
vfs_shutdown(1496c00, 101, 1335d58, 820006, 0, 1) at 
netbsd:vfs_shutdown+0x58
cpu_reboot(100, 0, 0, 0, 0, 0) at netbsd:cpu_reboot+0x1ac
panic(148da08, 1900, 16eb06, 1f478d4, 8, 1816c00) at netbsd:panic+0x14c
ffs_blkfree(62309b0, 16eb06, 800, 0, 0, 1f35400) at netbsd:ffs_blkfree+0x50
ffs_truncate(4, 62309b8, 0, 0, 0, 62376f0) at netbsd:ffs_truncate+0x720
VOP_TRUNCATE(62326c0, 0, 0, ffffffffffffffff, 5ef24e0, 4221a7d9) at 
netbsd:VOP_T
RUNCATE+0x34
ufs_inactive(0, 128, 6237988, 6237980, 2, 5ef0f30) at 
netbsd:ufs_inactive+0x280
VOP_INACTIVE(62326c0, 5ef24e0, 0, 5ef24e0, 0, 18178d8) at 
netbsd:VOP_INACTIVE+0x
28
ufs_remove(0, 5e8c400, ffffffffffffffff, 6237c30, 6234000, 0) at 
netbsd:ufs_remo
ve+0x78
VOP_REMOVE(5ef0f30, 62326c0, 6237c48, 2, 6237dd0, 30) at 
netbsd:VOP_REMOVE+0x2c
sys_unlink(62326c0, 6237dd0, 6237dc0, 0, 6237dd0, 0) at 
netbsd:sys_unlink+0x114
syscall(6237ed0, a, 40531b54, 6237dd0, 40531b54, 40531b58) at 
netbsd:syscall+0xd
4
?(20a000, 206980, 0, 203000, 406c84a0, 2) at 0x1008cb8
db>


Any advice?
thanks