[mapserver-users] Error/ false colored image with GetMap

Toma, Charlotte Charlotte.Toma at wiesbaden.de
Fri Feb 26 01:25:44 PST 2021


Hi Jörg, 
nice to hear from you ;)

I'm quite happy, that the mapfile is ok and works on your system - thanks for the test!
The same error occured without the OUTPUTFORMAT-blocks. I installed mapserver with the bundle from gisinternals (extract to "C:\mapserver", run SDKShell.bat as admin, integrate in apache with alias). This is my mapserv-info: 

MapServer version 7.6.2 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=PDF SUPPORTS=PROJ SUPPORTS=GD 
SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=CAIRO SUPPORTS=OPENGL SUPPORTS=ICONV SUPPORTS=FRIBIDI 
SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER
SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUPPORTS=THREADS SUPPORTS=GEOS INPUT=JPEG INPUT=POSTGIS INPUT=SHAPEFILE

My apache-alias: 

Alias /mapserv/ "C:/mapserver/bin/ms/apps/"
<Directory "C:/mapserver/bin/ms/apps/">
	AddHandler cgi-script .cgi .exe
	SetHandler cgi-script
    	Options +ExecCGI
   	Require all granted
</Directory>

If the problem ist the AGG driver or wrong mime-type provided by the apache... how can i fix or test this? Missing dll/ permission or something like this?

Greetings from sunny Darmstadt
Charly

-----Ursprüngliche Nachricht-----
Von: mapserver-users [mailto:mapserver-users-bounces at lists.osgeo.org] Im Auftrag von Jörg Thomsen (WhereGroup)
Gesendet: Freitag, 26. Februar 2021 09:22
An: mapserver-users at lists.osgeo.org
Betreff: Re: [mapserver-users] Error/ false colored image with GetMap

Hi Charly,

it works (debian and ubuntu....) have you tried to switch it off and on again? ;)

http://schulung.foss.academy/cgi-bin/mapserv?map=/data/charly/rheinek.map&SERVICE=WMS&VERSION=1.3.0&REQUEST=GetMap&BBOX=440663,5538120,452197,5543810&CRS=epsg:25832&WIDTH=823&HEIGHT=406&LAYERS=ug_test&STYLES=&FORMAT=image/png&DPI=96&MAP_RESOLUTION=96&FORMAT_OPTIONS=dpi:96

http://schulung.foss.academy/cgi-bin/mapserv?map=/data/charly/rheinek.map&SERVICE=WMS&VERSION=1.3.0&REQUEST=GetMap&BBOX=440663,5538120,452197,5543810&CRS=epsg:25832&WIDTH=823&HEIGHT=406&LAYERS=ug_test&STYLES=&FORMAT=image/jpeg&DPI=96&MAP_RESOLUTION=96&FORMAT_OPTIONS=dpi:96

Two ideas:
what about the OUTPUTFORMAT blocks? Do you need them? perhaps there's a problem with your AGG driver in your installation

my first thought pointed at your apache config, "the
> image can't be displayed cause it contains errors" looks like a wrong
mime-type provided by the apache.
also your jpeg_error.jpg looks more like an display-error.

The console-output (-v) looks O.K.,  you forgot to pipe the output into a file ('> test.png')

How did you install mapserver and webserver? ms4w? gisinternals?

regards from Berlin, Jörg

Am 26.02.21 um 07:15 schrieb Toma, Charlotte:
>  
> 
> Hello,
> 
>  
> 
> I need your help.
> 
> I installed mapserver on windows server and tested the installation 
> successful. The console output from "mapserv -v" looked like it should 
> and my GetCapabilities worked fine. Then I tested the GetMap and 
> GetLegend from my test-WMS and it isn't working correctly. The 
> requests gives me a false coloured picture with jpeg and an error with 
> png "the image can't be displayed cause it contains errors" (or so in 
> german). I never saw something like this and after my research in the 
> internet I still don't know what to do.
> 
>  
> 
> The test with "shp2img -m E:/mapserv_ows/rheinek.map -o test.png 
> -layer_debug ug_test 5" worked fine and I got the corret result as an 
> image (jpeg and png); but only after I added the "SIZE" parameter in 
> my mapfile. Until this I got the error "dimensions not defined / can't 
> be calculated".
> 
>  
> 
> My mapfile is very simple, cause i wanted to test if it works (one 
> shapefile, one polygon, simple red fill and black outline to display).
> In the following cloud folder you can see my mapfile, the weird 
> jpeg-GetMap answer and the error message:
> 
>  
> 
> https://my.hidrive.com/lnk/jrySL9oJ
> 
>  
> 
> Greetings
> 
> Charly
> 
> Mit freundlichen Grüßen
> im Auftrag
> 
> Charlotte Toma
> 
> Landeshauptstadt Wiesbaden
> -Der Magistrat-
> 
> Stadtplanungsamt
> -610230-
> Gustav-Stresemann-Ring 15
> 65189 Wiesbaden
> Tel.: 0611 31-3436
> Fax: 0611 31-3917
> E-Mail: 61GIS at wiesbaden.de <mailto:61GIS at wiesbaden.de>
> Internet: www.wiesbaden.de <http://www.wiesbaden.de/>
> 
> Jede nicht gedruckte Seite spart Holz, Wasser und Strom.
> 
>  
> 
> 
> _______________________________________________
> mapserver-users mailing list
> mapserver-users at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/mapserver-users
> 


Viele Grüße,
Jörg Thomsen

--
---------------------------------------------
Einladung zum
Mapbender Anwendertreffen
online am 25.03.2021
https://mapbender.org
---------------------------------------------

Jörg Thomsen
WhereGroup GmbH
Bundesallee 23
10717 Berlin
Germany

Fon: +49 (0)30 / 5130 278 74
Fax: +49 (0)30 / 5130 278 11	

joerg.thomsen at wheregroup.com
www.wheregroup.com

Geschäftsführer:
Olaf Knopp, Peter Stamm
Amtsgericht Bonn, HRB 9885

-------------------------------
Folgen Sie der WhereGroup auf twitter: http://twitter.com/WhereGroup_com _______________________________________________
mapserver-users mailing list
mapserver-users at lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users



More information about the MapServer-users mailing list