Unix Technical Forum

BUG #2642: Connection problems without IPv6

This is a discussion on BUG #2642: Connection problems without IPv6 within the pgsql Bugs forums, part of the PostgreSQL category; --> The following bug has been logged online: Bug reference: 2642 Logged by: Christoph Zwerschke Email address: cito@online.de PostgreSQL version: ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Bugs

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-10-2008, 11:14 AM
Christoph Zwerschke
 
Posts: n/a
Default BUG #2642: Connection problems without IPv6


The following bug has been logged online:

Bug reference: 2642
Logged by: Christoph Zwerschke
Email address: cito@online.de
PostgreSQL version: 8.1.4
Operating system: Win XP
Description: Connection problems without IPv6
Details:

I am using PostgreSQL 8.1.4 on Win XP, installed from the official binary.

When I start the PostgreSQL service, and I have my LAN network interface
activated with TCP/IP installed, but IPv6 deinstalled, I cannot connect to
the PostgreSQL database. In the log file, I get the following error
message:

"LOG: could not receive data from client: An operation was attempted on
something that is not a socket."

This problem does *not* happen if:

- the LAN network interface is deactivated or
- the TCP/IP protocol is deactivated or
- the TCP/IP protocol is activated, and TCP/IP v6 protocol is installed
(must not be activated)

It happens only if:

- the LAN network interface is activated and
- the TCP/IP protocol is activated and
- the TCP/IP v6 protocol is not installed

If this problem cannot be fixed, it should at least be mentioned in the
Windows FAQ
(http://pginstaller.projects.postgres...Q_windows.html) .

---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
choose an index scan if your joining column's datatypes do not
match

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-10-2008, 11:14 AM
Tom Lane
 
Posts: n/a
Default Re: BUG #2642: Connection problems without IPv6

"Christoph Zwerschke" <cito@online.de> writes:
> It happens only if:


> - the LAN network interface is activated and
> - the TCP/IP protocol is activated and
> - the TCP/IP v6 protocol is not installed


Perhaps you have a name server that is reporting only an IPv6 address
for your machine? Turning off the LAN prevents contacting that server?

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 04-10-2008, 11:14 AM
Christoph Zwerschke
 
Posts: n/a
Default Re: BUG #2642: Connection problems without IPv6

Tom Lane wrote:
> Perhaps you have a name server that is reporting only an IPv6
> address for your machine? Turning off the LAN prevents contacting
> that server?


No, and I'm using only localhost as address, i.e. I am contacting
localhost, and I have listen_addresses = localhost in postgresql.conf.
My name server does not resolve internal names (I'm using LMHOSTS). All
other programs do work with that configuration (i.e. IPv6 uninstalled).

However, I just noticed that when I stop the DNS client (caching)
service, then the problem disappears as well. Strange.

-- Christoph

---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
choose an index scan if your joining column's datatypes do not
match

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 04-10-2008, 11:14 AM
Christoph Zwerschke
 
Posts: n/a
Default Re: BUG #2642: Connection problems without IPv6

Some more infos: When I start and stop the postgres service, then very
rarely it happens that it works, particularly when I start and stop some
other services as well, such as the DNS caching client. But it is not
reproducible. Maybe a timing issue?

Can anybody reproduce this problem on Win XP?

When I switched on as much debug info in the log as possible, here is
what I got:

2006-09-22 12:39:55 LOG: 00000: transaction ID wrap limit is
2147484148, limited by database "postgres"
2006-09-22 12:39:55 LOCATION: SetTransactionIdLimit, varsup.c:234
2006-09-22 12:39:55 DEBUG: 00000: proc_exit(0)
2006-09-22 12:39:55 LOCATION: proc_exit, ipc.c:95
2006-09-22 12:39:55 DEBUG: 00000: shmem_exit(0)
2006-09-22 12:39:55 LOCATION: shmem_exit, ipc.c:126
2006-09-22 12:39:55 DEBUG: 00000: exit(0)
2006-09-22 12:39:55 LOCATION: proc_exit, ipc.c:113
2006-09-22 12:39:55 DEBUG: 00000: reaping dead processes
2006-09-22 12:39:55 LOCATION: reaper, postmaster.c:2021
2006-09-22 12:39:55 DEBUG: 00000: waiting on 2 children
2006-09-22 12:39:55 LOCATION: win32_waitpid, postmaster.c:4046
2006-09-22 12:39:55 DEBUG: 00000: waiting on 3 children
2006-09-22 12:39:55 LOCATION: win32_waitpid, postmaster.c:4046
2006-09-22 12:39:55 DEBUG: 00000: proc_exit(0)
2006-09-22 12:39:55 LOCATION: proc_exit, ipc.c:95
2006-09-22 12:39:55 DEBUG: 00000: shmem_exit(0)
2006-09-22 12:39:55 LOCATION: shmem_exit, ipc.c:126
2006-09-22 12:39:55 DEBUG: 00000: exit(0)
2006-09-22 12:39:55 LOCATION: proc_exit, ipc.c:113
2006-09-22 12:39:55 DEBUG: 00000: reaping dead processes
2006-09-22 12:39:55 LOCATION: reaper, postmaster.c:2021
2006-09-22 12:39:55 DEBUG: 00000: waiting on 4 children
2006-09-22 12:39:55 LOCATION: win32_waitpid, postmaster.c:4046
2006-09-22 12:39:55 DEBUG: 00000: waiting on 3 children
2006-09-22 12:39:55 LOCATION: win32_waitpid, postmaster.c:4046
2006-09-22 12:39:57 DEBUG: 00000: forked new backend, pid=3476 socket=1348
2006-09-22 12:39:57 LOCATION: BackendStartup, postmaster.c:2520
2006-09-22 12:39:57 LOG: 00000: connection received: host=localhost
port=1860
2006-09-22 12:39:57 LOCATION: BackendRun, postmaster.c:2699
2006-09-22 12:39:57 localhost(1860) LOG: XX000: could not receive data
from client: An operation was attempted on something that is not a socket.
2006-09-22 12:39:57 localhost(1860) LOCATION: pq_recvbuf, pqcomm.c:712
2006-09-22 12:39:57 localhost(1860) LOG: 08P01: incomplete startup packet
2006-09-22 12:39:57 localhost(1860) LOCATION: ProcessStartupPacket,
postmaster.c:1351
2006-09-22 12:39:57 localhost(1860) DEBUG: 00000: proc_exit(0)
2006-09-22 12:39:57 localhost(1860) LOCATION: proc_exit, ipc.c:95
2006-09-22 12:39:57 localhost(1860) DEBUG: 00000: shmem_exit(0)
2006-09-22 12:39:57 localhost(1860) LOCATION: shmem_exit, ipc.c:126
2006-09-22 12:39:57 localhost(1860) DEBUG: 00000: exit(0)
2006-09-22 12:39:57 localhost(1860) LOCATION: proc_exit, ipc.c:113
2006-09-22 12:39:58 DEBUG: 00000: reaping dead processes
2006-09-22 12:39:58 LOCATION: reaper, postmaster.c:2021
2006-09-22 12:39:58 DEBUG: 00000: waiting on 4 children
2006-09-22 12:39:58 LOCATION: win32_waitpid, postmaster.c:4046
2006-09-22 12:39:58 DEBUG: 00000: server process (PID 3476) exited
with exit code 0
2006-09-22 12:39:58 LOCATION: LogChildExit, postmaster.c:2419
2006-09-22 12:39:58 DEBUG: 00000: waiting on 3 children
2006-09-22 12:39:58 LOCATION: win32_waitpid, postmaster.c:4046

---------------------------(end of broadcast)---------------------------
TIP 1: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to majordomo@postgresql.org so that your
message can get through to the mailing list cleanly

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 04-10-2008, 11:15 AM
Magnus Hagander
 
Posts: n/a
Default Re: BUG #2642: Connection problems without IPv6

> The following bug has been logged online:
>
> Bug reference: 2642
> Logged by: Christoph Zwerschke
> Email address: cito@online.de
> PostgreSQL version: 8.1.4
> Operating system: Win XP
> Description: Connection problems without IPv6
> Details:
>
> I am using PostgreSQL 8.1.4 on Win XP, installed from the
> official binary.
>
> When I start the PostgreSQL service, and I have my LAN
> network interface activated with TCP/IP installed, but IPv6
> deinstalled, I cannot connect to the PostgreSQL database. In
> the log file, I get the following error
> message:
>
> "LOG: could not receive data from client: An operation was
> attempted on something that is not a socket."
>
> This problem does *not* happen if:
>
> - the LAN network interface is deactivated or
> - the TCP/IP protocol is deactivated or
> - the TCP/IP protocol is activated, and TCP/IP v6 protocol is
> installed (must not be activated)
>
> It happens only if:
>
> - the LAN network interface is activated and
> - the TCP/IP protocol is activated and
> - the TCP/IP v6 protocol is not installed


I've never seen any mention at all about this before. Do you have any
antivirus or firewall software on this machine? Especially firewall
software has a bad habit of breaking regular winsock operations, as
we've seen in many different cases...

Also, what is the value of listen_addresses in your postgresql.conf?


//Magnus

---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?

http://archives.postgresql.org

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 04-10-2008, 11:15 AM
Christoph Zwerschke
 
Posts: n/a
Default Re: BUG #2642: Connection problems without IPv6

Magnus Hagander wrote:
>> The following bug has been logged online:
>> ...
>> When I start the PostgreSQL service, and I have my LAN
>> network interface activated with TCP/IP installed, but IPv6
>> deinstalled, I cannot connect to the PostgreSQL database. In
>> the log file, I get the following error
>> message:
>>
>> "LOG: could not receive data from client: An operation was
>> attempted on something that is not a socket."
>>
>> ...
>> It happens only if:
>>
>> - the LAN network interface is activated and
>> - the TCP/IP protocol is activated and
>> - the TCP/IP v6 protocol is not installed

>
> I've never seen any mention at all about this before. Do you have any
> antivirus or firewall software on this machine? Especially firewall
> software has a bad habit of breaking regular winsock operations, as
> we've seen in many different cases...
>
> Also, what is the value of listen_addresses in your postgresql.conf?


No, there is no special software except the Win XP firewall, but it
happens even if it switched off. I had all other services and software
deactivated, it happened anyway. It tried various values for
listen_address including 'localhost' and '127.0.0.1.', but it did not
matter. It also happens when listen_address is not set at all (which
defaults to localhost I guess). That means if you simply install
PostgreSQL on Windows XP under the above conditions (LAN interface
active, TCP/IP active, TCP/IP 6 not installed), then in the last phase
of the installation where the installer tries to connect to the database
to install some extensions, it fails already.

netstat -anb shows:

TCP 127.0.0.1:5432 0.0.0.0:0 LISTEN
[postmaster.exe]

Is here anybody with Win XP who can confirm that behavior?

-- Christoph

---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?

http://archives.postgresql.org

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 05:58 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com