[postgis-users] Mapserver / PostGIS Layer
Lowther, David W
dlowther at ou.edu
Mon Jan 6 08:07:11 PST 2003
Hi List and Happy New Year!
I have been struggling with a situation related to Mapserver and PostGIS
layers and I was hoping someone might help me out.
I have PostGIS running on Redhat. I have 2 web/mapserver (3.6.3) servers
(Intel WinNT4.0 IIS4.0) that access this PostGIS database. One is a test
server (located in the same domain as the PostGIS server) and one is a live
server (located in a separate domain from the PostGIS server). Using the
same connection information in a mapfile the test server can access and map
the PostGIS database with no problem - as could the live server when it was
in the domain - but the live server fails to connect with an error
(msPOSTGISLayerOpen(): Query error. Error parsing POSTGIS connection
information.) now that it is outside the domain. I am stressing the domain
issue here because I can't think of any other difference in the two servers.
- PGAdmin from the live server connects with no problem.
- ODBC connectivity from the live server works fine.
- The mapfiles on the test and live servers are identical except for
necessary directory differences.
- Checked password, hostname, connection type, socket connections enabled as
instructed in debug version of Mapserver build, but if they work on the test
server shouldn't they work on the live?
- Added live server to pg_hba.conf although test server does not appear and
host all 184.108.40.206 255.255.255.0 trust
- Initialize postmaster with -i option to allow tcp/ip connections.
- tcpip_socket=true in postgresql.conf.
- Tried using port=5432 in the CONNECTION param for mapfile - no difference
Heres the layer from the mapfile:
### ROADS ###
CONNECTION "user=*** password=*** dbname=*** host=***"
DATA "the_geom from (select oid,* from roads) as foo"
PROJECTION #GEOGRAPHIC NAD83
NAME "Grady Roads"
OUTLINECOLOR -1 -1 -1
COLOR 10 200 100
Would anyone be willing to try connecting to the PostGIS server using
Mapserver if I were to provide ip, db, un, and pwd info? I'm just completely
stuck at this point.
Thanks so much for everyone's help getting me to this point and thanks in
advance for all your help with this issue,
GEO Information Systems
University of Oklahoma
dlowther at ou.edu
More information about the postgis-users