From owner-freebsd-current Sat Jan 26 21:42: 2 2002 Delivered-To: freebsd-current@freebsd.org Received: from magic.adaptec.com (magic.adaptec.com [208.236.45.80]) by hub.freebsd.org (Postfix) with ESMTP id 2C0D037B417; Sat, 26 Jan 2002 21:41:55 -0800 (PST) Received: from redfish.adaptec.com (redfish.adaptec.com [162.62.50.11]) by magic.adaptec.com (8.8.8+Sun/8.8.8) with ESMTP id VAA11052; Sat, 26 Jan 2002 21:41:52 -0800 (PST) Received: from btc.btc.adaptec.com (btc.btc.adaptec.com [162.62.64.10]) by redfish.adaptec.com (8.8.8+Sun/8.8.8) with ESMTP id VAA18939; Sat, 26 Jan 2002 21:25:13 -0800 (PST) Received: from hollin.btc.adaptec.com (hollin [162.62.149.56]) by btc.btc.adaptec.com (8.8.8+Sun/8.8.8) with ESMTP id WAA14719; Sat, 26 Jan 2002 22:41:44 -0700 (MST) Received: (from scottl@localhost) by hollin.btc.adaptec.com (8.11.6/8.11.4) id g0R5cs771402; Sat, 26 Jan 2002 22:38:54 -0700 (MST) (envelope-from scottl) Date: Sat, 26 Jan 2002 22:38:54 -0700 From: Scott Long To: Doug Swarin Cc: freebsd-current@freebsd.org, bright@mu.org, sobomax@freebsd.org, kris@obsecurity.org Subject: Re: Panic in ufs_dirbad() Message-ID: <20020127053854.GA71386@hollin.btc.adaptec.com> References: <20020125184512.A64502@staff.texas.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20020125184512.A64502@staff.texas.net> User-Agent: Mutt/1.3.25i Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, Jan 25, 2002 at 06:45:12PM -0600, Doug Swarin wrote: > On Thu, Jan 24, 2002 at 02:53:32PM -0800, Alfred Perlstein wrote: > > * Maxim Sobolev [020124 13:44] wrote: > > > Any ideas? This is a reasonably recent 5-CURRENT (last > > > makeworld/makekernel 7 days ago). > > > > This may be fallout from my initial fdlocking work, please try > > an update or get a debug traceback and we'll see. > > I have actually seen this panic very recently on -STABLE. Matt > Dillon suspected an issue with the RAID controller I was using > (aac) after some debugging work. > > I am still waiting on the results of diagnostic testing on the > RAID controller, but I just wanted to offer an additional data > point. > > I have attached dmesg and some of the results of our debugging > session below. The panic occurred during heavy file create/delete > activity. I referred to PR kern/13150, which may or may not be > related. > > We determined that *ep in ufs_lookup contained garbage (from a file > name). ep->d_name contained file data. Besides this somewhat empirical evidence, is there any other reason that you suspect the aac controller? Can you post the relevant dmesg lines that describe this controller? We make pretty heavy use of our aac controller here, with very good results. I'd like to help narrow this down, since data corruption is not a typical failure mode of these controllers or the aac driver. Scott > > Doug Swarin > doug@texas.net > > > (kgdb) back > #0 dumpsys () at /usr/src/sys/kern/kern_shutdown.c:473 > #1 0xc01705df in boot (howto=256) at /usr/src/sys/kern/kern_shutdown.c:313 > #2 0xc0170a01 in panic (fmt=0xc0276207 "ufs_dirbad: bad dir") > at /usr/src/sys/kern/kern_shutdown.c:581 > #3 0xc01e8ef6 in ufs_dirbad (ip=0xc8154200, offset=31, > how=0xc02761b0 "mangled entry") at /usr/src/sys/ufs/ufs/ufs_lookup.c:641 > #4 0xc01e8714 in ufs_lookup (ap=0xef25ad14) > at /usr/src/sys/ufs/ufs/ufs_lookup.c:291 > #5 0xc01ed715 in ufs_vnoperate (ap=0xef25ad14) > at /usr/src/sys/ufs/ufs/ufs_vnops.c:2423 > #6 0xc019a04a in vfs_cache_lookup (ap=0xef25ad6c) at vnode_if.h:77 > #7 0xc01ed715 in ufs_vnoperate (ap=0xef25ad6c) > at /usr/src/sys/ufs/ufs/ufs_vnops.c:2423 > #8 0xc019cfb9 in lookup (ndp=0xef25aec4) at vnode_if.h:52 > #9 0xc019cab4 in namei (ndp=0xef25aec4) > at /usr/src/sys/kern/vfs_lookup.c:153 > #10 0xc01a580a in vn_open (ndp=0xef25aec4, fmode=514, cmode=420) > at /usr/src/sys/kern/vfs_vnops.c:99 > #11 0xc01a1a8c in open (p=0xef1b8560, uap=0xef25af80) > at /usr/src/sys/kern/vfs_syscalls.c:999 > #12 0xc023ebbd in syscall2 (frame={tf_fs = -1078001617, tf_es = 47, > tf_ds = -1078001617, tf_edi = 513, tf_esi = 134645918, > tf_ebp = -1077945588, tf_isp = -282742828, tf_ebx = -1077946616, > tf_edx = 68, tf_ecx = -1077946780, tf_eax = 5, tf_trapno = 0, > tf_err = 2, tf_eip = 672953588, tf_cs = 31, tf_eflags = 663, > tf_esp = -1077946656, tf_ss = 47}) > at /usr/src/sys/i386/i386/trap.c:1157 > #13 0xc022b8eb in Xint0x80_syscall () > (kgdb) frame 4 > (kgdb) print ep->d_reclen > $4 = 0x6f63 > (kgdb) print entryoffsetinblock > $5 = 0x1f > (kgdb) print dirchk > $6 = 0x0 > (kgdb) print *ep > $7 = { > d_ino = 0x2e797567, > d_reclen = 0x6f63, > d_type = 0x6d, > d_namlen = 0x3e, > d_name = '\000' , "Assorted -"... > } > > > Copyright (c) 1992-2002 The FreeBSD Project. > Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 > The Regents of the University of California. All rights reserved. > FreeBSD 4.5-RC #0: Wed Jan 16 11:37:55 CST 2002 > root@localhost:/usr/obj/usr/src/sys/NEWS2450 > Timecounter "i8254" frequency 1193182 Hz > CPU: Pentium III/Pentium III Xeon/Celeron (993.33-MHz 686-class CPU) > Origin = "GenuineIntel" Id = 0x686 Stepping = 6 > Features=0x383fbff > real memory = 2147475456 (2097144K bytes) > config> q > avail memory = 2088914944 (2039956K bytes) > Changing APIC ID for IO APIC #0 from 2 to 0 in MP table > Changing APIC ID for IO APIC #1 from 0 to 3 on chip > Programming 16 pins in IOAPIC #0 > Programming 16 pins in IOAPIC #1 > FreeBSD/SMP: Multiprocessor motherboard > cpu0 (BSP): apic id: 1, version: 0x00040011, at 0xfee00000 > io0 (APIC): apic id: 0, version: 0x000f0011, at 0xfec00000 > io1 (APIC): apic id: 3, version: 0x000f0011, at 0xfec01000 > Preloaded elf kernel "kernel" at 0xc032b000. > Preloaded userconfig_script "/boot/kernel.conf" at 0xc032b09c. > Pentium Pro MTRR support enabled > md0: Malloc disk > Using $PIR table, 7 entries at 0xc00fc2c0 > npx0: on motherboard > npx0: INT 16 interface > pcib0: on motherboard > pci0: on pcib0 > pci0: at 14.0 > isab0: at device 15.0 on pci0 > isa0: on isab0 > atapci0: port 0x8b0-0x8bf at device 15.1 on pci0 > ata0: at 0x1f0 irq 14 on atapci0 > ata1: at 0x170 irq 15 on atapci0 > pci0: at 15.2 irq 11 > pcib1: on motherboard > IOAPIC #1 intpin 15 -> irq 2 > IOAPIC #1 intpin 0 -> irq 5 > pci1: on pcib1 > pcib2: at device 2.0 on pci1 > IOAPIC #1 intpin 14 -> irq 10 > pci2: on pcib2 > pci2: (vendor=0x9005, dev=0x00c5) at 4.0 irq 2 > ahc0: port 0xd800-0xd8ff mem 0xf7ffe000-0xf7ffefff irq 10 at device 4.1 on pci2 > aic7899: Ultra160 Wide Channel B, SCSI Id=7, 32/255 SCBs > aac0: mem 0xf0000000-0xf3ffffff irq 2 at device 2.1 on pci1 > aac0: i960RX 100MHz, 54MB cache memory, no battery support > aac0: Kernel 2.1-3, Build 2951, S/N 4c20d0 > fxp0: port 0xccc0-0xccff mem 0xf9000000-0xf90fffff,0xf9100000-0xf9100fff irq 5 at device 8.0 on pci1 > fxp0: Ethernet address 00:b0:d0:49:46:31 > inphy0: on miibus0 > inphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto > orm0: