problem with postgis
Juan Baron
jbarong at HOTMAIL.COM
Sat Oct 15 10:09:33 PDT 2005
Hello list,
I am using mapserver 4.4.1 and postgresql 8.0 with postgis.
I have a layer in the map file:
LAYER
CONNECTIONTYPE postgis
NAME callejero
CONNECTION "user=postgres dbname=pruebapostgis host=localhost
port=5432"
DATA "the_geom from tablacallejero"
STATUS DEFAULT
TYPE LINE
CLASS
COLOR 255 0 0
END
END
and when I execute the application, the layer doesn't appear me and the
result is a message for screen:
msDrawMap(): Image handling error. Failed to draw layer named 'callejero'.
msPOSTGISLayerOpen(): Query error. couldnt make connection to DB with
connect string 'user=postgres dbname=pruebapostgis host=localhost
port=5432'.
Error reported was 'could not translate host name "localhost" to address:
Unknown host '.
This error occured when trying to make a connection to the specified
postgresql server.
Most commonly this is caused by
(1) incorrect connection string
(2) you didnt specify a 'user=...' in your connection string
(3) the postmaster (postgresql server) isnt running
(4) you are not allowing TCP/IP connection to the postmaster
(5) your postmaster is not running on the correct port - if its not on
5432 you must specify a 'port=...'
(6) the security on your system does not allow the webserver (usually
user 'nobody') to make socket connections to the postmaster
(7) you forgot to specify a 'host=...' if the postmaster is on a different
machine
(8) you made a typo
I have proven to change localhost for 127.0.0.1, but the result is the
same one.
postgresql this being executed, because if I put netstat - na appears:
TCP 127.0.0.1:5432 LISTENING
I don't know which is the problem.
Thank's
More information about the MapServer-users
mailing list