Possible solution to lockups on FreeBSD 6?
Luke Dean
LukeD at pobox.com
Tue Dec 20 01:30:01 PST 2005
In my ongoing quest to figure out why my machine keeps locking up since I
upgraded from 5.4 to 6.0, I came across this interesting passage in man
(5) pf.conf:
BUGS
Due to a lock order reversal (LOR) with the socket layer, the use of the
group and user filter parameter in conjuction with a Giant-free netstack
can result in a deadlock. If you have to use group or user you must set
debug.mpsafenet to ``0'' from the loader(8), for the moment. This work-
around will still produce the LOR, but Giant will protect from the dead-
lock.
In the release notes for FreeBSD 6, I found:
Fine-grained locking has been applied to many of the data structures in
the IPX/SPX protocol stack. While not fully MPSAFE at this point, it is
generally safe to use IPX/SPX without the Giant lock (in other words,
the debug.mpsafenet sysctl variable may be set to 1).
While I don't fully understand what this passage is talking about, I take
it to mean that the default value of debug.mpsafenet is now 1, and that
this is a new feature of FreeBSD version 6.
I use pf. I use the user filter parameter on some oft-evaluated rules.
I discovered that my debug.mpsafenet is indeed "1" . My system is
deadlocking occasionally under 6 where it never did so under 5.4.
I think I'm going to attempt to set debug.mpsafenet to "0" in my
loader.conf and see how many days I can go without a lockup this time.
I've seen several threads lately from people having lockup troubles after
upgrading to version 6, and at least one of them mentioned pf
specifically, so I bet some of the rest of you may want to try this too.
More information about the freebsd-questions
mailing list