Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1iq12u-0004zq-Cf for pgsql-hackers@arkaria.postgresql.org; Fri, 10 Jan 2020 20:38:16 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1iq12s-0000wu-Hl for pgsql-hackers@arkaria.postgresql.org; Fri, 10 Jan 2020 20:38:14 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1iq12s-0000wn-4j for pgsql-hackers@lists.postgresql.org; Fri, 10 Jan 2020 20:38:14 +0000 Received: from tamriel.snowman.net ([2001:470:e38f::11]) by makus.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1iq12l-0005ER-Pb for pgsql-hackers@lists.postgresql.org; Fri, 10 Jan 2020 20:38:12 +0000 Received: by tamriel.snowman.net (Postfix, from userid 1000) id C6B765F799; Fri, 10 Jan 2020 15:38:07 -0500 (EST) Date: Fri, 10 Jan 2020 15:38:07 -0500 From: Stephen Frost To: Tom Lane Cc: Peter , pgsql-hackers@lists.postgresql.org Subject: Re: 12.1 not useable: clientlib fails after a dozen queries (GSSAPI ?) Message-ID: <20200110203807.GC3195@tamriel.snowman.net> References: <20200109181822.GA74698@gate.oper.dinoex.org> <7042.1578595681@sss.pgh.pa.us> <20200109205319.GA85142@gate.oper.dinoex.org> <15232.1578605504@sss.pgh.pa.us> <20200110022342.GA92515@gate.oper.dinoex.org> <12348.1578679149@sss.pgh.pa.us> <16362.1578684322@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="iK81oC7B6hkgNW1o" Content-Disposition: inline In-Reply-To: <16362.1578684322@sss.pgh.pa.us> User-Agent: Mutt/1.5.24 (2015-08-30) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --iK81oC7B6hkgNW1o Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Greetings, * Tom Lane (tgl@sss.pgh.pa.us) wrote: > I wrote: > > I haven't run it further to ground than that, but there's definitely > > something fishy here. Based on just these results one would be hard > > pressed to say if it's our bug or FreeBSD's, but your report that you > > don't see the failure with PG 11 makes it sound like our problem. >=20 > Ah, I have it: whoever wrote pg_GSS_read() failed to pay attention > to the fact that setting errno is a critical part of its API. > Sometimes it returns -1 while leaving errno in a state that causes > pqReadData to draw the wrong conclusions. In particular that can > happen when it reads an incomplete packet, and that's very timing > dependent, which is why this is so ticklish to reproduce. Ah-hah. Not sure if that was Robbie or myself (probably me, really, since I rewrote a great deal of that code). I agree that the regression tests don't test with very much data, but I tested pushing quite a bit of data through and didn't see any issues with my testing. Apparently I was getting pretty lucky. :/ > I'll have a patch in a little while. That's fantastic, thanks! Stephen --iK81oC7B6hkgNW1o Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBCgAGBQJeGOCvAAoJEO1sijiDR2RV2bgP/RjQqDLKSPmUBxiF07t7ChPf cAwMPl6TFolrkXzwDmoUb8EE0AHC1OkA3O23pPwDE6FK2Bl+jAVmTPaaIaJwasDu bCu6l0JSy7mwQhMj99Qd7THV6+8ZITCsshjJaqdmrttLzS/FzeToq4D1IKUA2qx6 Rn/PrKeWwxRq+6jRpAV+p99ARpWNqxGkfzOuGLYgPLWBL2IdRvAd0cuxVatUsKHs oiw7MdGoUu/lSB2a2LoVnLHvyvAi+9im5dfhjc+6QlYHBjB6Hv5fN79gHw1Xn2wd Mfionl9t+GNEFoFjhU/K4TH8EBUOLb9hLhnC38xqErYT+T4O7ujX20pXR3NoIY+n v63jcRWUCsKbAGL7uPlxdSfEViEq2UJq+c2HVbFMhaT0cQy8peum/R1bEIqCewua WW3+hwlBKwQXo4vfohib7ZVrsk574U6U/+eB3svl0oLILok+Qi99DPOCLjrMfZYZ 0FK7NAFeuxk/4y+FsaZ15O4h/xc8tF+x6oiq9Ao49uvRjWjOvBrolKsAiuYRWnEi SR8pDijbN6zv4X5EKtfIYucQrzP3EJ9naV3vBtuaX6XFbLyMq7y1nnBTx0J9dp2s BXTANkan98owTGQWeqy/l/R3Dn+xxYG7huIjoh2w0As49OGMVaMyW+p/6CdvZOiV mhZy4xRVbP3q54zS6F8z =yFJn -----END PGP SIGNATURE----- --iK81oC7B6hkgNW1o--