Subject: port-amiga/1038: panic!
To: None <gnats-admin@sun-lamp.cs.berkeley.edu>
From: None <henric@eci1.ucsb.edu>
List: netbsd-bugs
Date: 05/08/1995 18:35:03
>Number:         1038
>Category:       port-amiga
>Synopsis:       root fs panic
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    gnats-admin (GNATS administrator)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon May  8 18:35:01 1995
>Originator:     Henric Jungheim
>Organization:
Henric Jungheim  --  uhenric@mcl.ucsb.edu  --  henric@engineering.ucsb.edu
>Release:        sup'ed current as of May 8th <NetBSD-current source date>
>Environment:
	
System: NetBSD blurg.ucsb.edu 1.0A NetBSD 1.0A (HENRIC) #30: Mon May 8 05:18:47 PDT 1995 root@blurg.ucsb.edu:/usr/src/sys/arch/amiga/compile/HENRIC amiga
A4000/040 running 2 scsi drives on a GVP4008.

>Description:
	
I have now experienced several panics from my root file system (i.e., "/").
The first was experienced during the vm_pageout.c/"can't get here" incident,
but it has happend again afterwards.

I was very careful to note exactly what I did the last time it happend:
I was running in 'rxvt' under X11.  I just did a cp netbsd / from the
compile dir (the kernel I was running on already had the "vm_pageout.c" 
fix), then "sync" (several times), and "cp /netbsd /dev/reload".  The 
cursor immediately froze and then the computer just sat there (no disk
activity that I could hear).  I let it sit for about a minute and then
did a ctrl-amiga-amiga.  The machine booted properly (into X via xdm)
and I did an su, a few "sync"s, then "kill -TERM 1".  When I got
the single-user shell, I "umount -av", then "fsck /dev/rsd0a".  It
found a few problems (sorry, I didn't write them down), and I said "y"
to all questions.  Immediately after it finished, I typed "reboot".
AmigaDOS started, which then loadbsd -Aa'ed (it's in my startup).  The
startup got as far as the line that says "runtime link editor dir cache"
when I got the following panic:
May  8 17:22:46 blurg /netbsd: mode = 0100500, inum = 5927, fs = /
May  8 17:22:46 blurg /netbsd: panic: ffs_valloc: dup alloc

I typed "help" and, not knowing what I was doing, tried "show map".  This
apparently caused the following to appear in my /var/log/messages:
May  8 17:22:46 blurg /netbsd: vm_fault(e2000, 37006000, 1, 0) -> 1
May  8 17:22:46 blurg /netbsd:   type 8, code [mmu,,ssw]: 505
May  8 17:22:46 blurg /netbsd: trap type 8, code = 505, v = 37006442
May  8 17:22:46 blurg /netbsd: pid = 121, pc = 00074DA0, ps = 2009, sfc = 0001,
dfc = 0001
May  8 17:22:46 blurg /netbsd: Registers:
May  8 17:22:46 blurg /netbsd:              0        1        2        3
4        5        6        7
May  8 17:22:46 blurg /netbsd: dreg: 0000004F 00000025 00000000 00000000 00541F0
0 0000001C 00000000 00000000
May  8 17:22:46 blurg /netbsd: areg: 0007DB8C 0007278C 37006436 0000F550 0007DB8
C 0007DB68 FFFFFB60 0DFFFD40
May  8 17:22:46 blurg /netbsd:
May  8 17:22:47 blurg /netbsd: Kernel stack (FFFFFA14):
May  8 17:22:47 blurg /netbsd: FFFA14: 00098024 FFFFFACC 00000080 00097FC2 00000
008 00000505 37006442 00000000
May  8 17:22:47 blurg /netbsd: FFFA34: FFFFFA78 00098318 00000008 00000505 37006
442 FFFFFACC 00000008 00000000
May  8 17:22:47 blurg /netbsd: FFFA54: 00541F00 0000001C 00000505 37006442 005B0
300 0000F550 0007DB8C 0007DB68
May  8 17:22:47 blurg /netbsd: FFFA74: 00000001 FFFFFAB8 00098606 00000008 00000
505 37006442 FFFFFACC 005B0300
.... stuff deleted ... I have it saved if it would be useful.
May  8 17:22:49 blurg /netbsd: FFFBF4: 0000000A 000B0F3C 0009C4F2 FFFFFC14 0000E
E3A 0000000A 00000000 00000000
May  8 17:22:49 blurg /netbsd: panic: MMU fault
I then did a "c"; when the system came up, it "fsck"ed all file systems and
it did find a problem w/ the same inode the panic was about.  The boot
continued just fine (well, here I am).

I had a similar incident a few days ago.  I don't have a stack trace, but
I do have a log of an fsck the immediately preceded the panic (I triggered
the panic when I 'rm'ed a .core file that had been found by the /etc/daily
script (which also does a fsck).
I read my mail and saw the list of .core files, so I "su"ed and did "cd /"
"rm *.core".  The machine froze immediately.  I eventually did a ctrl-a-a
An 'ls' revealed that the core files were still there, so I did an "rm" again
and then I got a panic. 

The following was in my messages file, but I'm not sure if this is from
the initial freeze while I was running X or the latter panic when I was
on the text console (I suspect the former since I seem to recall the 
panic being something that included the word "inode").

May  6 16:00:34 blurg /netbsd: dev = 0x400, block = 2328, fs = /
May  6 16:00:34 blurg /netbsd: panic: blkfree: freeing free block
May  6 16:00:34 blurg /netbsd: syncing disks... 18 18 15 10 5 5 5 5 5 5 5 5 5 5
5 5 5 5 5 5 giving up
And a short excerpt from the fsck:
7551 DUP I=49 [there were quite a few more of these "DUP"]
7056 DUP I=49
7057 DUP I=49
DUP/BAD  I=49  OWNER=root MODE=100644
SIZE=2277376 MTIME=May  7 17:52 1995
FILE=/Xdaniver-1.01.core


Again, I have the output of /etc/daily as well as the "messages" files. 

>How-To-Repeat:
>Fix:
>Audit-Trail:
>Unformatted: