Date: Sat, 26 Jul 2014 14:48:39 +0300 From: Konstantin Belousov <kostikbel@gmail.com> To: Harald Schmalzbauer <h.schmalzbauer@omnilan.de> Cc: FreeBSD Stable <freebsd-stable@freebsd.org> Subject: Re: panic/lock on 9.3-RELEASE with nullfs/nfs/zfs combination Message-ID: <20140726114839.GF93733@kib.kiev.ua> In-Reply-To: <53D380B2.2080700@omnilan.de> References: <53D12973.3010805@omnilan.de> <20140724165917.GT93733@kib.kiev.ua> <53D1503B.2030200@omnilan.de> <20140724193048.GU93733@kib.kiev.ua> <53D2006C.7090207@omnilan.de> <20140725151448.GY93733@kib.kiev.ua> <53D380B2.2080700@omnilan.de>
next in thread | previous in thread | raw e-mail | index | archive | help
--lmwYJyD+fGI+a3sE Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sat, Jul 26, 2014 at 12:19:30PM +0200, Harald Schmalzbauer wrote: > vnode vnode 0xfffffe006cb86bd0: 0xfffffe006cb86bd0: tag null, type VDIR > tag null, type VDIR > usecount 1, writecount 0, refcount 1 mountedhere 0 > usecount 1, writecount 0, refcount 1 mountedhere 0 > flags (VV_ROOT|VI_ACTIVE) > flags (VV_ROOT|VI_ACTIVE) > v_object 0xfffffe006c8d30e8 ref 0 pages 0 cleanbuf 0 dirtybuf 0 > v_object 0xfffffe006c8d30e8 ref 0 pages 0 cleanbuf 0 dirtybuf 0 > lock type zfs: EXCL by thread 0xfffffe0033498920 (pid 1668) > lock type zfs: EXCL by thread 0xfffffe0033498920 (pid 1668) > vp=3D0xfffffe006cb86bd0, lowervp=3D0xfffffe001dbc53f0 > vp=3D0xfffffe006cb86bd0, lowervp=3D0xfffffe001dbc53f0 >=20 It is useful, but still requires more work to get to the issue. From the data you posted, I see that the problem was already reported sometime this winter. We did not come to any conclusion that time. Please, do the following. First, apply this debugging patch and obtain the same data as you did right now. Hopefully, the assert below would trigger. diff --git a/sys/fs/nullfs/null_vnops.c b/sys/fs/nullfs/null_vnops.c index 70402e3..bc9772c 100644 --- a/sys/fs/nullfs/null_vnops.c +++ b/sys/fs/nullfs/null_vnops.c @@ -372,6 +372,10 @@ null_lookup(struct vop_lookup_args *ap) */ ldvp =3D NULLVPTOLOWERVP(dvp); vp =3D lvp =3D NULL; + KASSERT((ldvp->v_vflag & VV_ROOT) =3D=3D 0 || + ((dvp->v_vflag & VV_ROOT) !=3D 0 && (flags & ISDOTDOT) =3D=3D 0), + ("ldvp %p fl %#x dvp %p fl %#x flags %#x", ldvp, ldvp->v_vflag, + dvp, dvp->v_vflag, flags)); error =3D VOP_LOOKUP(ldvp, &lvp, cnp); if (error =3D=3D EJUSTRETURN && (flags & ISLASTCN) && (dvp->v_mount->mnt_flag & MNT_RDONLY) && After that, you could try the patch which I posted at winter, but which was not tested. I do not know whether it is of any help, and I do need the debugging information with the patch above before I can make any conclusions. diff --git a/sys/fs/nullfs/null_subr.c b/sys/fs/nullfs/null_subr.c index fa6c4af..3f74579 100644 --- a/sys/fs/nullfs/null_subr.c +++ b/sys/fs/nullfs/null_subr.c @@ -251,6 +251,7 @@ null_nodeget(mp, lowervp, vpp) vp->v_type =3D lowervp->v_type; vp->v_data =3D xp; vp->v_vnlock =3D lowervp->v_vnlock; + vp->v_vflag =3D lowervp->v_vflag & VV_ROOT; error =3D insmntque1(vp, mp, null_insmntque_dtr, xp); if (error !=3D 0) return (error); --lmwYJyD+fGI+a3sE Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBAgAGBQJT05WXAAoJEJDCuSvBvK1BeogP/jNVZIb8Bz6mf5ec2OimQBMZ H3bTLf+KHW1eR6F9CHLLafgmoiIf4Pa735Uer8BEruxvbwKOF13yqnRTMk2UEyNG bPe1uIV/+KAMfHgdPFUUo/46Tav9xCLAYbYPBBthTl+4pW5ZoG7h6IKF9zEQZQy4 7qOLAp5tZjFMT2zCKpT105vXYs3mgEZHKIotLzT/SmTD6ddpDH7oYBSrRmtRe1LD wGmMplA2SWiMi7/kFHafQbMhDS7fQXZ0JJJnQbYO1SgSFm5eBh/eCfzGNh48RJCr PJ4Br8v3N0Hw1p8FMzFoZ4nk7e4pz0d/WPV3jh/JPJwb1rQFCRa37e9zeWsqIdQm pp+dGFOVcFGQByAlC9Q6+U0l2DKEMp7BiBN+F2YAlYE+sgzh2fZr+Gj24pl6nVC7 ZTj3gZOwIP5cw0SwWQAQUIob3Lj8zkh0nk5tCUJCpUh1kHSc9ySAnvgBI+CWU4no lLrUE1Zk4XX/xhmP4gDP6Nl0KnjLvVc1L699r0/O0+S1iHbC4ny/vd13fkwhM7Wa M49jn3WpF4n7FC7hX/XReT8HU8TnLmotrfQdBUHiiJGBpVOCRYJQ2osmQuBbGOqL UIDoyIGJJ7cklfchLsR86QwRKfb6NYQ57OABfkgX62UHkwlVi4FfqJ61A+Ub+cXE Rj/qIdlxxN1WuxMz74KP =MPp0 -----END PGP SIGNATURE----- --lmwYJyD+fGI+a3sE--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20140726114839.GF93733>