PHP's pg_connect() and non-standard location of the socket (was: REPOST: redefining location of the socket file /tmp/.s.PGSQL.5432) - Mailing list pgsql-general

From Arcady Genkin
Subject PHP's pg_connect() and non-standard location of the socket (was: REPOST: redefining location of the socket file /tmp/.s.PGSQL.5432)
Date
Msg-id r1z7kyhtop4.fsf_-_@gnu.cdf.toronto.edu
Whole thread Raw
In response to Re: REPOST: redefining location of the socket file /tmp/.s.PGSQL.5432  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: PHP's pg_connect() and non-standard location of the socket (was: REPOST: redefining location of the socket file /tmp/.s.PGSQL.5432)  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
Tom Lane <tgl@sss.pgh.pa.us> writes:

> Arcady Genkin <a.genkin@utoronto.ca> writes:
> > Tom Lane <tgl@sss.pgh.pa.us> writes:
> > Can I redefine location of the UNIX domain socket file to be other
> > than /tmp/.s.PGSQL.5432?
> >>
> >> Yes, in 7.1 this is a supported option.  See unix_socket_directory
> >> parameter.
>
> > Thanks a lot, this is what I was looking for.  I have another
> > question, though: how are the clients (mod_php4 for e.g.) going to
> > know the non-standard location of the socket file?
>
> They're not, unless you tell them, which is why runtime setting of the
> parameter isn't all that useful IMHO.  But some people wanted it, so
> there it is.

Hmm...  How would I tell that to `psql'?  Via "-v" parameter?
I wonder if there is a way to tell the PHP script where the socket
is...  The documentation of pg_connect() function is not exhaustive:
there is an "options" field for connection, but nowhere does it
explain syntax of specifying the options, nor what sort of options it
is expecting.
http://www.php.net/manual/en/function.pg-connect.php

Is there anyone knowledgeable with PHP in here?  PHP's mailing lists
have been down for a few weeks because of transition to new server
or something else.

Many thanks,
--
Arcady Genkin
i=1; while 1, hilb(i); i=i+1; end

pgsql-general by date:

Previous
From: Martín Marqués
Date:
Subject: Re: Permissions & Ownership (BUG?)
Next
From: Doug McNaught
Date:
Subject: Re: Q: pgaccess + restoring a table from a previous txt export