[mapserver-users] Couldn't run perl mapscript under Apache
krung
krung at cad.go.th
Sat Nov 9 09:09:08 PST 2002
Hi Lowell, Puneet
I tried as you told me. If I ran with command line, mapserver.log was created whem error occured. But when run on Apache, mapserver's never created as error occured. (access right with this directory'd set to 777 already) So I checked it at error_log of httpd log file, but it's non-sense to me. It showed only "Premature of script headers: /usr/mapserver/testmap.pl".
And I tried to change script logic flow as you, Puneet, told me. It's the same error as before (Internal Server Error).
Do I have to specially configure when I create mapserver program? Any comments, help, advice would be graceful.
Thank you
Krung
---------- Original Message ----------------------------------
From: "Lowell Filak"<lfilak at medinaco.org>
Date: Thu, 07 Nov 2002 08:24:06 -0500
>You can try adding the line noted below and see if a file mapserver.log exists in the current directory and if it reports an error.
>If the mapserver.log file isn't created then try changing the path of the log file to somewhere writeable by the apache process.
>HTH
>Lowell F.
>
>The following message was sent by "Krung Saengpole" <krung at cad.go.th> on Thu, 7 Nov 2002 18:45:20 +0700.
>
>> Hello all,
>>
>> I had trouble getting perl mapscript run on Apache 1.3.26 under RH 7.2. Mapscript compiled from mapserver 3.6.3.
>>
>> My script is:
>>
>> #!/usr/bin/perl
>> use mapscript;
>> use CGI qw/:standard/;
>
>$ENV{MS_ERRORFILE} = "mapserver.log"; <--Try adding this line.
>
>>
>> print header();
>> print start_html();
>> $map = new mapObj('mapfile.map');
>> $img = $map->draw(); # <---- error took place here
>> $img->saveImage('file.png', $mapscript::MS_PNG,1,1,0);
>> ....
>> ....
>>
>> What I did wrong with this script or anything else? But I could run this script at command line. I'm very new to Linux. I tried to write a script that open database and run under Apache, it had no problem. So, I thought it should not be wrong with Apache configuration.
>>
>> Thank you in advance.
>> Krung.
>
>
>
More information about the MapServer-users
mailing list