shp2img works fine but mapserv does not.

Frank Warmerdam warmerdam at POBOX.COM
Thu Sep 15 13:43:38 EDT 2005


On 9/15/05, Athanasios Lois <lois at uth.gr> wrote:
> hi there,
> 
> I have a situation where shp2img works with a postgis connection and
> mapserv does not. Postgis support was properly compiled into
> shp2img and the same for  mapserv.
> 
> When a web page is calling mapserver with postgis connection does not show anything, instead it works fine with shp files.
> 
> Program shp2img works fine for the same map file and produces the appropriate image file

T. Lois, 

If you are in a position to rebuild your mapserver I would
suggest you do so, adding the "--enable-debug" switch.  This
will include support for debugging output.  Then add "DEBUG TRUE"
on the layer in question and rerun mapserv.  You may get some 
useful debugging output in your Apache error_log file this way. 

Another useful debugging step is to invoke mapserv at the commandline
with your query to see if it works there. 

eg. 
  mapserv QUERY_STRING="..."

The QUERY_STRING value should be everything in the request
url after the question mark.  If it works for mapserv at the commandline
and not via apache, then the problem is likely related to permissions
or environment between your account and how things run under
apache. 

PS. My first guess was that it related to layer status, but I see
you already have that set to default, so there should be no question
of the layer displaying under mapserv.  You might also want to ensure
that a scale dependency check isn't causing that layer to be skipped 
in mapserv.

Good luck,

-- 
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | Geospatial Programmer for Rent



More information about the mapserver-users mailing list