[Bug 253992] ufsdirhash_build() sleeps with directory vnode locked due to M_WAITOK

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Wed Mar 3 18:44:02 UTC 2021


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=253992

--- Comment #2 from dgmorris at earthlink.net <dgmorris at earthlink.net> ---
Actually, we don't default to RR.

>From an email with Mark Johnston (and looking over the code paths):
> More to the point, I believe the zones are marked as FirstTouch because
> they pass "0" as the flags argument to uma_zcreate() -- and the
> keg_ctor() ends up setting the keg flags based on:
>
> 	/*
> 	 * Use a first-touch NUMA policy for kegs that pmap_extract() will
> 	 * work on.  Use round-robin for everything else.
> 	 *
> 	 * Zones may override the default by specifying either.
> 	 */
> #ifdef NUMA
> 	if ((keg->uk_flags &
> 	    (UMA_ZONE_ROUNDROBIN | UMA_ZFLAG_CACHE | UMA_ZONE_NOTPAGE)) == 0)
> 		keg->uk_flags |= UMA_ZONE_FIRSTTOUCH;
> 	else if ((keg->uk_flags & UMA_ZONE_FIRSTTOUCH) == 0)
> 		keg->uk_flags |= UMA_ZONE_ROUNDROBIN;
> #endif
>
> Then the zone flags inherit from the keg flags and there we are.

Yes, FIRSTTOUCH is the default policy for regular zones.

-- End email snippet --

And yes, sorry -- didn't realize I had an isi* function still in there. Yes,
this is Isilon. I tried to stay general about things.

Waiting on a domain specific scan in this case (again, because of First Touch)
may help -- but there may not be much the scan can do. In this case, there was
a separate kernel memory leak that had most of the domain tied up as "in use",
obviating the ability for the pagedaemon to free pages for the domain, but one
can speculate a spike in load localized within one domain that provides a
similar situation for long enough for the directory lock waiters to be noticed.

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-bugs mailing list