Skip site navigation (1) Skip section navigation (2)

Re: setsockopt(SO_REUSEADDR) (Re: Call for porting reports)

From: "Kardos, Dr(dot) Andreas" <kardos(at)repas-aeg(dot)de>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: <hackers(at)postgresql(dot)org>, <pgsql-ports(at)postgresql(dot)org>
Subject: Re: setsockopt(SO_REUSEADDR) (Re: Call for porting reports)
Date: 2000-04-11 15:53:39
Message-ID: 03bb01bfa3ce$1b122e30$99301eac@Dr.repas.de (view raw or flat)
Thread:
Lists: pgsql-ports
Yes, if
#define ONLY_REUSE_INET_SOCKETS
is included in solaris_sparc.h as in sco.h the postmaster can be started.

But except the libpq++, inet_aton() and SO_REUSEADDR problems there are more
problems:

1) psql cannot be made since perl is used to generate sql_help.h. There is
no perl on this machine. So configure doesn't help if perl is used anyway.

2) After I have copied sql_help.h from another platforms I could build psql,
but not start:

psql: PQconnectPoll() --  couldn't send startup packet: errno=22
Invalid argument

TCP/IP or Unix domain sockets doesn't matter.

Regards,
Andreas Kardos

-----Urspr√ľngliche Nachricht-----
Von: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
An: Kardos, Dr. Andreas <kardos(at)repas-aeg(dot)de>
Cc: <hackers(at)postgresql(dot)org>; <pgsql-ports(at)postgresql(dot)org>
Gesendet: Dienstag, 11. April 2000 16:40
Betreff: setsockopt(SO_REUSEADDR) (Re: Call for porting reports)


> "Kardos, Dr. Andreas" <kardos(at)repas-aeg(dot)de> writes:
> > SunOS 5.4 (sparc-sun-solaris) with native Sun compilers:
> > 3) The postmaster cannot be started:
>
> > sun2$ postmaster -i
> > FATAL: StreamServerPort: setsockopt(SO_REUSEADDR) failed: Protocol error
> > /usr/local/pgsql/bin/postmaster: cannot create UNIX stream port
>
> > Does SunOS not support Unix domain sockets? The same error appears
without
> > the -i option.
>
> There is an
> #ifdef ONLY_REUSE_INET_SOCKETS
> check to skip that call, but the symbol only seems to be defined for
> sco.  Now we see that Solaris doesn't like that call either.
>
> At the time the SCO patch was proposed, I thought we should just
> unconditionally skip the setsockopt(SO_REUSEADDR) call for the Unix-
> domain socket, because AFAIK it doesn't mean anything for that domain
> anyway.  Can anyone think of a reason not to do so now?  Seems to me
> that trying to apply a nonapplicable option is just asking for trouble.
>
> regards, tom lane
>


Responses

pgsql-ports by date

Next:From: Tom LaneDate: 2000-04-11 17:59:34
Subject: Re: [HACKERS] Re: setsockopt(SO_REUSEADDR) (Re: Call for porting reports)
Previous:From: Kardos, Dr. AndreasDate: 2000-04-11 13:18:34
Subject: Re: Call for porting reports

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group