Error - could not get socket error status: Invalid argument

Started by Jayaraman, Rajaram (STSD)over 16 years ago5 messagesgeneral
Jump to latest

Hi ,

I am working on hpux itanium platform

I am using postgres 8.4.0 version and have compiled 64bit libpq library.

While conneting I am getting error
" could not get socket error status: Invalid argument"

can someone help here? Why I am getting this error while connecting to database.

Regards

Rajaram J
We all make mistakes, but it's our responses to said mistakes that separate true leaders from the rest of the pack.

#2Tom Lane
tgl@sss.pgh.pa.us
In reply to: Jayaraman, Rajaram (STSD) (#1)
Re: Error - could not get socket error status: Invalid argument

"Jayaraman, Rajaram (STSD)" <rajaram.j@hp.com> writes:

I am using postgres 8.4.0 version and have compiled 64bit libpq library.

How did you do that exactly?

While conneting I am getting error
" could not get socket error status: Invalid argument"

A bit of grepping shows that it failed here:

ACCEPT_TYPE_ARG3 optlen = sizeof(optval);

if (getsockopt(conn->sock, SOL_SOCKET, SO_ERROR,
(char *) &optval, &optlen) == -1)
{
appendPQExpBuffer(&conn->errorMessage,
libpq_gettext("could not get socket error status: %s\n"),
SOCK_STRERROR(SOCK_ERRNO, sebuf, sizeof(sebuf)));

The most likely bet seems to be that optlen isn't of the width the
kernel is expecting, which would imply that configure didn't choose
the type ACCEPT_TYPE_ARG3 correctly, which would imply that HP's
done something weird and unlike every other platform. Which would
not be too much of a surprise :-(. Or possibly you gave configure
some inconsistent arguments that confused it.

regards, tom lane

#3simon
xinming.yang@hp.com
In reply to: Tom Lane (#2)
Re: Error - could not get socket error status: Invalid argument

how to fix it?

--
View this message in context: http://postgresql.1045698.n5.nabble.com/Error-could-not-get-socket-error-status-Invalid-argument-tp1884036p4513496.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.

#4Radosław Smogura
rsmogura@softperience.eu
In reply to: simon (#3)
Re: Error - could not get socket error status: Invalid argument

On Wed, 22 Jun 2011 02:42:42 -0700 (PDT), simon wrote:

how to fix it?

--
View this message in context:

http://postgresql.1045698.n5.nabble.com/Error-could-not-get-socket-error-status-Invalid-argument-tp1884036p4513496.html
Sent from the PostgreSQL - general mailing list archive at
Nabble.com.

Try manually allocate buffer of greater size, but what internal
structure will be inside I don't know, maybe HP has some additions at
the end of structure.

Regards,
Radek

#5Vijay
vijaybabu.r@hp.com
In reply to: Jayaraman, Rajaram (STSD) (#1)
Re: Error - could not get socket error status: Invalid argument

Hi,

Is this issue resolved? If yes, can you plz post the solution.

Regards,
Vijay

--
View this message in context: http://postgresql.nabble.com/Error-could-not-get-socket-error-status-Invalid-argument-tp1884036p5830654.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.

--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general