[mapserver-users] Perl Mapscript issue

Puneet Kishor pkishor at GeoAnalytics.com
Tue Sep 10 22:46:52 EDT 2002


On Tuesday, September 10, 2002, at 08:33  PM, Brian Tomaszewski wrote:

> 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?

likely not. Most likely your mapscript is simply not producing correct 
headers or a complete html file. Why don't you start with a simple 
page... just pop in the commands for starting and ending the html and 
start by adding a few basic mapscript commands (comment out the rest). 
Take it step by step and see if there is any specific command that is 
choking.

Also, make sure your directory where you are writing temporary images is 
writeable by your webserver.

pk/


>
> 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
>>
--
Puneet Kishor
pkishor at eidesis.org




More information about the mapserver-users mailing list