Re: listening addresses

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: Postgresql Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: listening addresses
Date: 2004-03-20 16:29:01
Message-ID: 10625.1079800141@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

Andrew Dunstan <andrew(at)dunslane(dot)net> writes:
> A small problem with it was reported to me a couple of days ago - user
> had firewalled off all IP6 traffic. The stats collector happily bound
> and connected to the socket, but all the packets fell in the bit bucket.
> They found it quite hard to diagnose the problem.

> Possible solutions that occurred to me:
> . an initial "hello"-"yes i'm here" exchange to validate the address

That one seems reasonable to me. Seems like it would take just a few
more lines of code in the loop that tries to find a working socket to
check that we can send a byte and receive it. You'd have to be careful
not to block if the socket is indeed not working ... also, is it safe to
assume that a byte sent with send() is *immediately* ready to recv()?

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Dunstan 2004-03-20 16:57:21 Re: listening addresses
Previous Message Andrew Dunstan 2004-03-20 15:53:18 Re: listening addresses

Browse pgsql-patches by date

  From Date Subject
Next Message Andrew Dunstan 2004-03-20 16:57:21 Re: listening addresses
Previous Message Andrew Dunstan 2004-03-20 15:53:18 Re: listening addresses