[GRASS-user] Unable to link to postgis/postgresql

Hi list,

I hope this is not a duplicate, but I could not find any solution on the
web by know.

I trying to connect to a remote postgresql database, without success.

What I have done:

1)
db.connect driver=pg
database="host=vmhydro27,dbname=cedim_rfra,port=5432"

2)db.login driver=pg database=cedim_rfra user=sluedtke password=#####
host=vmhydro27

3) db.tables -p

DBMI-PostgreSQL driver error:
Connection failed.
could not connect to server: No such file or directory
        Is the server running locally and accepting
        connections on Unix domain socket
"/var/run/postgresql/.s.PGSQL.5432"?
DBMI-PostgreSQL driver error:
Connection failed.
could not connect to server: No such file or directory
        Is the server running locally and accepting
        connections on Unix domain socket
"/var/run/postgresql/.s.PGSQL.5432"?
ERROR: Unable to open database <host=vmhydro27,dbname=cedim_rfra,port=5432>

I tried all drivers (odbc, ogr, pg) that made sense to me, no success.

It is no problem to connect QGIS, R and python to this db and visualize
the data.

I am using Kubuntu 16.04 with GRASS 7.04.

[I] /u/bin  apt-cache show grass

                            Mon 12 Sep 2016 13:20:37 CEST
Package: grass
Status: install ok installed
Priority: optional
Section: metapackages
Installed-Size: 33
Maintainer: Debian GIS Project <pkg-grass-devel@lists.alioth.debian.org>
Architecture: all
Version: 7.0.4-1~xenial2
Replaces: grass7, grass70
Provides: grass7, grass70
Depends: grass-core, grass-gui
Recommends: grass-doc
Suggests: grass-dev
Conflicts: grass7, grass70
Description: Geographic Resources Analysis Support System (GRASS GIS)
Commonly referred to as GRASS, this is a Geographic Information
System (GIS) used for geospatial data management and analysis,
image processing, graphics/map production, spatial modeling, and
visualization. GRASS is currently used in academic and commercial
settings around the world, as well as by many government agencies
and environmental consulting companies.
.
Install this virtual package to get a full GRASS system.
Description-md5: 927e5df9adc0c220121824a1dcc21063
Homepage: http://grass.osgeo.org/

I am able to get info of a certain layer using ogrinfo with the
connection string.

Any help is appreciated.

Cheers,

Stefan

Le Mon, 12 Sep 2016 13:22:29 +0200,
Stefan Lüdtke <sluedtke@gfz-potsdam.de> a écrit :

Hi list,

I hope this is not a duplicate, but I could not find any solution on
the web by know.

I trying to connect to a remote postgresql database, without success.

What I have done:

1)
db.connect driver=pg
database="host=vmhydro27,dbname=cedim_rfra,port=5432"

As this is the standard port, you could try without the port=5432 part
in the database definition string.

2)db.login driver=pg database=cedim_rfra user=sluedtke password=#####
host=vmhydro27

Try with either no database info in the db.login call, or with the port
parameter set, i.e.

db.login user=sluedtke password=######

or

db.login driver=pg database=cedim_rfra user=sluedtke password=#####
host=vmhydro27 port=5432

Moritz

Hi Moritz,

thanks for the hints but non of them worked.

As additional info. I have configured a couple of odbc connections I use
in R. Using these connections in GRASS do not give an error but do not
show any tables. Those odbc connections work as well from libreoffice.

That's it from my side so far.

Stefan

On 13/09/16 10:19, Moritz Lennert wrote:

Le Mon, 12 Sep 2016 13:22:29 +0200,
Stefan Lüdtke <sluedtke@gfz-potsdam.de> a écrit :

Hi list,

I hope this is not a duplicate, but I could not find any solution on
the web by know.

I trying to connect to a remote postgresql database, without success.

What I have done:

1)
db.connect driver=pg
database="host=vmhydro27,dbname=cedim_rfra,port=5432"

As this is the standard port, you could try without the port=5432 part
in the database definition string.

2)db.login driver=pg database=cedim_rfra user=sluedtke password=#####
host=vmhydro27

Try with either no database info in the db.login call, or with the port
parameter set, i.e.

db.login user=sluedtke password=######

or

db.login driver=pg database=cedim_rfra user=sluedtke password=#####
host=vmhydro27 port=5432

Moritz

--
Stefan Lüdtke

Section 5.4- Hydrology
Phone: +49(0)331-288-2821
Fax: +49(0)331-288-1570
Email: sluedtke@gfz-potsdam.de
___________________________________________

Helmholtz Centre Potsdam
GFZ German Research Centre for Geosciences
Foundation under public law of the federal state
of Brandenburg
Telegrafenberg, D-14473 Potsdam

Hi list,

Always the same problem with a remote Postgresql connection, with grass 7.0.4 and above (7.2 and 7.3). With grass 7.0.0, the connection to postgresql is perfect. I don’t try with 7.0.1, 7.0.2 and 7.0.3

All my other soft using Postgresql work fine (i.e. pgadmin, odoo, caldav, carddav, libreoffice, …)

The problem is the for all the PC on my network (server under Centos 7, workstations under Fedora 19, 21 or 22)

(attachments)

bcg_logo.gif
BCG_bas.gif
In-2C-21px-TM.png
icone_fb.gif
Modere_SocialMarketer_logomark.png

···

Le 12/09/16 13:22, Stefan Lüdtke a écrit :

Hi list,

I hope this is not a duplicate, but I could not find any solution on the
web by know.

I trying to connect to a remote postgresql database, without success.

What I have done:

1)
db.connect driver=pg	       	
database="host=vmhydro27,dbname=cedim_rfra,port=5432"

2)db.login driver=pg database=cedim_rfra user=sluedtke password=#####
host=vmhydro27

3) db.tables -p

DBMI-PostgreSQL driver error:
Connection failed.
could not connect to server: No such file or directory
        Is the server running locally and accepting
        connections on Unix domain socket
"/var/run/postgresql/.s.PGSQL.5432"?
DBMI-PostgreSQL driver error:
Connection failed.
could not connect to server: No such file or directory
        Is the server running locally and accepting
        connections on Unix domain socket
"/var/run/postgresql/.s.PGSQL.5432"?
ERROR: Unable to open database <host=vmhydro27,dbname=cedim_rfra,port=5432>

I tried all drivers (odbc, ogr, pg) that made sense to me, no success.

It is no problem to connect QGIS, R and python to this db and visualize
the data.

I am using Kubuntu 16.04 with GRASS 7.04.

[I]  /u/bin  apt-cache show grass

                            Mon 12 Sep 2016 13:20:37 CEST
Package: grass
Status: install ok installed
Priority: optional
Section: metapackages
Installed-Size: 33
Maintainer: Debian GIS Project [<pkg-grass-devel@lists.alioth.debian.org>](mailto:pkg-grass-devel@lists.alioth.debian.org)
Architecture: all
Version: 7.0.4-1~xenial2
Replaces: grass7, grass70
Provides: grass7, grass70
Depends: grass-core, grass-gui
Recommends: grass-doc
Suggests: grass-dev
Conflicts: grass7, grass70
Description: Geographic Resources Analysis Support System (GRASS GIS)
 Commonly referred to as GRASS, this is a Geographic Information
 System (GIS) used for geospatial data management and analysis,
 image processing, graphics/map production, spatial modeling, and
 visualization. GRASS is currently used in academic and commercial
 settings around the world, as well as by many government agencies
 and environmental consulting companies.
 .
 Install this virtual package to get a full GRASS system.
Description-md5: 927e5df9adc0c220121824a1dcc21063
Homepage: [http://grass.osgeo.org/](http://grass.osgeo.org/)

I am able to get info of a certain layer using ogrinfo with the
connection string.

Any help is appreciated.

Cheers,

Stefan

_______________________________________________
grass-user mailing list
[grass-user@lists.osgeo.org](mailto:grass-user@lists.osgeo.org)
[http://lists.osgeo.org/mailman/listinfo/grass-user](http://lists.osgeo.org/mailman/listinfo/grass-user)

Benoit André
Directeur - Gérant

benoit.andre@bcgeol.be
Tel. | +32 475 61 84 94
skype | benoit_andre_bcg
Voir le profil de Benoit André sur LinkedIn

BCG SPRL
Tél. | +32(0)81 58 26 11
Fax | +32(0)81 58 26 12
Chemin de la Foliette, 4 Bte 2
B-5000 - Namur
www.bcgeol.be - plan d’accès

BCG LOGO

Suivez-nous sur Lien LinkedinLien Facebook

Allons plus loin dans le respect de l’environnement : N’utilisons que des produits sans empreinte écologiqueLogo Modere

This really is a serious issue.

Would it be possible for you to provide a reproducible example ? Ideally
starting out from the North Caroline data. Something that creates a new
postgresql database, redefined db.connect to link to that, g.copy a few
maps and then see if the connection problem still happens ?

Ideally this should go into a bug ticket and IMHO it should definitely
be a blocker for the upcoming releases as I would consider this basic
functionality.

Moritz

Le Wed, 14 Sep 2016 11:22:57 +0200,
Benoit ANDRE <benoit.andre@bcgeol.be> a écrit :

Hi list,

Always the same problem with a remote Postgresql connection, with
grass 7.0.4 and above (7.2 and 7.3). With grass 7.0.0, the
connection to postgresql is perfect. I don't try with 7.0.1, 7.0.2
and 7.0.3

All my other soft using Postgresql work fine (i.e. pgadmin, odoo,
caldav, carddav, libreoffice, ...)

The problem is the for all the PC on my network (server under Centos
7, workstations under Fedora 19, 21 or 22)

Le 12/09/16 13:22, Stefan Lüdtke a écrit :
> Hi list,
>
> I hope this is not a duplicate, but I could not find any solution
> on the web by know.
>
> I trying to connect to a remote postgresql database, without
> success.
>
> What I have done:
>
> 1)
> db.connect driver=pg
> database="host=vmhydro27,dbname=cedim_rfra,port=5432"
>
> 2)db.login driver=pg database=cedim_rfra user=sluedtke
> password=##### host=vmhydro27
>
> 3) db.tables -p
>
> DBMI-PostgreSQL driver error:
> Connection failed.
> could not connect to server: No such file or directory
> Is the server running locally and accepting
> connections on Unix domain socket
> "/var/run/postgresql/.s.PGSQL.5432"?
> DBMI-PostgreSQL driver error:
> Connection failed.
> could not connect to server: No such file or directory
> Is the server running locally and accepting
> connections on Unix domain socket
> "/var/run/postgresql/.s.PGSQL.5432"?
> ERROR: Unable to open database
> <host=vmhydro27,dbname=cedim_rfra,port=5432>
>
> I tried all drivers (odbc, ogr, pg) that made sense to me, no
> success.
>
> It is no problem to connect QGIS, R and python to this db and
> visualize the data.
>
> I am using Kubuntu 16.04 with GRASS 7.04.
>
> [I] /u/bin  apt-cache show grass
>
>
> Mon 12 Sep 2016 13:20:37 CEST
> Package: grass
> Status: install ok installed
> Priority: optional
> Section: metapackages
> Installed-Size: 33
> Maintainer: Debian GIS Project
> <pkg-grass-devel@lists.alioth.debian.org> Architecture: all
> Version: 7.0.4-1~xenial2
> Replaces: grass7, grass70
> Provides: grass7, grass70
> Depends: grass-core, grass-gui
> Recommends: grass-doc
> Suggests: grass-dev
> Conflicts: grass7, grass70
> Description: Geographic Resources Analysis Support System (GRASS
> GIS) Commonly referred to as GRASS, this is a Geographic Information
> System (GIS) used for geospatial data management and analysis,
> image processing, graphics/map production, spatial modeling, and
> visualization. GRASS is currently used in academic and commercial
> settings around the world, as well as by many government agencies
> and environmental consulting companies.
> .
> Install this virtual package to get a full GRASS system.
> Description-md5: 927e5df9adc0c220121824a1dcc21063
> Homepage: http://grass.osgeo.org/
>
>
> I am able to get info of a certain layer using ogrinfo with the
> connection string.
>
> Any help is appreciated.
>
> Cheers,
>
> Stefan
>
>
>
>
>
> _______________________________________________
> grass-user mailing list
> grass-user@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/grass-user

Hi,

2016-09-12 13:22 GMT+02:00 Stefan Lüdtke <sluedtke@gfz-potsdam.de>:

1)
db.connect driver=pg
database="host=vmhydro27,dbname=cedim_rfra,port=5432"

2)db.login driver=pg database=cedim_rfra user=sluedtke password=#####
host=vmhydro27

please try out:

db.connect driver=pg database=edim_rfra
db.login driver=pg database=cedim_rfra user=sluedtke password=#####
host=vmhydro27 port=5432

Ma

--
Martin Landa
http://geo.fsv.cvut.cz/gwiki/Landa
http://gismentors.cz/mentors/landa

Hi,

2016-09-14 13:06 GMT+02:00 Martin Landa <landa.martin@gmail.com>:

I tested with 7.0.5.svn:

db.connect dri=pg datab=mydb
db.login dri=pg datab=mydb host=myhost user=myuser pass=mypw port=5432
db.tables -p

works. Could you try to enable debug message and post here relevant information:

g.gisenv set=debug=3
db.tables -p 2>&1 | grep open_database

(be aware that the log will contain all login information including
real password - good idea to change it before post here :slight_smile:

Ma

--
Martin Landa
http://geo.fsv.cvut.cz/gwiki/Landa
http://gismentors.cz/mentors/landa

Hi,

2016-09-14 13:40 GMT+02:00 Martin Landa <landa.martin@gmail.com>:

works. Could you try to enable debug message and post here relevant information:

g.gisenv set=debug=3
db.tables -p 2>&1 | grep open_database

(be aware that the log will contain all login information including
real password - good idea to change it before post here :slight_smile:

hm, with 7.0.4 you will not get relevant info, I fix debug message in
r69481. Could you try 7.0.5svn? You should get:

D3/5: db_driver_open_database(): host = myhost, port = 5432, options =
(null), tty = (null), dbname = mydb, user = myuser, password = mypw
schema = (null)

Ma

--
Martin Landa
http://geo.fsv.cvut.cz/gwiki/Landa
http://gismentors.cz/mentors/landa

Hi Martin,

Here is my log :

.-(/disques/divers/linux-1/archive/GIS/grass/grass-7.0/pyrite/grass-7.0.svn_src_snapshot_2016_09_10)------------------------------------------------------------(benoit@pyrite)-
--> db.connect dri=pg datab=administration D1/3: G_set_program_name(): db.connect D2/3: G_file_name(): path = /disques/grassdata/BCG_V7/benoit D2/3: dbDbmscap(): opendir [/disques/divers/linux-1/archive/GIS/grass/grass-7.0/pyrite/grass-7.0.svn_src_snapshot_2016_09_10/dist.i686-pc-linux-gnu/driver/db/] D3/3: db_get_login(): drv=[pg] db=[administration] D3/3: read_file(): DB login file = </home/benoit/.grass7/dblogin> .-(/disques/divers/linux-1/archive/GIS/grass/grass-7.0/pyrite/grass-7.0.svn_src_snapshot_2016_09_10)------------------------------------------------------------(benoit@pyrite)- → db.login dri=pg datab=administration host=192.168.1.200 user=benoit port=5432
D1/3: G_set_program_name(): db.login
D2/3: G_file_name(): path = /disques/grassdata/BCG_V7/benoit
D2/3: dbDbmscap(): opendir [/disques/divers/linux-1/archive/GIS/grass/grass-7.0/pyrite/grass-7.0.svn_src_snapshot_2016_09_10/dist.i686-pc-linux-gnu/driver/db/]
D3/3: db_set_login(): drv=[pg] db=[administration] usr=[benoit] pwd=[(null)] host=[192.168.1.200] port=[5432]
D3/3: read_file(): DB login file = </home/benoit/.grass7/dblogin>
D3/3: write_file(): DB login file = </home/benoit/.grass7/dblogin>
.-(/disques/divers/linux-1/archive/GIS/grass/grass-7.0/pyrite/grass-7.0.svn_src_snapshot_2016_09_10)------------------------------------------------------------(benoit@pyrite)-
`–> db.tables -p
D1/3: G_set_program_name(): db.tables
D2/3: G_file_name(): path = /disques/grassdata/BCG_V7/benoit
D2/3: dbDbmscap(): opendir [/disques/divers/linux-1/archive/GIS/grass/grass-7.0/pyrite/grass-7.0.svn_src_snapshot_2016_09_10/dist.i686-pc-linux-gnu/driver/db/]
D2/3: dbDbmscap(): opendir [/disques/divers/linux-1/archive/GIS/grass/grass-7.0/pyrite/grass-7.0.svn_src_snapshot_2016_09_10/dist.i686-pc-linux-gnu/driver/db/]
D1/3: db_d_init_error(): PostgreSQL
D3/3: db_get_login(): drv=[pg] db=[administration]
D3/3: read_file(): DB login file = </home/benoit/.grass7/dblogin>
D3/3: ret = 3 : drv=[pg] db=[administration] usr=[benoit] pwd= host=, port=
D3/3: db_driver_open_database(): driver=pg database definition = ‘administration’
D3/3: parse_conn: ‘administration’
D3/3: db_driver_open_database(): host = (null), port = (null), options = (null), tty = (null), dbname = administration, user = (null), password = (null), host = (null), port = (null) schema = (null)
D3/3: db_get_login(): drv=[pg] db=[administration]
D3/3: read_file(): DB login file = </home/benoit/.grass7/dblogin>
D3/3: ret = 3 : drv=[pg] db=[administration] usr=[benoit] pwd= host=, port=
DBMI-PostgreSQL erreur de pilote :
Connection failed.
n’a pas pu se connecter au serveur : Aucun fichier ou dossier de ce type
Le serveur est-il actif localement et accepte-t-il les connexions sur la
socket Unix « /var/run/postgresql/.s.PGSQL.5432 » ?

DBMI-PostgreSQL erreur de pilote :
Connection failed.
n’a pas pu se connecter au serveur : Aucun fichier ou dossier de ce type
Le serveur est-il actif localement et accepte-t-il les connexions sur la
socket Unix « /var/run/postgresql/.s.PGSQL.5432 » ?

ERREUR :Unable to open database
.-(/disques/divers/linux-1/archive/GIS/grass/grass-7.0/pyrite/grass-7.0.svn_src_snapshot_2016_09_10)------------------------------------------------------------(benoit@pyrite)-
--> db.tables -p 2>&1 | grep open_database D3/3: db_driver_open_database(): driver=pg database definition = 'administration' D3/3: db_driver_open_database(): host = (null), port = (null), options = (null), tty = (null), dbname = administration, user = (null), password = (null), host = (null), port = (null) schema = (null) .-(/disques/divers/linux-1/archive/GIS/grass/grass-7.0/pyrite/grass-7.0.svn_src_snapshot_2016_09_10)------------------------------------------------------------(benoit@pyrite)-

(attachments)

btn_liprofile_blue_80x15_fr_FR.png
bcg_logo.gif
BCG_bas.gif
In-2C-21px-TM.png
icone_fb.gif
Modere_SocialMarketer_logomark.png

···

Le 14/09/16 13:40, Martin Landa a écrit :

Hi,

2016-09-14 13:06 GMT+02:00 Martin Landa [<landa.martin@gmail.com>](mailto:landa.martin@gmail.com):

I tested with 7.0.5.svn:

db.connect dri=pg datab=mydb
db.login dri=pg datab=mydb host=myhost user=myuser pass=mypw port=5432
db.tables -p

works. Could you try to enable debug message and post here relevant information:

g.gisenv set=debug=3
db.tables -p 2>&1 | grep open_database

(be aware that the log will contain all login information including
real password - good idea to change it before post here :-)

Ma

Benoit André
Directeur - Gérant

benoit.andre@bcgeol.be
Tel. | +32 475 61 84 94
skype | benoit_andre_bcg
Voir le profil de Benoit André sur LinkedIn

BCG SPRL
Tél. | +32(0)81 58 26 11
Fax | +32(0)81 58 26 12
Chemin de la Foliette, 4 Bte 2
B-5000 - Namur
www.bcgeol.be - plan d’accès

BCG LOGO

Suivez-nous sur Lien LinkedinLien Facebook

Allons plus loin dans le respect de l’environnement : N’utilisons que des produits sans empreinte écologiqueLogo Modere

Hi,

I will work through that during the weekend.

An example is not that easy with a remote database ...

Cheers,

Stefan

On 14/09/16 13:52, Martin Landa wrote:

Hi,

2016-09-14 13:40 GMT+02:00 Martin Landa <landa.martin@gmail.com>:

works. Could you try to enable debug message and post here relevant information:

g.gisenv set=debug=3
db.tables -p 2>&1 | grep open_database

(be aware that the log will contain all login information including
real password - good idea to change it before post here :slight_smile:

hm, with 7.0.4 you will not get relevant info, I fix debug message in
r69481. Could you try 7.0.5svn? You should get:

D3/5: db_driver_open_database(): host = myhost, port = 5432, options =
(null), tty = (null), dbname = mydb, user = myuser, password = mypw
schema = (null)

Ma

--
Stefan Lüdtke

Section 5.4- Hydrology
Phone: +49(0)331-288-2821
Fax: +49(0)331-288-1570
Email: sluedtke@gfz-potsdam.de
___________________________________________

Helmholtz Centre Potsdam
GFZ German Research Centre for Geosciences
Foundation under public law of the federal state
of Brandenburg
Telegrafenberg, D-14473 Potsdam

Hi,

2016-09-14 17:43 GMT+02:00 Benoit ANDRE <benoit.andre@bcgeol.be>:

`--> db.login dri=pg datab=administration host=192.168.1.200 user=benoit
port=5432

btw, no password needed for connection?

Ma

--
Martin Landa
http://geo.fsv.cvut.cz/gwiki/Landa
http://gismentors.cz/mentors/landa

Hi there,

the suggestion below works. The other one suggested later on with "dri"
instead of "driver" by Martin with 7.0.5svn as well. I get a list of
tables with db.tables -p.

But non of them shows a list of vectors/rasters when I go for the "link"
or "import" within the gui. I can select a db from that server I am
connected to, but no table is shown.

???

Did the debug output from Benoit ANDRE helps anything? I guess mine
would still be interresting?

Cheers,

Stefan

On 14/09/16 13:06, Martin Landa wrote:

Hi,

2016-09-12 13:22 GMT+02:00 Stefan Lüdtke <sluedtke@gfz-potsdam.de>:

1)
db.connect driver=pg
database="host=vmhydro27,dbname=cedim_rfra,port=5432"

2)db.login driver=pg database=cedim_rfra user=sluedtke password=#####
host=vmhydro27

please try out:

db.connect driver=pg database=edim_rfra
db.login driver=pg database=cedim_rfra user=sluedtke password=#####
host=vmhydro27 port=5432

Ma

--
Stefan Lüdtke

Section 5.4- Hydrology
Phone: +49(0)331-288-2821
Fax: +49(0)331-288-1570
Email: sluedtke@gfz-potsdam.de
___________________________________________

Helmholtz Centre Potsdam
GFZ German Research Centre for Geosciences
Foundation under public law of the federal state
of Brandenburg
Telegrafenberg, D-14473 Potsdam

Hi Martin,

I tried again with last release (7.0.5RC2) announced by Markus, but without results. Problem 's staying the same : no connection. The arguments to call ‘psql’ seems missing.

(attachments)

btn_liprofile_blue_80x15_fr_FR.png
bcg_logo.gif
BCG_bas.gif
In-2C-21px-TM.png
icone_fb.gif
Modere_SocialMarketer_logomark.png

···

Le 16/09/16 21:12, Stefan Lüdtke a écrit :

Hi there,

the suggestion below works. The other one suggested later on with "dri"
instead of "driver"  by Martin with 7.0.5svn as well. I get a list of
tables with db.tables -p.

But non of them shows a list of vectors/rasters when I go for the "link"
or "import" within the gui. I can select a db from that server I am
connected to, but no table is shown.

???

Did the debug output from Benoit ANDRE helps anything? I guess mine
would still be interresting?

Cheers,

Stefan

On 14/09/16 13:06, Martin Landa wrote:

Hi,

2016-09-12 13:22 GMT+02:00 Stefan Lüdtke [<sluedtke@gfz-potsdam.de>](mailto:sluedtke@gfz-potsdam.de):

1)
db.connect driver=pg
database="host=vmhydro27,dbname=cedim_rfra,port=5432"

2)db.login driver=pg database=cedim_rfra user=sluedtke password=#####
host=vmhydro27

please try out:

db.connect driver=pg database=edim_rfra
db.login driver=pg database=cedim_rfra user=sluedtke password=#####
host=vmhydro27 port=5432

Ma

_______________________________________________
grass-user mailing list
[grass-user@lists.osgeo.org](mailto:grass-user@lists.osgeo.org)
[http://lists.osgeo.org/mailman/listinfo/grass-user](http://lists.osgeo.org/mailman/listinfo/grass-user)

Benoit André
Directeur - Gérant

benoit.andre@bcgeol.be
Tel. | +32 475 61 84 94
skype | benoit_andre_bcg
Voir le profil de Benoit André sur LinkedIn

BCG SPRL
Tél. | +32(0)81 58 26 11
Fax | +32(0)81 58 26 12
Chemin de la Foliette, 4 Bte 2
B-5000 - Namur
www.bcgeol.be - plan d’accès

BCG LOGO

Suivez-nous sur Lien LinkedinLien Facebook

Allons plus loin dans le respect de l’environnement : N’utilisons que des produits sans empreinte écologiqueLogo Modere

Hi,

I have not tried again in order to provide debug messages. Because I am
not sure whether they show anything new/different to the messages Benoit
ANDRE showed to us but its quite a bit of effort to compile from svn.

Is that output from my side still required??

Stefan

On 21/09/16 13:42, Benoit ANDRE wrote:

Hi Martin,

I tried again with last release (7.0.5RC2) announced by Markus, but
without results. Problem 's staying the same : no connection. The
arguments to call 'psql' seems missing.

Le 16/09/16 21:12, Stefan Lüdtke a écrit :

Hi there,

the suggestion below works. The other one suggested later on with "dri"
instead of "driver" by Martin with 7.0.5svn as well. I get a list of
tables with db.tables -p.

But non of them shows a list of vectors/rasters when I go for the "link"
or "import" within the gui. I can select a db from that server I am
connected to, but no table is shown.

???

Did the debug output from Benoit ANDRE helps anything? I guess mine
would still be interresting?

Cheers,

Stefan

On 14/09/16 13:06, Martin Landa wrote:

Hi,

2016-09-12 13:22 GMT+02:00 Stefan Lüdtke <sluedtke@gfz-potsdam.de>:

1)
db.connect driver=pg
database="host=vmhydro27,dbname=cedim_rfra,port=5432"

2)db.login driver=pg database=cedim_rfra user=sluedtke password=#####
host=vmhydro27

please try out:

db.connect driver=pg database=edim_rfra
db.login driver=pg database=cedim_rfra user=sluedtke password=#####
host=vmhydro27 port=5432

Ma

_______________________________________________
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user

--

*Benoit André*
*Directeur - Gérant*

benoit.andre@bcgeol.be <mailto:benoit.andre@bcgeol.be>
Tel. | +32 475 61 84 94
skype | benoit_andre_bcg
Voir le profil de Benoit André sur LinkedIn
<https://be.linkedin.com/in/benoitandre&gt;

*BCG SPRL*
Tél. | +32(0)81 58 26 11
Fax | +32(0)81 58 26 12
Chemin de la Foliette, 4 Bte 2
B-5000 - Namur
www.bcgeol.be <http://www.bcgeol.be> - plan d'accès
<https://maps.google.be/maps/ms?msid=210366068780572446312.0004dc0b834462107c00f&msa=0&ll=50.460427,4.856445&spn=0.001279,0.002411&iwloc=0004dc0b8345e35a35a20&gt;

  BCG LOGO <http://www.bcgeol.be>

Suivez-nous sur Lien Linkedin
<https://www.linkedin.com/company/bureau-conseil-en-géologie-sprl&gt; Lien
Facebook
<https://www.facebook.com/Bureau-Conseil-en-Géologie-153924548320189/?ref=hl&gt;

Allons plus loin dans le respect de l'environnement : N'utilisons que
des produits sans empreinte écologiqueLogo Modere
<https://www.modere.eu/?referralCode=050281&gt;

--
Stefan Lüdtke

Section 5.4- Hydrology
Phone: +49(0)331-288-2821
Fax: +49(0)331-288-1570
Email: sluedtke@gfz-potsdam.de
___________________________________________

Helmholtz Centre Potsdam
GFZ German Research Centre for Geosciences
Foundation under public law of the federal state
of Brandenburg
Telegrafenberg, D-14473 Potsdam

On Sep 21, 2016 1:50 PM, “Stefan Lüdtke” <sluedtke@gfz-potsdam.de> wrote:

Hi,

I have not tried again in order to provide debug messages. Because I am
not sure whether they show anything new/different to the messages Benoit
ANDRE showed to us but its quite a bit of effort to compile from svn.

On Linux that’s not more than

svn update
make

Since most was compiled before, it will take something like 60sec…

Finally perhaps (not me, I just run GRASS GIS directly from the compiled source code directory):
make install

Is that output from my side still required??

Does it work for you?

Markus

I'll give it a go ... that sounds doable :wink:

On 21/09/16 14:00, Markus Neteler wrote:

On Sep 21, 2016 1:50 PM, "Stefan Lüdtke" <sluedtke@gfz-potsdam.de
<mailto:sluedtke@gfz-potsdam.de>> wrote:

Hi,

I have not tried again in order to provide debug messages. Because I am
not sure whether they show anything new/different to the messages Benoit
ANDRE showed to us but its quite a bit of effort to compile from svn.

On Linux that's not more than

svn update
make

Since most was compiled before, it will take something like 60sec...

Finally perhaps (not me, I just run GRASS GIS directly from the compiled
source code directory):
make install

Is that output from my side still required??

Does it work for you?

Markus

--
Stefan Lüdtke

Section 5.4- Hydrology
Phone: +49(0)331-288-2821
Fax: +49(0)331-288-1570
Email: sluedtke@gfz-potsdam.de
___________________________________________

Helmholtz Centre Potsdam
GFZ German Research Centre for Geosciences
Foundation under public law of the federal state
of Brandenburg
Telegrafenberg, D-14473 Potsdam

Hi Moritz,

I tried with last release (7.0.5RC2) on my server (where postgresql is running) and not on a remote workstation. Connection to database is then a local connection. Here, there is no problem to work with postgresql. The problem seems thus to be linked with a remote acces…

Benoit

(attachments)

btn_liprofile_blue_80x15_fr_FR.png
bcg_logo.gif
BCG_bas.gif
In-2C-21px-TM.png
icone_fb.gif
Modere_SocialMarketer_logomark.png

···

Le 14/09/16 12:26, Moritz Lennert a écrit :

This really is a serious issue.

Would it be possible for you to provide a reproducible example ? Ideally
starting out from the North Caroline data. Something that creates a new
postgresql database, redefined db.connect to link to that, g.copy a few
maps and then see if the connection problem still happens ?

Ideally this should go into a bug ticket and IMHO it should definitely
be a blocker for the upcoming releases as I would consider this basic
functionality.

Moritz

Le Wed, 14 Sep 2016 11:22:57 +0200,
Benoit ANDRE [<benoit.andre@bcgeol.be>](mailto:benoit.andre@bcgeol.be) a écrit :

Hi list,

Always the same problem with a remote Postgresql connection, with
grass 7.0.4 and above (7.2 and 7.3).  With grass 7.0.0, the
connection to postgresql is perfect.  I don't try with 7.0.1, 7.0.2
and 7.0.3

All my other soft using Postgresql work fine (i.e. pgadmin, odoo, 
caldav, carddav, libreoffice, ...)

The problem is the for all the PC on my network (server under Centos
7, workstations under Fedora 19, 21 or 22)

Le 12/09/16 13:22, Stefan Lüdtke a écrit :

Hi list,

I hope this is not a duplicate, but I could not find any solution
on the web by know.

I trying to connect to a remote postgresql database, without
success.

What I have done:

1)
db.connect driver=pg	       	
database="host=vmhydro27,dbname=cedim_rfra,port=5432"

2)db.login driver=pg database=cedim_rfra user=sluedtke
password=##### host=vmhydro27

3) db.tables -p

DBMI-PostgreSQL driver error:
Connection failed.
could not connect to server: No such file or directory
         Is the server running locally and accepting
         connections on Unix domain socket
"/var/run/postgresql/.s.PGSQL.5432"?
DBMI-PostgreSQL driver error:
Connection failed.
could not connect to server: No such file or directory
         Is the server running locally and accepting
         connections on Unix domain socket
"/var/run/postgresql/.s.PGSQL.5432"?
ERROR: Unable to open database
<host=vmhydro27,dbname=cedim_rfra,port=5432>

I tried all drivers (odbc, ogr, pg) that made sense to me, no
success.

It is no problem to connect QGIS, R and python to this db and
visualize the data.

I am using Kubuntu 16.04 with GRASS 7.04.

[I]  /u/bin  apt-cache show grass

                             Mon 12 Sep 2016 13:20:37 CEST
Package: grass
Status: install ok installed
Priority: optional
Section: metapackages
Installed-Size: 33
Maintainer: Debian GIS Project
[<pkg-grass-devel@lists.alioth.debian.org>](mailto:pkg-grass-devel@lists.alioth.debian.org) Architecture: all
Version: 7.0.4-1~xenial2
Replaces: grass7, grass70
Provides: grass7, grass70
Depends: grass-core, grass-gui
Recommends: grass-doc
Suggests: grass-dev
Conflicts: grass7, grass70
Description: Geographic Resources Analysis Support System (GRASS
GIS) Commonly referred to as GRASS, this is a Geographic Information
  System (GIS) used for geospatial data management and analysis,
  image processing, graphics/map production, spatial modeling, and
  visualization. GRASS is currently used in academic and commercial
  settings around the world, as well as by many government agencies
  and environmental consulting companies.
  .
  Install this virtual package to get a full GRASS system.
Description-md5: 927e5df9adc0c220121824a1dcc21063
Homepage: [http://grass.osgeo.org/](http://grass.osgeo.org/)

I am able to get info of a certain layer using ogrinfo with the
connection string.

Any help is appreciated.

Cheers,

Stefan

_______________________________________________
grass-user mailing list
[grass-user@lists.osgeo.org](mailto:grass-user@lists.osgeo.org)
[http://lists.osgeo.org/mailman/listinfo/grass-user](http://lists.osgeo.org/mailman/listinfo/grass-user)  

Benoit André
Directeur - Gérant

benoit.andre@bcgeol.be
Tel. | +32 475 61 84 94
skype | benoit_andre_bcg
Voir le profil de Benoit André sur LinkedIn

BCG SPRL
Tél. | +32(0)81 58 26 11
Fax | +32(0)81 58 26 12
Chemin de la Foliette, 4 Bte 2
B-5000 - Namur
www.bcgeol.be - plan d’accès

BCG LOGO

Suivez-nous sur Lien LinkedinLien Facebook

Allons plus loin dans le respect de l’environnement : N’utilisons que des produits sans empreinte écologiqueLogo Modere

Hi Benoît and Stefan,

On 26/09/16 14:20, Benoit ANDRE wrote:

Hi Moritz,

I tried with last release (7.0.5RC2) on my server (where postgresql is
running) and not on a remote workstation. Connection to database is
then a local connection. Here, there is no problem to work with
postgresql. The problem seems thus to be linked with a remote acces...

I think I have found the origin of the problem. Please see the discussion in the relevant bug report [1].

Both of you say that you did set usernam and password in db.login. Could you check the contents of .grass7/dblogin ? Are there empty fields before the host entry ?

Moritz

[1] https://trac.osgeo.org/grass/ticket/3167

Benoit

Le 14/09/16 12:26, Moritz Lennert a écrit :

This really is a serious issue.

Would it be possible for you to provide a reproducible example ? Ideally
starting out from the North Caroline data. Something that creates a new
postgresql database, redefined db.connect to link to that, g.copy a few
maps and then see if the connection problem still happens ?

Ideally this should go into a bug ticket and IMHO it should definitely
be a blocker for the upcoming releases as I would consider this basic
functionality.

Moritz

Le Wed, 14 Sep 2016 11:22:57 +0200,
Benoit ANDRE <benoit.andre@bcgeol.be> a écrit :

Hi list,

Always the same problem with a remote Postgresql connection, with
grass 7.0.4 and above (7.2 and 7.3). With grass 7.0.0, the
connection to postgresql is perfect. I don't try with 7.0.1, 7.0.2
and 7.0.3

All my other soft using Postgresql work fine (i.e. pgadmin, odoo,
caldav, carddav, libreoffice, ...)

The problem is the for all the PC on my network (server under Centos
7, workstations under Fedora 19, 21 or 22)

Le 12/09/16 13:22, Stefan Lüdtke a écrit :

Hi list,

I hope this is not a duplicate, but I could not find any solution
on the web by know.

I trying to connect to a remote postgresql database, without
success.

What I have done:

1)
db.connect driver=pg
database="host=vmhydro27,dbname=cedim_rfra,port=5432"

2)db.login driver=pg database=cedim_rfra user=sluedtke
password=##### host=vmhydro27

3) db.tables -p

DBMI-PostgreSQL driver error:
Connection failed.
could not connect to server: No such file or directory
         Is the server running locally and accepting
         connections on Unix domain socket
"/var/run/postgresql/.s.PGSQL.5432"?
DBMI-PostgreSQL driver error:
Connection failed.
could not connect to server: No such file or directory
         Is the server running locally and accepting
         connections on Unix domain socket
"/var/run/postgresql/.s.PGSQL.5432"?
ERROR: Unable to open database
<host=vmhydro27,dbname=cedim_rfra,port=5432>

I tried all drivers (odbc, ogr, pg) that made sense to me, no
success.

It is no problem to connect QGIS, R and python to this db and
visualize the data.

I am using Kubuntu 16.04 with GRASS 7.04.

[I] /u/bin  apt-cache show grass

                             Mon 12 Sep 2016 13:20:37 CEST
Package: grass
Status: install ok installed
Priority: optional
Section: metapackages
Installed-Size: 33
Maintainer: Debian GIS Project
<pkg-grass-devel@lists.alioth.debian.org> Architecture: all
Version: 7.0.4-1~xenial2
Replaces: grass7, grass70
Provides: grass7, grass70
Depends: grass-core, grass-gui
Recommends: grass-doc
Suggests: grass-dev
Conflicts: grass7, grass70
Description: Geographic Resources Analysis Support System (GRASS
GIS) Commonly referred to as GRASS, this is a Geographic Information
  System (GIS) used for geospatial data management and analysis,
  image processing, graphics/map production, spatial modeling, and
  visualization. GRASS is currently used in academic and commercial
  settings around the world, as well as by many government agencies
  and environmental consulting companies.
  .
  Install this virtual package to get a full GRASS system.
Description-md5: 927e5df9adc0c220121824a1dcc21063
Homepage: http://grass.osgeo.org/

I am able to get info of a certain layer using ogrinfo with the
connection string.

Any help is appreciated.

Cheers,

Stefan

_______________________________________________
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user

--

*Benoit André*
*Directeur - Gérant*

benoit.andre@bcgeol.be <mailto:benoit.andre@bcgeol.be>
Tel. | +32 475 61 84 94
skype | benoit_andre_bcg
Voir le profil de Benoit André sur LinkedIn
<https://be.linkedin.com/in/benoitandre&gt;

*BCG SPRL*
Tél. | +32(0)81 58 26 11
Fax | +32(0)81 58 26 12
Chemin de la Foliette, 4 Bte 2
B-5000 - Namur
www.bcgeol.be <http://www.bcgeol.be> - plan d'accès
<https://maps.google.be/maps/ms?msid=210366068780572446312.0004dc0b834462107c00f&msa=0&ll=50.460427,4.856445&spn=0.001279,0.002411&iwloc=0004dc0b8345e35a35a20&gt;

  BCG LOGO <http://www.bcgeol.be>

Suivez-nous sur Lien Linkedin
<https://www.linkedin.com/company/bureau-conseil-en-géologie-sprl&gt; Lien
Facebook
<https://www.facebook.com/Bureau-Conseil-en-Géologie-153924548320189/?ref=hl&gt;

Allons plus loin dans le respect de l'environnement : N'utilisons que
des produits sans empreinte écologiqueLogo Modere
<https://www.modere.eu/?referralCode=050281&gt;

Hi,

if I do not set all parameters with db.login I do have empty fields in
that file, even though I put that parameters in the db.connect command.

If everything is in db.login, I can connect to the db (as reported
earlier) and list tables. However I can neither link nor import them
because they are not listed in the gui box.

Cheers,
Stefan

On 27/09/16 13:11, Moritz Lennert wrote:

Hi Benoît and Stefan,

On 26/09/16 14:20, Benoit ANDRE wrote:

Hi Moritz,

I tried with last release (7.0.5RC2) on my server (where postgresql is
running) and not on a remote workstation. Connection to database is
then a local connection. Here, there is no problem to work with
postgresql. The problem seems thus to be linked with a remote acces...

I think I have found the origin of the problem. Please see the
discussion in the relevant bug report [1].

Both of you say that you did set usernam and password in db.login. Could
you check the contents of .grass7/dblogin ? Are there empty fields
before the host entry ?

Moritz

[1] https://trac.osgeo.org/grass/ticket/3167

Benoit

Le 14/09/16 12:26, Moritz Lennert a écrit :

This really is a serious issue.

Would it be possible for you to provide a reproducible example ? Ideally
starting out from the North Caroline data. Something that creates a new
postgresql database, redefined db.connect to link to that, g.copy a few
maps and then see if the connection problem still happens ?

Ideally this should go into a bug ticket and IMHO it should definitely
be a blocker for the upcoming releases as I would consider this basic
functionality.

Moritz

Le Wed, 14 Sep 2016 11:22:57 +0200,
Benoit ANDRE <benoit.andre@bcgeol.be> a écrit :

Hi list,

Always the same problem with a remote Postgresql connection, with
grass 7.0.4 and above (7.2 and 7.3). With grass 7.0.0, the
connection to postgresql is perfect. I don't try with 7.0.1, 7.0.2
and 7.0.3

All my other soft using Postgresql work fine (i.e. pgadmin, odoo,
caldav, carddav, libreoffice, ...)

The problem is the for all the PC on my network (server under Centos
7, workstations under Fedora 19, 21 or 22)

Le 12/09/16 13:22, Stefan Lüdtke a écrit :

Hi list,

I hope this is not a duplicate, but I could not find any solution
on the web by know.

I trying to connect to a remote postgresql database, without
success.

What I have done:

1)
db.connect driver=pg
database="host=vmhydro27,dbname=cedim_rfra,port=5432"

2)db.login driver=pg database=cedim_rfra user=sluedtke
password=##### host=vmhydro27

3) db.tables -p

DBMI-PostgreSQL driver error:
Connection failed.
could not connect to server: No such file or directory
         Is the server running locally and accepting
         connections on Unix domain socket
"/var/run/postgresql/.s.PGSQL.5432"?
DBMI-PostgreSQL driver error:
Connection failed.
could not connect to server: No such file or directory
         Is the server running locally and accepting
         connections on Unix domain socket
"/var/run/postgresql/.s.PGSQL.5432"?
ERROR: Unable to open database
<host=vmhydro27,dbname=cedim_rfra,port=5432>

I tried all drivers (odbc, ogr, pg) that made sense to me, no
success.

It is no problem to connect QGIS, R and python to this db and
visualize the data.

I am using Kubuntu 16.04 with GRASS 7.04.

[I] /u/bin  apt-cache show grass

                             Mon 12 Sep 2016 13:20:37 CEST
Package: grass
Status: install ok installed
Priority: optional
Section: metapackages
Installed-Size: 33
Maintainer: Debian GIS Project
<pkg-grass-devel@lists.alioth.debian.org> Architecture: all
Version: 7.0.4-1~xenial2
Replaces: grass7, grass70
Provides: grass7, grass70
Depends: grass-core, grass-gui
Recommends: grass-doc
Suggests: grass-dev
Conflicts: grass7, grass70
Description: Geographic Resources Analysis Support System (GRASS
GIS) Commonly referred to as GRASS, this is a Geographic Information
  System (GIS) used for geospatial data management and analysis,
  image processing, graphics/map production, spatial modeling, and
  visualization. GRASS is currently used in academic and commercial
  settings around the world, as well as by many government agencies
  and environmental consulting companies.
  .
  Install this virtual package to get a full GRASS system.
Description-md5: 927e5df9adc0c220121824a1dcc21063
Homepage: http://grass.osgeo.org/

I am able to get info of a certain layer using ogrinfo with the
connection string.

Any help is appreciated.

Cheers,

Stefan

_______________________________________________
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user

--

*Benoit André*
*Directeur - Gérant*

benoit.andre@bcgeol.be <mailto:benoit.andre@bcgeol.be>
Tel. | +32 475 61 84 94
skype | benoit_andre_bcg
Voir le profil de Benoit André sur LinkedIn
<https://be.linkedin.com/in/benoitandre&gt;

*BCG SPRL*
Tél. | +32(0)81 58 26 11
Fax | +32(0)81 58 26 12
Chemin de la Foliette, 4 Bte 2
B-5000 - Namur
www.bcgeol.be <http://www.bcgeol.be> - plan d'accès
<https://maps.google.be/maps/ms?msid=210366068780572446312.0004dc0b834462107c00f&msa=0&ll=50.460427,4.856445&spn=0.001279,0.002411&iwloc=0004dc0b8345e35a35a20&gt;

    BCG LOGO <http://www.bcgeol.be>

Suivez-nous sur Lien Linkedin
<https://www.linkedin.com/company/bureau-conseil-en-géologie-sprl&gt; Lien

Facebook
<https://www.facebook.com/Bureau-Conseil-en-Géologie-153924548320189/?ref=hl&gt;

Allons plus loin dans le respect de l'environnement : N'utilisons que
des produits sans empreinte écologiqueLogo Modere
<https://www.modere.eu/?referralCode=050281&gt;

--
Stefan Lüdtke

Section 5.4- Hydrology
Phone: +49(0)331-288-2821
Fax: +49(0)331-288-1570
Email: sluedtke@gfz-potsdam.de
___________________________________________

Helmholtz Centre Potsdam
GFZ German Research Centre for Geosciences
Foundation under public law of the federal state
of Brandenburg
Telegrafenberg, D-14473 Potsdam

Hi Moritz,

It works fine with your suggestion… Thank you.

First : I erase ./grass7/dblogin (outside grass)
2nd : I go into grass 7.0.4
3th :

  • db.connect driver=pg database=administration
  • db.login driver=pg database=administration user=benoit password=rien host=192.168.1.200 port=5432

No matter if a password is necessary in my case

Then, I had to reconnect map to table with
4th : v.db.connect -o map=survey_bcg@benoit driver=pg database=administration table=public.survey_bcg

The only place where host and port arise is in the ‘db.login’ function.

OK. Now, I’m able to make the jump to grass 7.

Thank you again, Moritz.

Cheers,

Ben.

(attachments)

bcg_logo.gif
BCG_bas.gif
In-2C-21px-TM.png
icone_fb.gif
Modere_SocialMarketer_logomark.png

···

Le 27/09/16 14:52, Stefan Lüdtke a écrit :

Hi,

if I do not set all parameters with db.login I do have empty fields in
that file, even though I put that parameters in the db.connect command.

If everything is in db.login, I can connect to the db (as reported
earlier) and list tables. However I can neither link nor import them
because they are not listed in the gui box.

Cheers,
Stefan

On 27/09/16 13:11, Moritz Lennert wrote:

Hi Benoît and Stefan,

On 26/09/16 14:20, Benoit ANDRE wrote:

Hi Moritz,

I tried with last release (7.0.5RC2) on my server (where postgresql is
running) and not on a remote workstation.  Connection to database is
then a local connection.  Here, there is no problem to work with
postgresql.  The problem seems thus to be linked with a remote acces...

I think I have found the origin of the problem. Please see the
discussion in the relevant bug report [1].

Both of you say that you did set usernam and password in db.login. Could
you check the contents of .grass7/dblogin ? Are there empty fields
before the host entry ?

Moritz

[1] [https://trac.osgeo.org/grass/ticket/3167](https://trac.osgeo.org/grass/ticket/3167)

Benoit

Le 14/09/16 12:26, Moritz Lennert a écrit :

This really is a serious issue.

Would it be possible for you to provide a reproducible example ? Ideally
starting out from the North Caroline data. Something that creates a new
postgresql database, redefined db.connect to link to that, g.copy a few
maps and then see if the connection problem still happens ?

Ideally this should go into a bug ticket and IMHO it should definitely
be a blocker for the upcoming releases as I would consider this basic
functionality.

Moritz

Le Wed, 14 Sep 2016 11:22:57 +0200,
Benoit ANDRE [<benoit.andre@bcgeol.be>](mailto:benoit.andre@bcgeol.be) a écrit :

Hi list,

Always the same problem with a remote Postgresql connection, with
grass 7.0.4 and above (7.2 and 7.3).  With grass 7.0.0, the
connection to postgresql is perfect.  I don't try with 7.0.1, 7.0.2
and 7.0.3

All my other soft using Postgresql work fine (i.e. pgadmin, odoo,
caldav, carddav, libreoffice, ...)

The problem is the for all the PC on my network (server under Centos
7, workstations under Fedora 19, 21 or 22)

Le 12/09/16 13:22, Stefan Lüdtke a écrit :

Hi list,

I hope this is not a duplicate, but I could not find any solution
on the web by know.

I trying to connect to a remote postgresql database, without
success.

What I have done:

1)
db.connect driver=pg              
database="host=vmhydro27,dbname=cedim_rfra,port=5432"

2)db.login driver=pg database=cedim_rfra user=sluedtke
password=##### host=vmhydro27

3) db.tables -p

DBMI-PostgreSQL driver error:
Connection failed.
could not connect to server: No such file or directory
         Is the server running locally and accepting
         connections on Unix domain socket
"/var/run/postgresql/.s.PGSQL.5432"?
DBMI-PostgreSQL driver error:
Connection failed.
could not connect to server: No such file or directory
         Is the server running locally and accepting
         connections on Unix domain socket
"/var/run/postgresql/.s.PGSQL.5432"?
ERROR: Unable to open database
<host=vmhydro27,dbname=cedim_rfra,port=5432>

I tried all drivers (odbc, ogr, pg) that made sense to me, no
success.

It is no problem to connect QGIS, R and python to this db and
visualize the data.

I am using Kubuntu 16.04 with GRASS 7.04.

[I]  /u/bin  apt-cache show grass

                             Mon 12 Sep 2016 13:20:37 CEST
Package: grass
Status: install ok installed
Priority: optional
Section: metapackages
Installed-Size: 33
Maintainer: Debian GIS Project
[<pkg-grass-devel@lists.alioth.debian.org>](mailto:pkg-grass-devel@lists.alioth.debian.org) Architecture: all
Version: 7.0.4-1~xenial2
Replaces: grass7, grass70
Provides: grass7, grass70
Depends: grass-core, grass-gui
Recommends: grass-doc
Suggests: grass-dev
Conflicts: grass7, grass70
Description: Geographic Resources Analysis Support System (GRASS
GIS) Commonly referred to as GRASS, this is a Geographic Information
  System (GIS) used for geospatial data management and analysis,
  image processing, graphics/map production, spatial modeling, and
  visualization. GRASS is currently used in academic and commercial
  settings around the world, as well as by many government agencies
  and environmental consulting companies.
  .
  Install this virtual package to get a full GRASS system.
Description-md5: 927e5df9adc0c220121824a1dcc21063
Homepage: [http://grass.osgeo.org/](http://grass.osgeo.org/)

I am able to get info of a certain layer using ogrinfo with the
connection string.

Any help is appreciated.

Cheers,

Stefan

_______________________________________________
grass-user mailing list
[grass-user@lists.osgeo.org](mailto:grass-user@lists.osgeo.org)
[http://lists.osgeo.org/mailman/listinfo/grass-user](http://lists.osgeo.org/mailman/listinfo/grass-user)

-- 

    

*Benoit André*
*Directeur - Gérant*

[benoit.andre@bcgeol.be](mailto:benoit.andre@bcgeol.be) [<mailto:benoit.andre@bcgeol.be>](mailto:benoit.andre@bcgeol.be)
Tel. | +32 475 61 84 94
skype | benoit_andre_bcg
Voir le profil de Benoit André sur LinkedIn
[<https://be.linkedin.com/in/benoitandre>](https://be.linkedin.com/in/benoitandre)

*BCG SPRL*
Tél. | +32(0)81 58 26 11
Fax | +32(0)81 58 26 12
Chemin de la Foliette, 4 Bte 2
B-5000 - Namur
[www.bcgeol.be](http://www.bcgeol.be) [<http://www.bcgeol.be>](http://www.bcgeol.be)  -  plan d'accès
[<https://maps.google.be/maps/ms?msid=210366068780572446312.0004dc0b834462107c00f&msa=0&ll=50.460427,4.856445&spn=0.001279,0.002411&iwloc=0004dc0b8345e35a35a20>](https://maps.google.be/maps/ms?msid=210366068780572446312.0004dc0b834462107c00f&msa=0&ll=50.460427,4.856445&spn=0.001279,0.002411&iwloc=0004dc0b8345e35a35a20)

    BCG LOGO [<http://www.bcgeol.be>](http://www.bcgeol.be)

Suivez-nous sur  Lien Linkedin
[<https://www.linkedin.com/company/bureau-conseil-en-g%C3%A9ologie-sprl>](https://www.linkedin.com/company/bureau-conseil-en-g%C3%A9ologie-sprl) Lien

Facebook
[<https://www.facebook.com/Bureau-Conseil-en-G%C3%A9ologie-153924548320189/?ref=hl>](https://www.facebook.com/Bureau-Conseil-en-G%C3%A9ologie-153924548320189/?ref=hl)

Allons plus loin dans le respect de l'environnement : N'utilisons que
des produits sans empreinte écologiqueLogo Modere
[<https://www.modere.eu/?referralCode=050281>](https://www.modere.eu/?referralCode=050281)

Benoit André
Directeur - Gérant

benoit.andre@bcgeol.be
Tel. | +32 475 61 84 94
skype | benoit_andre_bcg
Voir le profil de Benoit André sur LinkedIn

BCG SPRL
Tél. | +32(0)81 58 26 11
Fax | +32(0)81 58 26 12
Chemin de la Foliette, 4 Bte 2
B-5000 - Namur
www.bcgeol.be - plan d’accès

BCG LOGO

Suivez-nous sur Lien LinkedinLien Facebook

Allons plus loin dans le respect de l’environnement : N’utilisons que des produits sans empreinte écologiqueLogo Modere