pg.ddx.io pgsql-interfaces@postgresql.org mailing list archive
help / color / mirror / Atom feedPQsetdbLogin() and PQconnectdb() fail on HPUX11i 64 bits with empty servername
3+ messages / 2 participants
[nested] [flat]
* PQsetdbLogin() and PQconnectdb() fail on HPUX11i 64 bits with empty servername
@ 2006-09-20 12:38 Jan van der Weijde <Jan.van.der.Weijde@attachmate.com>
0 siblings, 2 replies; 3+ messages in thread
From: Jan van der Weijde @ 2006-09-20 12:38 UTC (permalink / raw)
To: pgsql-interfaces
Hello all,
I'm using PQsetdbLogin() or PQconnectdb() to connect to a local server
on an 64bits HP system with O/S HPUX11i. The PostgreSQL version is 8.1.4
According to the documentation I can leave out the host specification:
host:
Name of host to connect to. If this begins with a slash, it specifies
Unix-domain communication rather than TCP/IP communication; the value is
the name of the directory in which the socket file is stored. The
default behavior when host is not specified is to connect to a
Unix-domain socket in /tmp (or whatever socket directory was specified
when PostgreSQL was built). On machines without Unix-domain sockets, the
default is to connect to localhost.
However when I do that, the client givers error message:
could not connect to server:
Is the server running locally and accepting
connections on Unix domain socket "/tmp/.s.PGSQL.5432"?
while the postmaster server log the first time:
LOG: getsockname() failed: Invalid argument
and any subsequent time:
LOG: incomplete startup packet
No other socket location was specified when PostgreSQL was built, so
both the client and the server should use /tmp
When I compile the client API as 32 bits code, the error does not occur.
When I do specify localhost or an actual server name both connect
functions succeed.
Can anyone help me?
Thank you,
Jan van der Weijde
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: PQsetdbLogin() and PQconnectdb() fail on HPUX11i 64 bits with empty servername
@ 2006-09-23 18:53 Tom Lane <tgl@sss.pgh.pa.us>
parent: Jan van der Weijde <Jan.van.der.Weijde@attachmate.com>
1 sibling, 0 replies; 3+ messages in thread
From: Tom Lane @ 2006-09-23 18:53 UTC (permalink / raw)
To: Jan van der Weijde <Jan.van.der.Weijde@attachmate.com>; +Cc: pgsql-interfaces
"Jan van der Weijde" <Jan.van.der.Weijde@attachmate.com> writes:
> I'm using PQsetdbLogin() or PQconnectdb() to connect to a local server
> on an 64bits HP system with O/S HPUX11i. The PostgreSQL version is 8.1.4
> ...
> When I compile the client API as 32 bits code, the error does not occur.
> When I do specify localhost or an actual server name both connect
> functions succeed.
What exactly do you mean by "HPUX11i" --- it's not even clear whether
you are talking about a PA-RISC or an Intel platform here? What
compiler are you using, and with what options? (The output of pg_config
would be helpful.)
FWIW, I checked PG 8.1 before release on 11.23, PA-RISC and IA64 both,
and it passed regression tests in 64-bit builds, so it's not completely
broken on that platform. The regression tests do use local connections
by default.
regards, tom lane
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: PQsetdbLogin() and PQconnectdb() fail on HPUX11i 64 bits with empty servername
@ 2006-10-23 22:43 Tom Lane <tgl@sss.pgh.pa.us>
parent: Jan van der Weijde <Jan.van.der.Weijde@attachmate.com>
1 sibling, 0 replies; 3+ messages in thread
From: Tom Lane @ 2006-10-23 22:43 UTC (permalink / raw)
To: Jan van der Weijde <Jan.van.der.Weijde@attachmate.com>; +Cc: pgsql-interfaces
"Jan van der Weijde" <Jan.van.der.Weijde@attachmate.com> writes:
> I'm using PQsetdbLogin() or PQconnectdb() to connect to a local server
> on an 64bits HP system with O/S HPUX11i. The PostgreSQL version is 8.1.4
> According to the documentation I can leave out the host specification:
> However when I do that, the client givers error message:
> could not connect to server:
> Is the server running locally and accepting
> connections on Unix domain socket "/tmp/.s.PGSQL.5432"?
I tried to reproduce this on HP's testdrive machines, without success:
it seems to work fine. "64bits HP system with O/S HPUX11i" is pretty
darn vague, considering that HP supports this OS on two different
architectures and there are multiple subversions of it, but on the whole
I'd bet on a compiler problem. Is your compiler fully up-to-date with
HP's patches?
regards, tom lane
^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2006-10-23 22:43 UTC | newest]
Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2006-09-20 12:38 PQsetdbLogin() and PQconnectdb() fail on HPUX11i 64 bits with empty servername Jan van der Weijde <Jan.van.der.Weijde@attachmate.com>
2006-09-23 18:53 ` Tom Lane <tgl@sss.pgh.pa.us>
2006-10-23 22:43 ` Tom Lane <tgl@sss.pgh.pa.us>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox