Re: Re: [BUGS] BUG #13611: test_postmaster_connection failed (Windows, listen_addresses = '0.0.0.0' or '::')

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: Noah Misch <noah(at)leadboat(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Tatsuo Ishii <ishii(at)postgresql(dot)org>, robertmhaas(at)gmail(dot)com, kondo(at)sraoss(dot)co(dot)jp, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Re: [BUGS] BUG #13611: test_postmaster_connection failed (Windows, listen_addresses = '0.0.0.0' or '::')
Date: 2015-10-24 06:04:39
Message-ID: 562B1F77.5050500@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs pgsql-hackers

On 10/23/15 11:10 PM, Noah Misch wrote:
> On RHEL 5 and some other "active adult" systems, "localhost" does not reach a
> listen_addresses='::' server. IPv6 is available, but "localhost" resolves to
> 127.0.0.1 only.
>
> The latest systems resolve "localhost" to both 127.0.0.1 and ::1, in which
> case PQping("host='localhost'") will attempt both addresses in an unspecified
> order. Given a postmaster with listen_addresses='0.0.0.0', contacting ::1
> first will fail (fine) or reach a different postmaster (not fine).

A design I have seen in some other systems is that you specify as a
configuration parameter an address by which you want to be contacted by
admin tools. This might be overkill here since we only need to be
contacted by a local client and the discussion is hoping to handle those
cases, but if not it would be a more principled solution.

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Maxim Boguk 2015-10-24 07:16:47 Re: BUG #13657: Some kind of undetected deadlock between query and "startup process" on replica.
Previous Message Noah Misch 2015-10-24 03:10:36 Re: Re: [BUGS] BUG #13611: test_postmaster_connection failed (Windows, listen_addresses = '0.0.0.0' or '::')

Browse pgsql-hackers by date

  From Date Subject
Next Message Victor Wagner 2015-10-24 06:32:41 Re: Patch (2): Implement failover on libpq connect level.
Previous Message Jeff Janes 2015-10-24 04:33:16 Re: 9.5Beta1 psql wrapped format expanded output