httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From paul POULAIN <paul.poul...@free.fr>
Subject Re: [users@httpd] strange things in errorlog, (apache 2.0, Perl CGI)
Date Tue, 06 May 2003 16:05:47 GMT
Boyle Owen wrote:

Thanks for your answer, but this does not help me...

>>[Fri May 02 17:04:40 2003] [error] [client 127.0.0.1] Premature end of 
>>script headers: search.pl, referer: 
>>http://127.0.0.1:7777/cgi-bin/koha/acqui.simple/addbiblio.pl?oldbiblion
>>    
>>
>umber=8
>
>This means that the script failed to function as a "proper" CGI program.
>That is, it did not output a CGI header before any other data. This
>could be because:
>- it is not programmed to do so (you need: print "Content-type:
>text/html\n\n";)
>- an error caused it to die or produce output before it got to the
>header line.
>
>>If I close the mozilla windows, after 3 or 4 more minuts, the log is 
>>suddenly filled with dozens of :
>>[Fri May 02 16:56:52 2003] [error] [client 127.0.0.4] Use of 
>>uninitialized value in hash element at 
>>/usr/lib/perl5/site_perl/5.8.0/MARC/Record.pm line 206., referer: 
>>http://koha.dev/cgi-bin/koha/acqui.simple/addbiblio.pl?oldbiblionumber=
>>    
>>
>8
>
>You might like to look on line 206 of Record.pm... It will be a
>statement in a loop (hence dozens of lines) which is trying to use an
>uninitialised variable to lookup a hash. Test your variable with
>"defined" before using it.
>
This message is due to a bug in the call of a Net-z3950.pm sub.
a variable is not assigned correctly, causing the bug.
I know and agree about this. And as Perl reports non-CGI output, apache 
has proble.

BUT, my problem is that there is NO reporting of this error before 2mn. 
NOTHING : neither on logs, or in mozilla (in fact, in mozilla, the page 
stays to "waiting for 127.0.0.1:7777 forever)
It seems apache/perl enters a loop that lasts 2-3 minuts, trying, and 
trying again. After 2-3 mn, error is reported in the log, but still 
nothing in mozilla, then 3-4 min laters, the log shows 12x of 
MARC::Record error, suddenly.

>>Note it occurs only on a runtime error in the module. In case of a 
>>compilation error, the error is reported immediatly as previously.
>>
>>It's a bug in Koha, but with my previous install (http1.3 from mdk90), 
>>The errors where reported immediatly to the error log.
>>At the moment, it's pretty unuseable for error tracking !
>>    
>>
>
>Well, CGI is not exactly a program debug environment... You're supposed
>to get your code working before you put it on the webserver (e.g. from
>the command-line). However, if you want to see more output, activate the
>"ScriptLog". See the docs for details but one tip: the ScriptLog file
>should be owned by the apache "User" and it should exist before you use
>it (unlike the other log files which are owned by root and get created
>if they don't exist).
>
Activating ScriptLog does nothing more...
The errorlog & the ScriptLog file are filled on a strange basis.

Note too, that i never had this problem before (with mandrake 9.0 and 
apache 1.3.x).
Note (I repeat) that this occurs ONLY on bugs that happends in installed 
packages. Errors that occurs in my own perl scripts are correctly 
reported (as far as i can understand what happends !)

I'm still needing help...

-- 
Paul POULAIN
Consultant ind├ępendant en logiciels libres
responsable francophone de koha (SIGB libre http://www.koha-fr.org)


Mime
View raw message