[plug] Perl cgi scripts

Anne Busby anne at clearsol.iinet.net.au
Wed May 2 18:54:58 WST 2001


Some details.

Postgres Version: PostgreSQL 6.5.3 on i686-pc-linux-gnu, compiled by gcc 
egcs-2.91.66
( all software from the RedHat 6.2 CD )

Error Message from apache error_log:
[Wed May  2 18:51:44 2001] [error] (26)Text file busy: exec of 
/home/project/anne/project/kbs_list.cgi failed
[Wed May  2 18:51:46 2001] [error] [client 192.168.1.32] Premature end of 
script headers: /home/project/anne/project/kbs_list.cgi

Print Line:	print 'dddd';

Script:

Interface to the database:	use Pg;

I added the 'print line' under the '#! /usr/bin/perl -w' line at the top of 
the script, saved the script - reloaded it and it ran. Removed the print 
line and it still runs. For a change all the other scripts that get called 
after the first script worked OK.

I hope this helps you. Also, if any one sees something that I am not doing 
right or a better way of writing these scripts, let me know. This is the 
first perl programmming and the first cgi programming I have ever done.

Thanks,
Anne Busby


On Wednesday, May 02, 2001 10:27 AM, Ryan [SMTP:ryan at slowest.net] wrote:
> How don't they run?  What errors if any? - in the apache error logs.
> What do you print when you add in the print line?
> Can we see the scripts?
> What version of Postgres?
> What are you using to interface with the database? - libpgperl? (it sits
> as: use Pg;)
>
> Ryan
>
> At 02:40 PM 5/2/01 +1000, you wrote:
>
> >I have written some perl cgi scripts that create web
> >pages using data retrieved from a postgres database.
> >
> >My problem is that each time I boot the box, with
> >these scripts, the scripts don't run until I have
> >modified them by adding a simple print statement,
> >which I can remove after I have run the script once.
> >
> >The scripts then work until the box is next booted.
> >
> >Any Ideas ??
> >
> >Anne Busby
>
>
> 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: kbs_list.cgi
Type: application/octet-stream
Size: 2276 bytes
Desc: not available
URL: <http://lists.plug.org.au/pipermail/plug/attachments/20010502/c0277989/attachment.obj>


More information about the plug mailing list