[mapserver-users] Perl Mapscript issue (was: Tried to send messageto thelist..)

Lowell Filak lfilak at medinaco.org
Wed Sep 11 08:44:10 EDT 2002


There is no problem using raster layers. The png error that popped up in the log file indicated that there was a png file used as a layer and that libpng could not successfully read it.
Please put this line right after the 'use mapscript;' line in your script:
$ENV{MS_ERRORFILE} = "../html/tmp/mapserver.log";
Please change the path '../html/tmp/mapserver.log' to the same as your IMAGEPATH and then run the script. After it chokes 'cat ../html/tmp/mapserver.log' and you should see where/why it stopped.
HTH
Lowell F.

> The following message was sent by "Brian Tomaszewski" <btski at rochester.rr.com> on Tue, 10 Sep 2002 21:33:38 -0400.
> 
> > Thank you for the reply Lowel
> > 
> > I modfied the map file and took out RASTER and postGIS references, and now
> > the error is just
> > 
> > [Tue Sep 10 21:45:56 2002] [error] [client 192.168.1.1] Premature end of
> > script headers: /usr/local/apache/cgi-bin/ms.cgi
> > 
> > Questions:
> > 
> > I am learning PERL as I learn mapscript, so could there be something with my
> > PERL installation?
> > 
> > In general, can you not use raster layers with mapscript ?
> > 
> > Any more ideas on things to look for?
> > 
> > Thank you
> > 
> > Brian
> > 
> > -----Original Message-----
> > From: owner-mapserver-users at lists.gis.umn.edu
> > [mailto:owner-mapserver-users at lists.gis.umn.edu]On Behalf Of Lowell
> > Filak
> > Sent: Tuesday, September 10, 2002 5:12 PM
> > To: mapserver-users at lists.gis.umn.edu; btski at rochester.rr.com
> > Subject: Re: [mapserver-users] Perl Mapscript issue (was: Tried to send
> > messageto thelist..)
> > 
> > 
> > Do you have RASTER layers in your mapfile? If you comment that layer(s) out
> > does the cgi work?
> > Lowell F.
> > 
> > 
> > > I tried to send a message to the MS list, but it didn't seem to go
> > through..
> > > However, nothing was sent back to me (wrong email).
> > >
> > > Here is my message:
> > >
> > > *********************************************************************
> > >
> > > Hi List
> > >
> > > I am trying to run a very basic mapscript cgi. Here is the code:
> > >
> > > #!/usr/local/bin/perl
> > >
> > > use mapscript;
> > >
> > > my $map = new mapObj('/usr/local/apache/htdocs/liv_ms/liv.map') or
> > > die('Unable to open mapfile');
> > > my $image = $map->draw() or die('Unable to draw map');
> > >
> > >
> > > When I  try to run, I get a 500 Internal server error in my browser and
> > the
> > > following is in the apache error log:
> > >
> > > [Mon Sep  9 21:25:25 2002] [error] [client 192.168.1.1] Premature end of
> > > script headers: /usr/local/apache/cgi-bin/ms.cgi
> > > libpng warning: Incomplete compressed datastream in iCCP chunk
> > >
> > > I have already checked:
> > >
> > > -perl is in /usr/local/bin/
> > > -there is a map file at the location
> > >
> > > Any help or ideas would be appreciated
> > >
> > > Thank you in advance
> > >
> > > Brian Tomaszewski




More information about the mapserver-users mailing list