I have been working on a patch to implement IPv6 connections. A working
patch was supplied by Nigel Kukard about two weeks ago, and I have been
improving it. The original patch assumed the system has IPv6 functions,
like getaddrinfo(), so the major work was patching it into our existing
code that doesn't use IPv6 functions, so systems with/without IPv6 will
be able to compile the same code.
The patch is at:
It has a configure test to determine if getaddrinfo() exists, and sets a
#define and a Makefile variable appropriately. Most of the changes are
in backend/libpq/pqcomm.c::StreamServerPort and
interfaces/libpq/fe-connect.c::connectDBStart. There are also two new
files, ip.c and ip.h, which contain IP-specific support functions.
I have done my best to make the code as clear as possible. There are
more define tests than I would like, but I am hesitant to split out more
of the code into almost duplicate functions for IPv4 and IPv6
I have tested the code using IPv6 functions, and IPv4 functions. The
system also has no IPv6 support in the kernel, so that has also been
The patch is about a week away from being applied, but I thought I would
post the URL so folks can see where I am going. I am interested in
improvements and testing with various configurations.
FYI, I am also working with someone on the openprojects IRC channel
#ipv6 on an IPv6 data type.
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073
pgsql-hackers by date
|Next:||From: Shahbaz Chaudhary||Date: 2002-12-29 21:44:09|
|Subject: BITMAP Index support (and other DSS info.)|
|Previous:||From: David Walker||Date: 2002-12-28 22:11:43|
|Subject: Bad download link|