pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Peter <pmc@citylink.dinoex.sub.org>
Cc: pgsql-hackers@lists.postgresql.org, Stephen Frost <sfrost@snowman.net>
Subject: Re: 12.1 not useable: clientlib fails after a dozen queries (GSSAPI ?)
Date: Fri, 10 Jan 2020 14:25:22 -0500
Message-ID: <16362.1578684322@sss.pgh.pa.us> (raw)
In-Reply-To: <12348.1578679149@sss.pgh.pa.us>
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>

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.

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.

I'll have a patch in a little while.

			regards, tom lane





view thread (22+ messages)  latest in thread

Message-ID: <16362.1578684322@sss.pgh.pa.us>
Permalink:  ../16362.1578684322@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/16362.1578684322@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-general@postgresql.org
  Cc: tgl@sss.pgh.pa.us, pmc@citylink.dinoex.sub.org, sfrost@snowman.net
  Subject: Re: 12.1 not useable: clientlib fails after a dozen queries (GSSAPI ?)
  In-Reply-To: <16362.1578684322@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox