BUG #1294: Random errors (failed connection) - Mailing list pgsql-bugs

From PostgreSQL Bugs List
Subject BUG #1294: Random errors (failed connection)
Date
Msg-id 20041025205613.7BB275A1010@www.postgresql.com
Whole thread Raw
Responses Re: BUG #1294: Random errors (failed connection)
List pgsql-bugs
The following bug has been logged online:

Bug reference:      1294
Logged by:          Stefanos Harhalakis

Email address:      v13@it.teithe.gr

PostgreSQL version: 7.4.5

Operating system:   IRIX 6.5.17

Description:        Random errors (failed connection)

Details:

This bug is tested against pgsql 7.4.1 and 7.4.6 using openssl 0.9.7c and
0.9.7d.

It took me about 6 hours and a lot of compiles and step-by-step tracing to
figure it out.

Every postgresql client that runs under IRIX 6.5 seems to fail to connect to
remote clients either when using openssl or not(without ssl there are some
(random) successfull connections). The error indicates that no connection is
done at all.

The test case was:
psql or a custom client running on Irix 6.5
postmaster running on Linux 2.6.8

Trying to connect from psql@Linux -> postmaster@Irix was always successfull.
Trying to connect from psql@Other_Linux -> psql@Linux was always successfull
too, so it seemed that this was a problem with clients under Irix only.

You will know for sure that this is the case when:
You try: psql -h X.X.X.X -U xxxx yyyy
from the Irix box and it fails giving nothing more than "LOG:  incomplete
startup packet" in the server log, but if you try: strace psql -h X.X.X.X -U
xxxx yyyy then it connects (!!).

It seems that something goes wrong when postgresql is compiled to use the
poll() system call. I changed the #define HAVE_POLL to #undef HAVE_POLL and
it worked (!).

Please consider changing the default for IRIX systems to select() instead of
poll().

TIA and keep up the good work...

<<V13>>

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #1293: INSERT INTO test (f1.f2) VALUES (1,2) - wrong diagnostic
Next
From: Kris Jurka
Date:
Subject: aggregates other than count accpet *