View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0000029 | Pgpool-II | Bug | public | 2012-10-18 15:03 | 2012-12-05 09:21 |
| Reporter | spork | Assigned To | t-ishii | ||
| Priority | normal | Severity | major | Reproducibility | always |
| Status | resolved | Resolution | open | ||
| OS | FreeBSD | OS Version | 8.3 | ||
| Summary | 0000029: pgpool 3.2.1 cannot connect to db hosts | ||||
| Description | Get an odd socket error when trying to connect. Have verified that the psql client can connect as the same user. Logs from pgpool: Oct 18 01:49:18 k16 pgpool[6655]: pool_initialize_private_backend_status: initialize backend status Oct 18 01:49:18 k16 pgpool[6655]: connect_inet_domain_socket: connect() failed: Socket is already connected Oct 18 01:49:18 k16 pgpool[6545]: connect_inet_domain_socket: connect() failed: Socket is already connected Oct 18 01:49:18 k16 pgpool[6655]: make_persistent_db_connection: connection to k11.i(5432) failed Oct 18 01:49:18 k16 pgpool[6545]: make_persistent_db_connection: connection to k11.i(5432) failed Oct 18 01:49:18 k16 pgpool[6545]: find_primary_node: make_persistent_connection failed Oct 18 01:49:18 k16 pgpool[6655]: connect_inet_domain_socket: connect() failed: Socket is already connected Oct 18 01:49:18 k16 pgpool[6655]: make_persistent_db_connection: connection to k29.i(5432) failed Oct 18 01:49:18 k16 pgpool[6655]: check_replication_time_lag: DB node is valid but no persistent connection Oct 18 01:49:18 k16 pgpool[6655]: check_replication_time_lag: could not connect to DB node 0, check sr_check_user and sr_check_password And from the server (PG 9.2.1): Oct 18 02:00:41 k11 postgres[84834]: [52-1] LOG: connection received: host=10.99.88.49 port=26170 Oct 18 02:00:41 k11 postgres[84834]: [53-1] LOG: incomplete startup packet Unrelated (I hope), but the build fails in the watchdog directory unless "#include <netinet/in.h>" is added wd_packet.c. | ||||
| Steps To Reproduce | Build/install PG 9.2.1, build/install pgpool 3.2.1. Config basic streaming replication load balancing and failover. | ||||
| Additional Information | Is there anything else you need? Would you like a FreeBSD 8.3 environment made available for testing with PG and other stuff already installed? | ||||
| Tags | No tags attached. | ||||
|
|
Still fails with the same errors when running 3.2-stable from 10/19/2012. Trying the 3.1 branch next to see if there's any difference (although I'm not sure that works with PG 9.2). |
|
|
3.1.5/3.1-stable (they appear to be the same) do not exhibit this bug. At the same debug level, this is the log output after all the backend processes have reported themselves: Oct 19 22:17:16 k16 pgpool[35234]: pool_initialize_private_backend_status: initialize backend status Oct 19 22:17:16 k16 pgpool[35131]: pool_ssl: SSL requested but SSL support is not available Oct 19 22:17:16 k16 pgpool[35131]: s_do_auth: auth kind: 0 Oct 19 22:17:16 k16 pgpool[35131]: s_do_auth: backend key data received Oct 19 22:17:16 k16 pgpool[35131]: s_do_auth: transaction state: I Oct 19 22:17:16 k16 pgpool[35131]: do_query: extended:0 query:SELECT pg_is_in_recovery() It then goes on to make other queries. Not sure what the SSL errors mean, I have no SSL parameters defined in the config file. What else can I provide you from the 3.2-stable install? |
|
|
OK, one last thing. If I do the following and recompile 3.2-stable, it successfully connects to the db hosts: -copy pool_connection_pool.c from 3.1-stable -add the line "volatile sig_atomic_t health_check_timer_expired;" to pool_connection_pool.c (to fix a compile error when main.c is built) So based on a diff of the two versions of pool_connection_pool.c, it appears that this commit broke something (at least on FreeBSD): http://git.postgresql.org/gitweb/?p=pgpool2.git;a=commitdiff;h=3d3fe8611b8a87e8787fc50272c59e40b28daff4 Not sure if this is helpful or not: http://cr.yp.to/docs/connect.html |
|
|
I visited the URL you introduced. Yes, there may be a problem with non-block connect(2) code in 3.1-stable head. I'll study more. |
|
|
"Socket is already connected": what is the error no and error symbol(macro)? I couldn't find it on Linux. |
|
|
I found it EISCONN. Fix committed to master and V3_2_STABLE. |
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2012-10-18 15:03 | spork | New Issue | |
| 2012-10-20 10:50 | spork | Note Added: 0000115 | |
| 2012-10-20 11:57 | spork | Note Added: 0000116 | |
| 2012-10-20 13:39 | spork | Note Added: 0000117 | |
| 2012-11-14 15:35 | t-ishii | Assigned To | => t-ishii |
| 2012-11-14 15:35 | t-ishii | Status | new => assigned |
| 2012-11-19 16:16 | t-ishii | Note Added: 0000156 | |
| 2012-11-19 18:11 | t-ishii | Note Added: 0000158 | |
| 2012-11-26 16:04 | t-ishii | Status | assigned => feedback |
| 2012-12-05 09:21 | t-ishii | Note Added: 0000176 | |
| 2012-12-05 09:21 | t-ishii | Status | feedback => resolved |