Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 15 Oct 1996 18:19:15 +0200 (MET DST)
From:      Tor Egge <Tor.Egge@idt.ntnu.no>
To:        FreeBSD-gnats-submit@freebsd.org
Subject:   kern/1812: vnodes are left in a locked state
Message-ID:  <199610151619.SAA25686@ikke.idt.unit.no>
Resent-Message-ID: <199610151620.JAA17033@freefall.freebsd.org>

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

>Number:         1812
>Category:       kern
>Synopsis:       vnodes are left in a locked state
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          open
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Oct 15 09:20:01 PDT 1996
>Last-Modified:
>Originator:     Tor Egge
>Organization:
Norwegian University of Science and Technology, Trondheim, Norway

>Release:        FreeBSD 2.2-CURRENT i386
>Environment:

FreeBSD ikke.idt.unit.no 2.2-CURRENT FreeBSD 2.2-CURRENT #3: Mon Oct 14 02:10:57 MET DST 1996     root@ikke.idt.unit.no:/usr/src/sys/compile/TEGGE  i386

>Description:

	Writing to memory regions corresponding to a few hundred mmapped files 
        and using msync() to flush the file system may cause the process
	to hang.

	The process is unkillable, in diskwait. 

	ps xl outout shows 
  UID   PID  PPID CPU PRI NI   VSZ  RSS WCHAN  STAT  TT       TIME COMMAND
26850 24861 24860  45 -18 19   612 38132 vmiorl DN    ??    2:02.79 bin/domainhelp

	One of the vnodes for the mmapped files is left in a locked state, 
        i.e. lstat() hangs :-(

  UID   PID  PPID CPU PRI NI   VSZ  RSS WCHAN  STAT  TT       TIME COMMAND
26850 25492 25098 145 -14  0   204  592 uihget D+    p9    0:00.03 ls -F -ld h.de (ls@386freebsd)

	As a side effect of this, the vnode for the directory in which 
	the file resides
	(/export/akg2/ftpsearch/datasets/datasets/dataset2/domain) 
	becomes locked. :-(

>How-To-Repeat:
	open and mmap 250 files, each 1.2 MB in size.

	Write to the first 32 KB on each of the 250 mmapped memory regions,
	then use msync() with the MS_ASYNC flag and fsync() for each of the 250
	mmapped memory regions.
	Continue with the next 32 KB, until all of the mmapped regions have
	been written to disk.

>Fix:
	Temporary workaround: reboot the system whenever this occurs.
	

>Audit-Trail:
>Unformatted:



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