Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 10 Aug 2013 21:21:09 +0300
From:      Konstantin Belousov <kostikbel@gmail.com>
To:        Bryan Drewery <bryan-lists@shatow.net>
Cc:        freebsd-current@freebsd.org
Subject:   Re: panic on boot with fresh current
Message-ID:  <20130810182109.GG4972@kib.kiev.ua>
In-Reply-To: <20130810174547.GE4972@kib.kiev.ua>
References:  <20130810112410.GA27286@devbox.vnode.local> <52066DE0.2060305@shatow.net> <52067537.2070309@shatow.net> <20130810174407.GD4972@kib.kiev.ua> <20130810174547.GE4972@kib.kiev.ua>

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

--vbZajQVEYxrkwA3V
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Sat, Aug 10, 2013 at 08:45:47PM +0300, Konstantin Belousov wrote:
> On Sat, Aug 10, 2013 at 08:44:07PM +0300, Konstantin Belousov wrote:
> > On Sat, Aug 10, 2013 at 12:15:35PM -0500, Bryan Drewery wrote:
> > > On 8/10/2013 11:44 AM, Bryan Drewery wrote:
> > > > On 8/10/2013 6:24 AM, Joel Dahl wrote:
> > > >> panic: witness_init: pending locks list is too small, increase
> > > >> WITNESS_PENDLIST
> > > > I also get this. The last stable revision for me was r254150
> > >=20
> > > r254150 stable, r254171 panic.
> > >=20
> > > backtrace: https://dl.dropboxusercontent.com/u/8732004/r254171-panic.=
jpg
> >=20
> > So could you point to exact commit which causes panic ?
> It is r254167, right ?
>=20
So I cannot reproduce it locally.  The problem is that r254167 moved sleepq
initialization before witness is operational, and witness has a backlog
of locks initialized before witness init.  The backlog overflown.

The right fix looks to be just what the panic message told, please try
this:

diff --git a/sys/kern/subr_witness.c b/sys/kern/subr_witness.c
index 3b4d7a2..37e8cf2 100644
--- a/sys/kern/subr_witness.c
+++ b/sys/kern/subr_witness.c
@@ -135,7 +135,7 @@ __FBSDID("$FreeBSD$");
 #define	WITNESS_COUNT 		1024
 #define	WITNESS_CHILDCOUNT 	(WITNESS_COUNT * 4)
 #define	WITNESS_HASH_SIZE	251	/* Prime, gives load factor < 2 */
-#define	WITNESS_PENDLIST	768
+#define	WITNESS_PENDLIST	1024
=20
 /* Allocate 256 KB of stack data space */
 #define	WITNESS_LO_DATA_COUNT	2048

If this does not help, try to increse PENDLIST even more.  But, sleepq
uses 256 elements, which means that my increase should be enough.

--vbZajQVEYxrkwA3V
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.20 (FreeBSD)

iQIcBAEBAgAGBQJSBoSUAAoJEJDCuSvBvK1BeSkQAKNnwWNIk8B0z6pM2ja8FeXQ
5hDHM0dtmb1QCenAY/33RG44cNO7Cqzs+ZQgqfxvvCLd+PH6LGZJfzwIzySS8Qsl
eAZF8inKCbvNeSzuY/TWcDT9OtV6jvG5/7jP2uwHQtc3X7T0Z9Ob5fCilYQp2Da0
EJ54i4zqMaLNjLxcmfaSjHU22oGIRXl0ojbOPJ875a8bz8etBFoupt387SiUSA3K
VlcPX9QfDNJ3TM3uq6JpC2D6UuIilsEQotBwZ17d5WLp4oPGzahczgFe99JWjEPF
dDY9ZMZQkIFk3mTBV+C2/jtQBxN0fc12TMOC7WwjGyBQ8fq1jGfYv+4e5cfGZVzl
tkCJ+DhxjApJq125oHBf/xGQmQevHIqMFWLpTW/N5R2O3h4VNgu+uzws545gxmxe
KCgW5sLOggXS26+2B+Yb4l5tuJ8Zp0p727fXrnV1dZaPzsJ5T0U8cOYHf8cab8hr
D7kMlzsn4+QH0af02bmTKeJTZVt7zA5zI7MV/2YrLSwOXiFmIB+R5oKWPLs30Ncm
tdEkntre3EaorbiJvwz5n1jYsredCjcdK59RvRu5JtoeDnxEdB70yxDcnnd6KZTw
ZYYWTOBXWl+gAEtUTQeHZ+KfTuNwooxm9H8n/jbatD2aepKLBzvLB3aDgI+WrOpS
d5QuNcY+9vpSt9OSAWU5
=IHFc
-----END PGP SIGNATURE-----

--vbZajQVEYxrkwA3V--



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