Re: Ufs dead-locks on freebsd 6.2



On Thu, May 17, 2007 at 01:03:37PM -0400, Andrew Edwards wrote:
Here it is.

db> show vnode 0xccd47984
vnode 0xccd47984: tag ufs, type VDIR
usecount 5135, writecount 0, refcount 5137 mountedhere 0
flags (VV_ROOT)
v_object 0xcd02518c ref 0 pages 1
#0 0xc0593f0d at lockmgr+0x4ed
#1 0xc06b8e0e at ffs_lock+0x76
#2 0xc0739787 at VOP_LOCK_APV+0x87
#3 0xc0601c28 at vn_lock+0xac
#4 0xc05ee832 at lookup+0xde
#5 0xc05ee4b2 at namei+0x39a
#6 0xc05e2ab0 at unp_connect+0xf0
#7 0xc05e1a6a at uipc_connect+0x66
#8 0xc05d9992 at soconnect+0x4e
#9 0xc05dec60 at kern_connect+0x74
#10 0xc05debdf at connect+0x2f
#11 0xc0723e2b at syscall+0x25b
#12 0xc070ee0f at Xint0x80_syscall+0x1f

ino 2, on dev amrd0s1a
It seems to be the sort of things that cannot happen. VOP_LOCK()
returned 0, but vnode was not really locked.

Although claiming that kernel code cannot have such bug is too optimistic,
I would first make sure that:
1. You checked the memory of the machine.
2. Your kernel is built from pristine sources.


-----Original Message-----
From: Kostik Belousov [mailto:kostikbel@xxxxxxxxx]
Sent: Thursday, May 17, 2007 1:01 PM
To: Andrew Edwards
Cc: freebsd-performance@xxxxxxxxxxx; freebsd-fs@xxxxxxxxxxx
Subject: Re: Ufs dead-locks on freebsd 6.2

On Thu, May 17, 2007 at 11:44:15AM -0400, Andrew Edwards wrote:
I've upgraded to 6-stable, added the kernel options as per
the kernel
handbook. After about 5 hours of they system in a deadlock
it panic'd.
Here's the backtrace, and show pcpu, show allpcpu, show locks, show
alllocks, show lockedvnods and alltrace.

I will have the system down for approx another 15-20mins if there's
anything else someone would like while I'm in the debugger.


db> bt
Tracing pid 46784 tid 105112 td 0xd44a8000
kdb_enter(c0785f13) at kdb_enter+0x2b
vfs_badlock(c0785f2c,c0786051,ccd47984) at vfs_badlock+0x47
assert_vop_locked(ccd47984,c0786051) at assert_vop_locked+0x4a
vop_lock_post(f9f709dc,0,1002,ccd47984,f9f709f8,...) at
vop_lock_post+0x2a
VOP_LOCK_APV(c07dc2e0,f9f709dc) at VOP_LOCK_APV+0xa0
vn_lock(ccd47984,1002,d44a8000) at vn_lock+0xac
lookup(f9f70c08) at lookup+0xde
namei(f9f70c08) at namei+0x39a
unp_connect(d44b2de8,d44dc380,d44a8000,d44b2de8,25,...) at
unp_connect+0xf0
uipc_connect(d44b2de8,d44dc380,d44a8000) at uipc_connect+0x66
soconnect(d44b2de8,d44dc380,d44a8000) at soconnect+0x4e
kern_connect(d44a8000,7,d44dc380,d44dc380,0,...) at
kern_connect+0x74
connect(d44a8000,f9f70d04) at connect+0x2f
syscall(3b,805003b,bfbf003b,bfbfd920,bfbfd922,...) at syscall+0x25b
Xint0x80_syscall() at Xint0x80_syscall+0x1f

Could you, please, do the "show vnode 0xccd47984" from ddb
prompt or "p/x *(struct vnode *)0xccd47984" from kgdb using
dump for this panic ?

Side note: it seems that on HEAD, vnode_if.awk does not
generate call to vop_lock_{pre,post} due to mismatch in the
name of vop and pre/post names.



_______________________________________________
freebsd-fs@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-fs
To unsubscribe, send any mail to "freebsd-fs-unsubscribe@xxxxxxxxxxx"

Attachment: pgpofOzr0sRsi.pgp
Description: PGP signature



Relevant Pages

  • RE: Ufs dead-locks on freebsd 6.2
    ... vnode 0xccd47984: tag ufs, type VDIR ... flags ... v_object 0xcd02518c ref 0 pages 1 ...
    (freebsd-performance)
  • Re: Writing a plain text file to disk from kernel space
    ... Anyways, I modified the filewriter kernel module that I attached to my previous post so that it used the kio code, and verified that the code does work when called across different threads. ... If I comment out the kio_write code and put a printf instead, there are no such problems, so it seems the kio_write function is doing something that is upsetting the kernel, but only when called from a function that is acting as a pfil output hook? ... void kio_close(struct vnode *vp); ... struct thread *td = curthread; ...
    (freebsd-hackers)
  • Re: recent changes in Giant usage -> panic
    ... > I installed the new kernel, rebooted, and got this panic while mtree was ... > running in installworld. ... Here we've completely released the vnode, ... Here we reference something hanging off it. ...
    (freebsd-current)
  • Re: final decision about *at syscalls
    ... different directory under the same descriptor number. ... Do you not realize that the kernel copying data ... in from userland multiple times and having it change in between is very bug ... With vnode approach where do you have more data copying between ...
    (freebsd-arch)
  • Re: tuning hints for PAE
    ... On Thu, 15 Jul 2004, Daniel Lang wrote: ... are kernel-land structures that can reference any ... Your vnode use count is always going to be greater than ... multiple programs accessing the same file or directory, the kernel ...
    (freebsd-current)