From owner-freebsd-geom@freebsd.org Thu Oct 13 20:22:57 2016 Return-Path: Delivered-To: freebsd-geom@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CF736C109F5 for ; Thu, 13 Oct 2016 20:22:57 +0000 (UTC) (envelope-from pawel@dawidek.net) Received: from mail.dawidek.net (garage.dawidek.net [91.121.88.72]) by mx1.freebsd.org (Postfix) with ESMTP id 9E8002D5 for ; Thu, 13 Oct 2016 20:22:57 +0000 (UTC) (envelope-from pawel@dawidek.net) Received: from localhost (unknown [24.6.107.161]) by mail.dawidek.net (Postfix) with ESMTPSA id ED2C6BAF; Thu, 13 Oct 2016 22:22:49 +0200 (CEST) Date: Thu, 13 Oct 2016 22:22:46 +0200 From: Pawel Jakub Dawidek To: Terrence Koeman Cc: freebsd-geom@freebsd.org Subject: Re: fsck geom geli volume? Message-ID: <20161013202246.GA39811@garage.freebsd.pl> References: <467301d221ea$f3d6f320$db84d960$@darkness-reigns.com> <20161009071639.GA26588@garage.freebsd.pl> <46ad01d2221c$3e0aa780$ba1ff680$@darkness-reigns.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="x+6KMIRAuhnl3hBn" Content-Disposition: inline In-Reply-To: <46ad01d2221c$3e0aa780$ba1ff680$@darkness-reigns.com> X-OS: FreeBSD 11.0-CURRENT amd64 User-Agent: Mutt/1.5.24 (2015-08-30) X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Oct 2016 20:22:57 -0000 --x+6KMIRAuhnl3hBn Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Oct 09, 2016 at 12:59:44PM +0200, Terrence Koeman wrote: >=20 > [snip] > >=20 > > Please start by running: > >=20 > > # ktrace fsck -t ufs -pf /dev/vtbd1.eli > >=20 > > and see where exactly it is failing and with what error (run kdump and > > look for attempts to open /dev/vtbd1.eli device). >=20 > Unfortunately, I don't have KTRACE compiled in on this machine. However, = I found that fsck would work when I commented the attempt at mounting & reb= ooted. >=20 > I investigated and I found that when I only run "geli attach" I can run f= sck, but when I attach and then try to mount (which fails due to dirty fs) = then fsck thinks the fs is read-only. Whether I then detach and attach agai= n doesn't matter, fsck will think /dev/vtbd1.eli is read-only until reboot. I recall there was some hack that allowed to fsck device even if it was open already, but only once. Maybe this is somehow related. You could try setting kern.geom.debugflags to 4 and see where g_access(9) is failing. --=20 Pawel Jakub Dawidek http://www.wheelsystems.com FreeBSD committer http://www.FreeBSD.org Am I Evil? Yes, I Am! http://mobter.com --x+6KMIRAuhnl3hBn Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCgAGBQJX/+0WAAoJEJVLhSuxKFt1SzEP/2D+rj7PxgPxJxO7b+74egXH Z9/s1GlFlnE2R/TS2cv31zjgPtl2qLiugzFy3LBr1xGUIngG2E66q1Xt2Zbi2aoH gvlAU696+hL+b4xfkZBQZ6HiHzh2ahDpgtIo2NX+A/k/a4GfSyw3DkSHrWF2DMsT m8PnGUuO1s3EbO/uOyV0knCzDXdg4cJRGiSNHsi5dn9g+vpxGdrPS16tDcRaUHfL TB6dvXgvBJ29/xhdRX18pUnT/OSYZv5KRECsVjx+KxkkTxhE5YscbQ1qZG0OtN1w 09fGY+XT8uwXEwXUHlv8uXTvihGq5z75KWUuo5/kf52dV7JGGV+R57G8ih6VZAdS GTLthdiTTBUvpglm2WtbQx7AAF55l/1AkEFzfzcpX0tgjotMwJVokGQPFdLVEjzO uARDJYRDqG31R7yzQCauKgfT9RR/02kRkqVjmdJgJ2GAIteov+AoUyEEV+2Z7ehG 11e8EJius6I9I0it9BGmOzf/EbZ3wQDLN+bxSyR7fobMdgA8jR0vVJiNGf99zuH5 858Mi+V02zxl4YzW6hrJrYkckuqoDzXH3jxyiTCkboSOjrEG1QEH5ejjYjgs0ki+ tCqCcaQIjqac7q8fvzyoiHHQ7efz1/uwa+i2Thnzh6kXGEnrejjI3PDcSwPyvZod +6WN2hyKAvDvWsiXmIiD =d3z6 -----END PGP SIGNATURE----- --x+6KMIRAuhnl3hBn--