[GRASSLIST:987] Re: g.select.pg problem: list OK but refuse to select available database

Glynn Clements glynn.clements at virgin.net
Thu Aug 21 07:18:33 EDT 2003


tlaronde at polynum.org wrote:

> > I'm using grass 5.0.2 and PostgreSQL 7.3.4.
> > Postmaster is running OK, and can do management with
> > psql.
> > 
> > When running g.select.pg, the connection is OK when asked
> > do list the available databases, but when selecting one
> > it says that the connexion was refused.
> 
> I'm using Postgres locally (via Unix socket). But it seems
> that the listing of the available databases is done via
> the Unix socket, but the selecting of the database is
> required by TCP/IP, since launching postmaster with the option
> of accepting connections via TCP/IP changes the error messages.

Note that the g.select.pg program in 5.0.2 (and earlier) doesn't allow
you to "undefine" a host. Once you use "g.select.pg host=...", all
subsequent connections will be via TCP/IP. You can select a different
host, but you can't revert to Unix domain sockets.

To revert to using a Unix domain socket to connect to a local
postmaster process, you have to manually delete the PG_HOST entry from
the $GISRC file (typically ~/.grassrc5).

This is fixed in the CVS HEAD version, and should be fixed in 5.0.3.

-- 
Glynn Clements <glynn.clements at virgin.net>




More information about the grass-user mailing list