NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: kern/50375: layerfs (nullfs) locking problem leading to livelock

The following reply was made to PR kern/50375; it has been noted by GNATS.

From: "J. Hannken-Illjes" <>
Cc: Konrad Schroder <>
Subject: Re: kern/50375: layerfs (nullfs) locking problem leading to livelock
Date: Fri, 30 Oct 2015 09:55:12 +0100

 > A quick read of hannken's analysis makes me think that the basic problem 
 > here is that the two imposed locking orders (parent directory before 
 > subdirectory, and upper before lower) are in direct conflict when a 
 > directory is null-mounted onto a subdirectory of itself.
 Sure, loops would deadlock very fast.
 For the deadlock described here it is sufficient to mount a path on
 two different null mounts like:
 dev on /data type ffs
 /nulla on /data type null
 /nullb on /data type null
 The deadlock arises from one thread cleaning a node from /nulla while
 another thread tries to vget a node on /nullb and both nodes point to
 the same node on /data.
 J. Hannken-Illjes - - TU Braunschweig (Germany)

Home | Main Index | Thread Index | Old Index