From: Marinos Yannikos <mjy@geizhals.at>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: PostgreSQL Bugs <pgsql-bugs@postgresql.org>
Subject: Re: Ident authentication fails due to bind error on server (8.4.8)
Date: Sat, 18 Jun 2011 04:55:59 +0200
Message-ID: <op.vw83rlr0khmbxg@klump-pc.ghoffice> (raw)
In-Reply-To: <20339.1308333119@sss.pgh.pa.us>
References: <op.vw7q9avrkhmbxg@klump-pc>
<17691.1308325281@sss.pgh.pa.us>
<20339.1308333119@sss.pgh.pa.us>
On Fri, 17 Jun 2011 19:51:59 +0200, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> I looked at the glibc source code for getaddrinfo, and it looks like
> they do reliably set sin_port to zero when no service argument is
> provided, despite the above documentation statement. So that's why it
> works for me. But still, if you're on a non-Linux platform it seems
> possible that this is the mechanism for what's biting you.
Both client and server are Linux systems here and sin_port is 0 also
according to debug output I added. I cannot reproduce the problem reliably
(the users are much better testers it seems), so I'm a bit stuck with my
best guess being TIME_WAIT issues, perhaps FIN packets getting lost. I've
set
sysctl -w net.ipv4.tcp_tw_reuse=1
now and will post again if there is any change.
> (BTW, is it really sane to be using ident auth over a "high latency
> connection"? That would certainly suggest to me that you could be
> getting connections from untrustworthy machines ...)
Both endpoints are properly firewalled (the sane sysadmins say so) and for
this particular connection only one client IP address is allowed by
pg_hba.conf, the reason why we also use ident authentication is to allow
only a few select uid's on the client host to connect to certain DSNs.
Thanks for all the helpful info!
Regards,
Marinos
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-bugs@postgresql.org
Cc: mjy@geizhals.at, tgl@sss.pgh.pa.us
Subject: Re: Ident authentication fails due to bind error on server (8.4.8)
In-Reply-To: <op.vw83rlr0khmbxg@klump-pc.ghoffice>
References: <op.vw7q9avrkhmbxg@klump-pc> <17691.1308325281@sss.pgh.pa.us> <20339.1308333119@sss.pgh.pa.us> <op.vw83rlr0khmbxg@klump-pc.ghoffice>
* 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