panic: lockmgr: locking against myself

From: Daniel C. Sobral <dcs_at_tcoip.com.br>
Date: Tue, 20 May 2003 08:47:39 -0300
This is an easily reproducable panic. Whenever my system panics for some 
reason, that panic will follow during the background fsck afterwards.

I'm inclined to disable background fsck, only that would be just masking 
the problem, not solving it. I *thought* this had been solved. :-(

When this stuff happens, I always boot single user and run fsck by hand, 
so I can't see how it could be inconsistent state left by an early panic 
_during_ a background fsck.

Kirk, do you recommend any course of action to me that would help 
tracking down this bug?

Trace follows, further information available upon request. This kernel 
was compiled from yesterday (19th) sources.

GNU gdb 5.2.1 (FreeBSD)
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain 
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-undermydesk-freebsd"...
"/var/crash/vmcore.2" is not a core dump: File format not recognized
(gdb) quit
root_at_dcs:/opt/home/dcs$ gdb -k /usr/obj/usr/src/sys/DCS/kernel.debug 
/var/crash/vmcore.2
GNU gdb 5.2.1 (FreeBSD)
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain 
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-undermydesk-freebsd"...
panic: lockmgr: locking against myself
panic messages:
---
panic: lockmgr: locking against myself

syncing disks, buffers remaining... 248 248 247 247 247 247 247 247 247 
247 247 247 247 247 247 247 247 247 247 247 247 247
giving up on 231 buffers
Uptime: 3m5s
Dumping 255 MB
ata0: resetting devices ..
done
  16 32 48 64 80 96 112 128 144 160 176 192 208 224 240Copyright (c) 
1992-2003 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 5.1-BETA #30: Mon May 19 21:40:33 BRT 2003
     root_at_dcs:/usr/obj/usr/src/sys/DCS
Preloaded elf kernel "/boot/kernel/kernel" at 0xc04c0000.
Preloaded elf module "/boot/kernel/snd_cmi.ko" at 0xc04c021c.
Preloaded elf module "/boot/kernel/snd_pcm.ko" at 0xc04c02c8.
Preloaded elf module "/boot/kernel/mac_biba.ko" at 0xc04c0374.
Preloaded elf module "/boot/kernel/mac_mls.ko" at 0xc04c0424.
Preloaded elf module "/boot/kernel/acpi.ko" at 0xc04c04d0.
Timecounter "i8254"  frequency 1193182 Hz
Timecounter "TSC"  frequency 1007050471 Hz
CPU: Intel(R) Celeron(TM) CPU                1000MHz (1007.05-MHz 
686-class CPU)
   Origin = "GenuineIntel"  Id = 0x6b1  Stepping = 1
 
Features=0x383f9ff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,MMX,FXSR,SSE>
real memory  = 268353536 (255 MB)
avail memory = 255438848 (243 MB)
Security policy loaded: TrustedBSD MAC/Biba (mac_biba)
Security policy loaded: TrustedBSD MAC/MLS (mac_mls)
Pentium Pro MTRR support enabled
VESA: v3.0, 4096k memory, flags:0x1, mode table:0xc03ca722 (1000022)
VESA: NVidia
npx0: <math processor> on motherboard
npx0: INT 16 interface
acpi0: <ASUS   TUV4X   > on motherboard
pcibios: BIOS version 2.10
Using $PIR table, 9 entries at 0xc00f12d0
acpi0: power button is handled as a fixed feature programming model.
Timecounter "ACPI-fast"  frequency 3579545 Hz
acpi_timer0: <24-bit timer at 3.579545MHz> port 0xe408-0xe40b on acpi0
acpi_cpu0: <CPU> on acpi0
acpi_button0: <Power Button> on acpi0
pcib0: <ACPI Host-PCI bridge> port 0xcf8-0xcff on acpi0
pci0: <ACPI PCI bus> on pcib0
agp0: <VIA 82C691 (Apollo Pro) host to PCI bridge> mem 
0xf8000000-0xfbffffff at device 0.0 on pci0
pcib1: <ACPI PCI-PCI bridge> at device 1.0 on pci0
pcib1: could not get PCI interrupt routing table for \\_SB_.PCI0.AGP_ - 
AE_NOT_FOUND
pci1: <ACPI PCI bus> on pcib1
pci1: <display, VGA> at device 0.0 (no driver attached)
isab0: <PCI-ISA bridge> at device 4.0 on pci0
isa0: <ISA bus> on isab0
atapci0: <VIA 82C686B UDMA100 controller> port 0xd800-0xd80f at device 
4.1 on pci0
ata0: at 0x1f0 irq 14 on atapci0
ata1: at 0x170 irq 15 on atapci0
uhci0: <VIA 83C572 USB controller> port 0xd400-0xd41f irq 5 at device 
4.2 on pci0
usb0: <VIA 83C572 USB controller> on uhci0
usb0: USB revision 1.0
uhub0: VIA UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub0: 2 ports with 2 removable, self powered
uhub0: port error, restarting port 1
uhub0: port error, giving up port 1
ugen0: AKS eToken R2 2242, rev 1.00/1.00, addr 2
uhub0: port error, restarting port 2
uhub0: port error, giving up port 2
uhci1: <VIA 83C572 USB controller> port 0xd000-0xd01f irq 5 at device 
4.3 on pci0
usb1: <VIA 83C572 USB controller> on uhci1
usb1: USB revision 1.0
uhub1: VIA UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub1: 2 ports with 2 removable, self powered
uhub1: port error, restarting port 1
uhub1: port error, giving up port 1
uhub1: port error, restarting port 2
uhub1: port error, giving up port 2
pcm0: <CMedia CMI8738> port 0xb800-0xb8ff at device 5.0 on pci0
pcib0: slot 5 INTA is routed to irq 5
fxp0: <Intel 82557/8/9 EtherExpress Pro/100(B) Ethernet> port 
0xb400-0xb43f mem 0xf3000000-0xf30fffff,0xf3800000-0xf3800fff irq 10 at 
device 9.0 on pci0
fxp0: Ethernet address 00:02:b3:ae:0d:ea
miibus0: <MII bus> on fxp0
inphy0: <i82555 10/100 media interface> on miibus0
inphy0:  10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto
fdc0: <Enhanced floppy controller (i82077, NE72065 or clone)> port 
0x3f7,0x3f2-0x3f5 irq 6 drq 2 on acpi0
fdc0: FIFO enabled, 8 bytes threshold
fd0: <1440-KB 3.5" drive> on fdc0 drive 0
ppc0 port 0x378-0x37f irq 7 on acpi0
ppc0: Generic chipset (EPP/NIBBLE) in COMPATIBLE mode
ppbus0: <Parallel port bus> on ppc0
lpt0: <Printer> on ppbus0
lpt0: Interrupt-driven port
ppi0: <Parallel I/O> on ppbus0
sio0 port 0x3f8-0x3ff irq 4 on acpi0
sio0: type 16550A
sio1 port 0x2f8-0x2ff irq 3 on acpi0
sio1: type 16550A
atkbdc0: <Keyboard controller (i8042)> port 0x64,0x60 irq 1 on acpi0
atkbd0: <AT Keyboard> flags 0x1 irq 1 on atkbdc0
kbd0 at atkbd0
psm0: <PS/2 Mouse> irq 12 on atkbdc0
psm0: model Generic PS/2 mouse, device ID 0
orm0: <Option ROMs> at iomem 0xd0000-0xd0fff,0xc0000-0xcffff on isa0
pmtimer0 on isa0
sc0: <System console> at flags 0x100 on isa0
sc0: VGA <16 virtual consoles, flags=0x300>
vga0: <Generic ISA VGA> at port 0x3c0-0x3df iomem 0xa0000-0xbffff on isa0
Timecounters tick every 1.000 msec
acpi_cpu: throttling enabled, 16 steps (100% to 6.2%), currently 100.0%
ad0: 19092MB <ST320410A> [38792/16/63] at ata0-master UDMA100
acd0: CDROM <CRD-8481B> at ata1-master PIO4
Mounting root from ufs:/dev/ad0s2a
WARNING: / was not properly dismounted
/: mount pending error: blocks 4 files 1
WARNING: /opt was not properly dismounted
/opt: mount pending error: blocks 8 files 1
WARNING: /tmp was not properly dismounted
/tmp: mount pending error: blocks 868 files 1
WARNING: /usr was not properly dismounted
/usr: mount pending error: blocks 96 files 1
WARNING: /var was not properly dismounted
handle_workitem_freeblocks: block count
panic: lockmgr: locking against myself

syncing disks, buffers remaining... 178 178 177 177 177 177 177 177 177 
177 177 177 177 177 177 177 177 177 177 177 177 177
giving up on 171 buffers
Uptime: 2m36s
Dumping 255 MB
ata0: resetting devices ..
done
  16 32 48 64 80 96 112 128 144 160 176 192 208 224 240
---
Reading symbols from /boot/kernel/snd_cmi.ko...done.
Loaded symbols for /boot/kernel/snd_cmi.ko
Reading symbols from /boot/kernel/snd_pcm.ko...done.
Loaded symbols for /boot/kernel/snd_pcm.ko
Reading symbols from 
/usr/obj/usr/src/sys/DCS/modules/usr/src/sys/modules/mac_biba/mac_biba.ko.debug...done.
Loaded symbols for 
/usr/obj/usr/src/sys/DCS/modules/usr/src/sys/modules/mac_biba/mac_biba.ko.debug
Reading symbols from 
/usr/obj/usr/src/sys/DCS/modules/usr/src/sys/modules/mac_mls/mac_mls.ko.debug...done.
Loaded symbols for 
/usr/obj/usr/src/sys/DCS/modules/usr/src/sys/modules/mac_mls/mac_mls.ko.debug
Reading symbols from 
/usr/obj/usr/src/sys/DCS/modules/usr/src/sys/modules/acpi/acpi.ko.debug...done.
Loaded symbols for 
/usr/obj/usr/src/sys/DCS/modules/usr/src/sys/modules/acpi/acpi.ko.debug
Reading symbols from /boot/kernel/green_saver.ko...done.
Loaded symbols for /boot/kernel/green_saver.ko
Reading symbols from 
/usr/obj/usr/src/sys/DCS/modules/usr/src/sys/modules/linux/linux.ko.debug...done.
Loaded symbols for 
/usr/obj/usr/src/sys/DCS/modules/usr/src/sys/modules/linux/linux.ko.debug
#0  doadump () at /usr/src/sys/kern/kern_shutdown.c:238
238             dumping++;
(kgdb) bt full
#0  doadump () at /usr/src/sys/kern/kern_shutdown.c:238
No locals.
#1  0xc01e7353 in boot (howto=256) at /usr/src/sys/kern/kern_shutdown.c:370
No locals.
#2  0xc01e769b in panic () at /usr/src/sys/kern/kern_shutdown.c:543
         td = (struct thread *) 0xc2a8d260
         bootopt = 256
         newpanic = 1
         buf = "lockmgr: locking against myself", '\0' <repeats 224 times>
#3  0xc01cc8de in lockmgr (lkp=0xc77bab1c, flags=34144290, 
interlkp=0x2000020, td=0xc2a8d260)
     at /usr/src/sys/kern/kern_lock.c:447
         error = 0
         thr = (struct thread *) 0xc2a8d260
         extflags = 33554464
         lockflags = 34144290
#4  0xc0241360 in BUF_TIMELOCK (bp=0xc77bab1c, locktype=34144290, 
interlock=0x0, wmesg=0x0, catch=0, timo=0)
     at buf.h:319
         ret = 0
#5  0xc023c988 in flushbuflist (blist=0xc77ba1b8, flags=4, 
vp=0xc2c08490, slpflag=0, slptimeo=0, errorp=0x0)
     at /usr/src/sys/kern/vfs_subr.c:1231
         bp = (struct buf *) 0xc77bab1c
         nbp = (struct buf *) 0x2090022
         found = 1
         error = 0
#6  0xc023c629 in vinvalbuf (vp=0xc2c08490, flags=4, cred=0x0, td=0x0, 
slpflag=0, slptimeo=0)
     at /usr/src/sys/kern/vfs_subr.c:1144
         blist = (struct buf *) 0x0
         error = 0
         object = (struct vm_object *) 0x20
#7  0xc0279f29 in ffs_truncate (vp=0xc2c08490, length=0, flags=2048, 
cred=0x0, td=0xc2a8d260)
     at /usr/src/sys/ufs/ffs/ffs_inode.c:273
         ovp = (struct vnode *) 0xc2c08490
         oip = (struct inode *) 0xc2bfe5a0
         bn = 1901600437728
         lbn = -4595934205466068317
         lastblock = -3284770578296209408
         lastiblock = {7825139660, 4294852608, 4294983680}
---Type <return> to continue, or q <return> to quit---
         indir_lbn = {-3284769166285545984, 0, -3987497662119620000}
         oldblks = {-4416425772450700000, -4597567232564789125, 
-4603278599235426448, 7561655336,
   1527937901856, -4074702231462273124, 3530172376, 
-4603248444270041168, 3266688040, 531505490166,
   24892772352, 1446336, 1446560, 3530172344, -4413556631095498160}
         newblks = {-4595933861868684637, -4595967809288669728, 
-4595827075025206604, -4603010438657333540,
   -3284770111214707876, -4595967809290379171, -4597571450222673919, 
-4416425775675211334,
   -3284770008136013578, -4597567229341424624, 16109427460, 
-3284769784756383136, -4597567232564788666,
   -4597296039739784738, -4595934549061929304}
         count = -3284770423677386752
         blocksreleased = 0
         datablocks = 96
         fs = (struct fs *) 0xc2753000
         bp = (struct buf *) 0xc020baa3
         needextclean = 0
         softdepslowdown = 0
         extblocks = 0
         offset = -1027570544
         size = 0
         level = 0
         nblocks = -764795284
         i = -1027570544
         error = 0
         allerror = 0
         osize = 3224918624
#8  0xc027d6e4 in ffs_snapshot (mp=0xc2611a00, snapfile=---Can't read 
userspace from dump, or kernel process---

) at /usr/src/sys/ufs/ffs/ffs_snapshot.c:664
         numblks = 262138
         blkno = -4602474053076637436
         blkp = (ufs2_daddr_t *) 0xc037f4c8
         snapblklist = (ufs2_daddr_t *) 0xc020ba3b
         error = 5
         cg = -764794632
         snaploc = 0
         i = 0
         size = 0
         len = -1029123488
         loc = 582
         flag = 220270592
---Type <return> to continue, or q <return> to quit---
         starttime = {tv_sec = 0, tv_nsec = 0}
         endtime = {tv_sec = -1070048928, tv_nsec = 0}
         saved_nice = 0 '\0'
         redo = 0
         snaplistsize = 0
         lp = (int32_t *) 0x0
         space = (void *) 0xc0321084
         copy_fs = (struct fs *) 0x0
         fs = (struct fs *) 0xc2753000
         snaphead = (struct snaphead *) 0xd26a28c8
         td = (struct thread *) 0xc2a8d260
         ip = (struct inode *) 0xc2bfe5a0
         xp = (struct inode *) 0xc2c085b4
         bp = (struct buf *) 0xc77baa50
         nbp = (struct buf *) 0xc037f450
         ibp = (struct buf *) 0xc037f428
         sbp = (struct buf *) 0x0
         nd = {ni_dirp = 0x80c52e0---Can't read userspace from dump, or 
kernel process---



-- 
Daniel C. Sobral                   (8-DCS)
Gerencia de Operacoes
Divisao de Comunicacao de Dados
Coordenacao de Seguranca
VIVO Centro Oeste Norte
Fones: 55-61-313-7654/Cel: 55-61-9618-0904
E-mail: Daniel.Capo_at_tco.net.br
         Daniel.Sobral_at_tcoip.com.br
         dcs_at_tcoip.com.br

Outros:
	dcs_at_newsguy.com
	dcs_at_freebsd.org
	capo_at_notorious.bsdconspiracy.net

Wedding is destiny, and hanging likewise.
		-- John Heywood
Received on Tue May 20 2003 - 02:47:43 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:37:08 UTC