[Mapserver-users] Re: More info on strange mapserv - mode=map behavior

Davis Michael A DPW GIS TECH michael.davis at richardson.army.mil
Tue Jul 13 16:49:15 PDT 2004


This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.

------_=_NextPart_001_01C46934.014261C0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

They all produce bad images, I have tried JPEG, PNG, as well as GIF and =
all
come out malformed.  When doing a browser/cgi request the JPEG option
returns an IE "the page cannot be displayed" error, the other two =
return the
"CGI error".  All three are successful in "browse" mode.

Mike Davis
GIS Analyst
Fort Richardson, AK


-----Original Message-----
From: Paul Ramsey [mailto:pramsey at refractions.net]=20
Sent: Tuesday, July 13, 2004 3:30 PM
To: Davis Michael A DPW GIS TECH
Subject: Re: [Mapserver-users] Re: More info on strange mapserv - =
mode=3Dmap
behavior

If you change your output format to PNG or JPEG, does the behavior =
differ?

Davis Michael A DPW GIS TECH wrote:

> Unfortunately issuing a browser request for=20
>
"http://rpw-edms/scripts/mapserv.exe?map=3D//rpw-edms/crrel/usartrak/tes=
t.map&
mode=3Dmap=20
>
<http://rpw-edms/scripts/mapserv.exe?map=3D//rpw-edms/crrel/usartrak/tes=
t.map&
mode=3Dmap>"
>=20
> Returns the dreaded
>=20
> "CGI Error
>=20
> The specified CGI application misbehaved by not returning a complete =
set=20
> of HTTP headers. The headers it did return are:
>=20
>=20
> GIF87a=90=01X=02""
>=20
> So it looks like the image is not being built correctly.
>=20
>=20
> Mike Davis
> GIS Analyst
> Fort Richardson, AK
>=20
>=20
> -----Original Message-----
> From: Paul Ramsey [mailto:pramsey at refractions.net]
> Sent: Tuesday, July 13, 2004 3:18 PM
> To: Davis Michael A DPW GIS TECH
> Cc: Ryan, Adam
> Subject: Re: [Mapserver-users] Re: More info on strange mapserv -=20
> mode=3Dmap behavior
>=20
> Do you get the same results from hitting the mapserv.exe with a =
browser
> via cgi? It really looks like the program is terminating early, =
leaving
> the image partially written. Hence the funny interlaced look, and the
> majority of programs interpretting it as corrupt. That could be cause =
by
> a bad implementation of the > operator in Windows, so hitting it via
> CGI/browser might make things work better? (guessing, guessing...)
>=20
> Paul
>=20
>=20
>=20
> Davis Michael A DPW GIS TECH wrote:
>=20
>  > Sure, in the mapserv.exe directory I ran the following commands:
>  >
>  > set "REQUEST_METHOD=3DGET"
>  > set =
"QUERY_STRING=3Dmap=3D//rpw-edms/crrel/usartrak/test.map&mode=3Dmap"
>  > mapserv.exe > c:\inetpub\scripts\test.gif
>  >
>  > This produced the image I sent out.
>  >
>  > -btw tried again with interlace set to OFF in the map file, still
failed
>  > but the resulting image looked a little different. (attached)
>  >
>  > My relationship with the all powerful Essree has also been =
somewhat
>  > love-hate lately.  Our web mapping tools are some of the last =
remaining
>  > non-esri technologies we use, unfortunately.
>  >
>  > Mike Davis
>  > GIS Analyst
>  > Fort Richardson, AK
>  >
>  >
>  > -----Original Message-----
>  > From: Ryan, Adam [mailto:ARyan at co.linn.or.us]
>  > Sent: Tuesday, July 13, 2004 2:48 PM
>  > To: Davis Michael A DPW GIS TECH
>  > Cc: mapserver-users at lists.gis.umn.edu
>  > Subject: RE: [Mapserver-users] Re: More info on strange mapserv -
>  > mode=3Dmap behavior
>  >
>  >
>  > Hey, saw my name and I figured I'd give it another shot, =
especially=20
> with my
>  > long-standing love-hate relationship with E.S.R.I.
>  >
>  > Can you send us your command line request?
>  >
>  > Adam
>  >=20
>  > -----Original Message-----
>  > From: Davis Michael A DPW GIS TECH
>  > [mailto:michael.davis at richardson.army.mil]
>  > Sent: Tuesday, July 13, 2004 2:59 PM
>  > To: mapserver-users at lists.gis.umn.edu
>  > Subject: [Mapserver-users] Re: More info on strange mapserv - =
mode=3Dmap
>  > behavior
>  >
>  >
>  > Pardon my reply to my own post, but I am starting to run out of =
ideas.
>  > I generated a test image (attached) from a map file containing two =

> layers
>  > using the command line.
>  > It is viewable in Internet Explorer but all my other image =
software=20
> reports
>  > an error when opening it.  Has anyone had issues with the .dll's=20
> included
>  > with the 4.2 binary?  I am pretty confidant they aren't the =
problem,=20
> but at
>  > this point I am grasping at straws.
>  > Any and all assistance is greatly appreciated, unfortunately this =
is a
>  > make-or-break project for Mapserver within the U.S. Army Alaska.  =
If I
>  > can't
>  > resolve my issues, it will be a big the foot-in-the-door for the =
ArcIMS
>  > camp.   =20
>  > Mike Davis
>  > GIS Analyst
>  > Fort Richardson, AK
>  >  >>Thanks to some great assistance from Adam Ryan, of Linn County, =
I=20
> have
>  >  >>been able to narrow down my issues with the mapserv cgi on
>  > Win2k+IIS.  We
>  >  >>are using the latest 4.2 build.
>  >  >>
>  >  >>Our problem has been occurring when we send a request in "map" =
mode.

>  > The
>  >  >>request will fail with a "CGI Error...CGI application =
misbehaved"
>  > error if
>  >  >>there is more than one layer set to default or requested =
through the
>  > URL.
>  >  >>The request will also fail if there is one layer with multiple
>  > classes set
>  >  >>to default.
>  >  >>
>  >  >>All of the test .map files will work just fine in "browse" =
mode.
>  >  >>
>  >  >>I am wondering if anyone in list land has had a similar =
experience,
>  > or if
>  >  >>anyone who uses Win2k+IIS can recommend web server settings to =
check
>  > or a
>  >  >>way to get more debug information out of the mapserv cgi.  The=20
> standard
>  >  >>log file reports the bad requests as normal execution.
>  >  >>
>  >  >>Thanks very much for all your continued help.
>  >  >>
>  >  >>Mike Davis
>  >  >>GIS Analyst
>  >  >>Fort Richardson, AK
>  >=20
>  >
>  >=20
>  >
>  >
------------------------------------------------------------------------=

>  >
>=20

------_=_NextPart_001_01C46934.014261C0
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3Diso-8859-1">
<META NAME=3D"Generator" CONTENT=3D"MS Exchange Server version =
5.5.2653.12">
<TITLE>RE: [Mapserver-users] Re: More info on strange mapserv - =
mode=3Dmap behavior</TITLE>
</HEAD>
<BODY>

<P><FONT SIZE=3D2>They all produce bad images, I have tried JPEG, PNG, =
as well as GIF and all come out malformed.  When doing a =
browser/cgi request the JPEG option returns an IE "the page cannot =
be displayed" error, the other two return the "CGI =
error".  All three are successful in "browse" =
mode.</FONT></P>

<P><FONT SIZE=3D2>Mike Davis</FONT>
<BR><FONT SIZE=3D2>GIS Analyst</FONT>
<BR><FONT SIZE=3D2>Fort Richardson, AK</FONT>
</P>
<BR>

<P><FONT SIZE=3D2>-----Original Message-----</FONT>
<BR><FONT SIZE=3D2>From: Paul Ramsey [<A =
HREF=3D"mailto:pramsey at refractions.net">mailto:pramsey at refractions.net</=
A>] </FONT>
<BR><FONT SIZE=3D2>Sent: Tuesday, July 13, 2004 3:30 PM</FONT>
<BR><FONT SIZE=3D2>To: Davis Michael A DPW GIS TECH</FONT>
<BR><FONT SIZE=3D2>Subject: Re: [Mapserver-users] Re: More info on =
strange mapserv - mode=3Dmap behavior</FONT>
</P>

<P><FONT SIZE=3D2>If you change your output format to PNG or JPEG, does =
the behavior differ?</FONT>
</P>

<P><FONT SIZE=3D2>Davis Michael A DPW GIS TECH wrote:</FONT>
</P>

<P><FONT SIZE=3D2>> Unfortunately issuing a browser request for =
</FONT>
<BR><FONT SIZE=3D2>> "<A =
HREF=3D"http://rpw-edms/scripts/mapserv.exe?map=3D//rpw-edms/crrel/usart=
rak/test.map&mode=3Dmap" =
TARGET=3D"_blank">http://rpw-edms/scripts/mapserv.exe?map=3D//rpw-edms/c=
rrel/usartrak/test.map&mode=3Dmap</A> </FONT>
<BR><FONT SIZE=3D2>> <<A =
HREF=3D"http://rpw-edms/scripts/mapserv.exe?map=3D//rpw-edms/crrel/usart=
rak/test.map&mode=3Dmap" =
TARGET=3D"_blank">http://rpw-edms/scripts/mapserv.exe?map=3D//rpw-edms/c=
rrel/usartrak/test.map&mode=3Dmap</A>>"</FONT>
<BR><FONT SIZE=3D2>> </FONT>
<BR><FONT SIZE=3D2>> Returns the dreaded</FONT>
<BR><FONT SIZE=3D2>> </FONT>
<BR><FONT SIZE=3D2>> "CGI Error</FONT>
<BR><FONT SIZE=3D2>> </FONT>
<BR><FONT SIZE=3D2>> The specified CGI application misbehaved by not =
returning a complete set </FONT>
<BR><FONT SIZE=3D2>> of HTTP headers. The headers it did return =
are:</FONT>
<BR><FONT SIZE=3D2>> </FONT>
<BR><FONT SIZE=3D2>> </FONT>
<BR><FONT SIZE=3D2>> GIF87a=90=01X=02""</FONT>
<BR><FONT SIZE=3D2>> </FONT>
<BR><FONT SIZE=3D2>> So it looks like the image is not being built =
correctly.</FONT>
<BR><FONT SIZE=3D2>> </FONT>
<BR><FONT SIZE=3D2>> </FONT>
<BR><FONT SIZE=3D2>> Mike Davis</FONT>
<BR><FONT SIZE=3D2>> GIS Analyst</FONT>
<BR><FONT SIZE=3D2>> Fort Richardson, AK</FONT>
<BR><FONT SIZE=3D2>> </FONT>
<BR><FONT SIZE=3D2>> </FONT>
<BR><FONT SIZE=3D2>> -----Original Message-----</FONT>
<BR><FONT SIZE=3D2>> From: Paul Ramsey [<A =
HREF=3D"mailto:pramsey at refractions.net">mailto:pramsey at refractions.net</=
A>]</FONT>
<BR><FONT SIZE=3D2>> Sent: Tuesday, July 13, 2004 3:18 PM</FONT>
<BR><FONT SIZE=3D2>> To: Davis Michael A DPW GIS TECH</FONT>
<BR><FONT SIZE=3D2>> Cc: Ryan, Adam</FONT>
<BR><FONT SIZE=3D2>> Subject: Re: [Mapserver-users] Re: More info on =
strange mapserv - </FONT>
<BR><FONT SIZE=3D2>> mode=3Dmap behavior</FONT>
<BR><FONT SIZE=3D2>> </FONT>
<BR><FONT SIZE=3D2>> Do you get the same results from hitting the =
mapserv.exe with a browser</FONT>
<BR><FONT SIZE=3D2>> via cgi? It really looks like the program is =
terminating early, leaving</FONT>
<BR><FONT SIZE=3D2>> the image partially written. Hence the funny =
interlaced look, and the</FONT>
<BR><FONT SIZE=3D2>> majority of programs interpretting it as =
corrupt. That could be cause by</FONT>
<BR><FONT SIZE=3D2>> a bad implementation of the > operator in =
Windows, so hitting it via</FONT>
<BR><FONT SIZE=3D2>> CGI/browser might make things work better? =
(guessing, guessing...)</FONT>
<BR><FONT SIZE=3D2>> </FONT>
<BR><FONT SIZE=3D2>> Paul</FONT>
<BR><FONT SIZE=3D2>> </FONT>
<BR><FONT SIZE=3D2>> </FONT>
<BR><FONT SIZE=3D2>> </FONT>
<BR><FONT SIZE=3D2>> Davis Michael A DPW GIS TECH wrote:</FONT>
<BR><FONT SIZE=3D2>> </FONT>
<BR><FONT SIZE=3D2>>  > Sure, in the mapserv.exe directory I =
ran the following commands:</FONT>
<BR><FONT SIZE=3D2>>  ></FONT>
<BR><FONT SIZE=3D2>>  > set =
"REQUEST_METHOD=3DGET"</FONT>
<BR><FONT SIZE=3D2>>  > set =
"QUERY_STRING=3Dmap=3D//rpw-edms/crrel/usartrak/test.map&mode=3D=
map"</FONT>
<BR><FONT SIZE=3D2>>  > mapserv.exe > =
c:\inetpub\scripts\test.gif</FONT>
<BR><FONT SIZE=3D2>>  ></FONT>
<BR><FONT SIZE=3D2>>  > This produced the image I sent =
out.</FONT>
<BR><FONT SIZE=3D2>>  ></FONT>
<BR><FONT SIZE=3D2>>  > -btw tried again with interlace set =
to OFF in the map file, still failed</FONT>
<BR><FONT SIZE=3D2>>  > but the resulting image looked a =
little different. (attached)</FONT>
<BR><FONT SIZE=3D2>>  ></FONT>
<BR><FONT SIZE=3D2>>  > My relationship with the all =
powerful Essree has also been somewhat</FONT>
<BR><FONT SIZE=3D2>>  > love-hate lately.  Our web =
mapping tools are some of the last remaining</FONT>
<BR><FONT SIZE=3D2>>  > non-esri technologies we use, =
unfortunately.</FONT>
<BR><FONT SIZE=3D2>>  ></FONT>
<BR><FONT SIZE=3D2>>  > Mike Davis</FONT>
<BR><FONT SIZE=3D2>>  > GIS Analyst</FONT>
<BR><FONT SIZE=3D2>>  > Fort Richardson, AK</FONT>
<BR><FONT SIZE=3D2>>  ></FONT>
<BR><FONT SIZE=3D2>>  ></FONT>
<BR><FONT SIZE=3D2>>  > -----Original Message-----</FONT>
<BR><FONT SIZE=3D2>>  > From: Ryan, Adam [<A =
HREF=3D"mailto:ARyan at co.linn.or.us">mailto:ARyan at co.linn.or.us</A>]</FON=
T>
<BR><FONT SIZE=3D2>>  > Sent: Tuesday, July 13, 2004 2:48 =
PM</FONT>
<BR><FONT SIZE=3D2>>  > To: Davis Michael A DPW GIS =
TECH</FONT>
<BR><FONT SIZE=3D2>>  > Cc: =
mapserver-users at lists.gis.umn.edu</FONT>
<BR><FONT SIZE=3D2>>  > Subject: RE: [Mapserver-users] Re: =
More info on strange mapserv -</FONT>
<BR><FONT SIZE=3D2>>  > mode=3Dmap behavior</FONT>
<BR><FONT SIZE=3D2>>  ></FONT>
<BR><FONT SIZE=3D2>>  ></FONT>
<BR><FONT SIZE=3D2>>  > Hey, saw my name and I figured I'd =
give it another shot, especially </FONT>
<BR><FONT SIZE=3D2>> with my</FONT>
<BR><FONT SIZE=3D2>>  > long-standing love-hate relationship =
with E.S.R.I.</FONT>
<BR><FONT SIZE=3D2>>  ></FONT>
<BR><FONT SIZE=3D2>>  > Can you send us your command line =
request?</FONT>
<BR><FONT SIZE=3D2>>  ></FONT>
<BR><FONT SIZE=3D2>>  > Adam</FONT>
<BR><FONT SIZE=3D2>>  > </FONT>
<BR><FONT SIZE=3D2>>  > -----Original Message-----</FONT>
<BR><FONT SIZE=3D2>>  > From: Davis Michael A DPW GIS =
TECH</FONT>
<BR><FONT SIZE=3D2>>  > [<A =
HREF=3D"mailto:michael.davis at richardson.army.mil">mailto:michael.davis at r=
ichardson.army.mil</A>]</FONT>
<BR><FONT SIZE=3D2>>  > Sent: Tuesday, July 13, 2004 2:59 =
PM</FONT>
<BR><FONT SIZE=3D2>>  > To: =
mapserver-users at lists.gis.umn.edu</FONT>
<BR><FONT SIZE=3D2>>  > Subject: [Mapserver-users] Re: More =
info on strange mapserv - mode=3Dmap</FONT>
<BR><FONT SIZE=3D2>>  > behavior</FONT>
<BR><FONT SIZE=3D2>>  ></FONT>
<BR><FONT SIZE=3D2>>  ></FONT>
<BR><FONT SIZE=3D2>>  > Pardon my reply to my own post, but =
I am starting to run out of ideas.</FONT>
<BR><FONT SIZE=3D2>>  > I generated a test image (attached) =
from a map file containing two </FONT>
<BR><FONT SIZE=3D2>> layers</FONT>
<BR><FONT SIZE=3D2>>  > using the command line.</FONT>
<BR><FONT SIZE=3D2>>  > It is viewable in Internet Explorer =
but all my other image software </FONT>
<BR><FONT SIZE=3D2>> reports</FONT>
<BR><FONT SIZE=3D2>>  > an error when opening it.  Has =
anyone had issues with the .dll's </FONT>
<BR><FONT SIZE=3D2>> included</FONT>
<BR><FONT SIZE=3D2>>  > with the 4.2 binary?  I am =
pretty confidant they aren't the problem, </FONT>
<BR><FONT SIZE=3D2>> but at</FONT>
<BR><FONT SIZE=3D2>>  > this point I am grasping at =
straws.</FONT>
<BR><FONT SIZE=3D2>>  > Any and all assistance is greatly =
appreciated, unfortunately this is a</FONT>
<BR><FONT SIZE=3D2>>  > make-or-break project for Mapserver =
within the U.S. Army Alaska.  If I</FONT>
<BR><FONT SIZE=3D2>>  > can't</FONT>
<BR><FONT SIZE=3D2>>  > resolve my issues, it will be a big =
the foot-in-the-door for the ArcIMS</FONT>
<BR><FONT SIZE=3D2>>  > camp.    </FONT>
<BR><FONT SIZE=3D2>>  > Mike Davis</FONT>
<BR><FONT SIZE=3D2>>  > GIS Analyst</FONT>
<BR><FONT SIZE=3D2>>  > Fort Richardson, AK</FONT>
<BR><FONT SIZE=3D2>>  >  >>Thanks to some great =
assistance from Adam Ryan, of Linn County, I </FONT>
<BR><FONT SIZE=3D2>> have</FONT>
<BR><FONT SIZE=3D2>>  >  >>been able to narrow =
down my issues with the mapserv cgi on</FONT>
<BR><FONT SIZE=3D2>>  > Win2k+IIS.  We</FONT>
<BR><FONT SIZE=3D2>>  >  >>are using the latest =
4.2 build.</FONT>
<BR><FONT SIZE=3D2>>  >  >></FONT>
<BR><FONT SIZE=3D2>>  >  >>Our problem has been =
occurring when we send a request in "map" mode. </FONT>
<BR><FONT SIZE=3D2>>  > The</FONT>
<BR><FONT SIZE=3D2>>  >  >>request will fail with =
a "CGI Error...CGI application misbehaved"</FONT>
<BR><FONT SIZE=3D2>>  > error if</FONT>
<BR><FONT SIZE=3D2>>  >  >>there is more than one =
layer set to default or requested through the</FONT>
<BR><FONT SIZE=3D2>>  > URL.</FONT>
<BR><FONT SIZE=3D2>>  >  >>The request will also =
fail if there is one layer with multiple</FONT>
<BR><FONT SIZE=3D2>>  > classes set</FONT>
<BR><FONT SIZE=3D2>>  >  >>to default.</FONT>
<BR><FONT SIZE=3D2>>  >  >></FONT>
<BR><FONT SIZE=3D2>>  >  >>All of the test .map =
files will work just fine in "browse" mode.</FONT>
<BR><FONT SIZE=3D2>>  >  >></FONT>
<BR><FONT SIZE=3D2>>  >  >>I am wondering if =
anyone in list land has had a similar experience,</FONT>
<BR><FONT SIZE=3D2>>  > or if</FONT>
<BR><FONT SIZE=3D2>>  >  >>anyone who uses =
Win2k+IIS can recommend web server settings to check</FONT>
<BR><FONT SIZE=3D2>>  > or a</FONT>
<BR><FONT SIZE=3D2>>  >  >>way to get more debug =
information out of the mapserv cgi.  The </FONT>
<BR><FONT SIZE=3D2>> standard</FONT>
<BR><FONT SIZE=3D2>>  >  >>log file reports the =
bad requests as normal execution.</FONT>
<BR><FONT SIZE=3D2>>  >  >></FONT>
<BR><FONT SIZE=3D2>>  >  >>Thanks very much for =
all your continued help.</FONT>
<BR><FONT SIZE=3D2>>  >  >></FONT>
<BR><FONT SIZE=3D2>>  >  >>Mike Davis</FONT>
<BR><FONT SIZE=3D2>>  >  >>GIS Analyst</FONT>
<BR><FONT SIZE=3D2>>  >  >>Fort Richardson, =
AK</FONT>
<BR><FONT SIZE=3D2>>  > </FONT>
<BR><FONT SIZE=3D2>>  ></FONT>
<BR><FONT SIZE=3D2>>  > </FONT>
<BR><FONT SIZE=3D2>>  ></FONT>
<BR><FONT SIZE=3D2>>  > =
------------------------------------------------------------------------=
</FONT>
<BR><FONT SIZE=3D2>>  ></FONT>
<BR><FONT SIZE=3D2>> </FONT>
</P>

</BODY>
</HTML>
------_=_NextPart_001_01C46934.014261C0--




More information about the MapServer-users mailing list