Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 24 Apr 1995 22:00:02 -0700
From:      Curt Mayer <curt@mofo.emergent.com>
To:        freebsd-bugs
Subject:   kern/360: filesystem deadlock
Message-ID:  <199504250500.WAA13313@freefall.cdrom.com>
In-Reply-To: Your message of Mon, 24 Apr 1995 21:51:09 -0700 <199504250451.VAA00498@mofo.emergent.com>

next in thread | previous in thread | raw e-mail | index | archive | help

>Number:         360
>Category:       kern
>Synopsis:       filesystem deadlock trivial to produce
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    freebsd-bugs (FreeBSD bugs mailing list)
>State:          open
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Apr 24 22:00:01 1995
>Originator:     Curt Mayer
>Organization:
>Release:        FreeBSD 2.0.950412-SNAP i386
>Environment:

	CX486-DX2/80
	16M, wd and aic disks

>Description:

	the filesystem deadlocks when installing a file to itself.
	a ktrace shows a strange sequence:

   450 install  CALL  stat(0xefbfda0f,0xefbfd87c)
   450 install  NAMI  "/var/tmp/xx"
   450 install  RET   stat 0
   450 install  CALL  stat(0xefbfda07,0xefbfd7ec)
   450 install  NAMI  "termcap"
   450 install  RET   stat 0
   450 install  CALL  stat(0x4414,0xefbfd78c)
   450 install  NAMI  "/var/tmp/xx/termcap"
   450 install  RET   stat 0
   450 install  CALL  unlink(0x4414)
   450 install  NAMI  "/var/tmp/xx/termcap"
   450 install  RET   unlink 0
   450 install  CALL  open(0x4414,0x601,0x180)
   450 install  NAMI  "/var/tmp/xx/termcap"
   450 install  RET   open 3
   450 install  CALL  open(0xefbfda07,0,0)
   450 install  NAMI  "termcap"
   450 install  RET   open 4
   450 install  CALL  mmap(0,0x2c48e,0x1,0,0x4,0,0,0)
   450 install  RET   mmap 134807552/0x8090000
   450 install  CALL  write(0x3,0x8090000,0x2c48e)

	at this point, deadlock with ps -l reporting ufslk2
	
>How-To-Repeat:

	cd /tmp
	cp /etc/termcap .
	install -c -m 0644 termcap /tmp
	>lockup<

>Fix:
	don't install a file to itself.	
>Audit-Trail:
>Unformatted:





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199504250500.WAA13313>