Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: ModPerl: ModPerl

APR::Table sporadic error

 

 

ModPerl modperl RSS feed   Index | Next | Previous | View Threaded


aubreyja at gmail

May 6, 2011, 8:24 AM

Post #1 of 4 (796 views)
Permalink
APR::Table sporadic error

Hi All,

We have a modperl application that is an online homework system for math
courses called webwork. My installation and a few others have seen a
sporadic error from APR::Table that nobody quite knows how to diagnose.
Here are two typical examples:

Example 1:
Can't locate object method "get" via package "APR::Table" at
[WW]/lib/Apache/WeBWorK.pm line 74
Died within AnswerEvaluator::evaluate called at line 1 of (eval 1321)
System: Ubuntu 8.04, Apache 2.2

Example 2:
Failed to initialize course environment: Could not evaluate global
environment file /opt/webwork/webwork2/conf/global.conf: Can't locate object
method "get" via package "APR::Table" at
/opt/webwork/webwork2/lib/Apache/WeBWorK.pm line 74.
RHEL 5 with RedHat's build of Apache 2.2.3. 1 GB RAM, perl-status shows
ARP::Table is loaded.
APR::Table 0.009000 Fri Sep 19 04:30:28 2008
/usr/lib64/perl5/vendor_perl/5.8.8/x86_64-linux-thread-multi/APR/Table.pm

I'm hoping you might be able to provide some suggestions of where to start
looking for the source of this problem.

The modperl handler is here:

http://webwork.maa.org/viewvc/system/trunk/webwork2/lib/Apache/WeBWorK.pm?view=markup

The error was not seen (and has not been seen) running mod_perl 1. Here is
a report from one user:

We've seen the APR::Table error sporadically, and have found it to be
> chronic and page load dependent. We've found in every case that if we reload
> the page the error will go away. Our hypothesis is that it's probably a
> thread initialization problem, and that it shows up when the apache process
> hands the WeBWorK job off to a new thread that doesn't have all of the
> required Perl loaded before the it tries to execute the WeBWorK request.
> That said, we don't know much about thread management in apache, so we don't
> know if that's even credible.


Any hints/tips/ideas would be very much appreciated.

Thanks,
Jason


torsten.foertsch at gmx

May 6, 2011, 9:01 AM

Post #2 of 4 (769 views)
Permalink
Re: APR::Table sporadic error [In reply to]

On Friday, May 06, 2011 17:24:18 Jason Aubrey wrote:
> Any hints/tips/ideas would be very much appreciated.

Are you really sure (I mean really really) that APR::Table is loaded? I
see you load Apache2::Log but nothing about APR::Table.

I think if you replace line 74

my $warnings = $r->notes->get("warnings");

by

my $warnings = eval {$r->notes->get("warnings")};
if( $@ ) {
warn "APR::Table is '$INC{q{APR/Table.pm}}'";
die $@;
}

you will see that it is not loaded.

If you use a threaded Perl make sure every interpreter loads APR::Table.
Do you by chance use PerlOptions +Parent in a VHost?

Torsten Förtsch

--
Need professional modperl support? Hire me! (http://foertsch.name)

Like fantasy? http://kabatinte.net


aubreyja at gmail

May 6, 2011, 9:05 AM

Post #3 of 4 (765 views)
Permalink
Re: APR::Table sporadic error [In reply to]

>
> my $warnings = eval {$r->notes->get("warnings")};
> if( $@ ) {
> warn "APR::Table is '$INC{q{APR/Table.pm}}'";
> die $@;
> }
>
> you will see that it is not loaded.
>
>
Thanks Torsten - we'll try this out.

If you use a threaded Perl make sure every interpreter loads APR::Table.
> Do you by chance use PerlOptions +Parent in a VHost?
>
> No, the typical configuration is like this:

http://webwork.maa.org/viewvc/system/trunk/webwork2/conf/webwork.apache2-config.dist?revision=6531&view=markup

Thanks again,
Jason


aubreyja at gmail

May 6, 2011, 11:18 AM

Post #4 of 4 (766 views)
Permalink
Re: APR::Table sporadic error [In reply to]

Additional data:

One effected installation (Ubuntu 10.04.2, Apache 2.2.14, Perl 5.10.1,
libapache2-mod-perl2 2.0.4) reports that that eval
{$r->notes->get("warnings")} did not produce an error ($@ was not set) in
his case, but that this problem went away for him after reverting the ubuntu
perl updates from May 4 (http://www.ubuntu.com/usn/usn-1129-1/).

Those perl updates on Ubuntu seem to have triggered this error for the two
installations that reported it today, but the strange thing is that this is
not the first time we've seen this error - it was reported on a CentOS
installation and two RHEL 5 installations in January.

Perhaps RH et. al. applied the patches for the SVE's in January and Ubuntu
just now, and one of those changes is causing this. Still, we don't know,
so any other possible leads will be eagerly followed.

Jason

2011/5/6 Jason Aubrey <aubreyja [at] gmail>

>
>
>> my $warnings = eval {$r->notes->get("warnings")};
>> if( $@ ) {
>> warn "APR::Table is '$INC{q{APR/Table.pm}}'";
>> die $@;
>> }
>>
>> you will see that it is not loaded.
>>
>>
> Thanks Torsten - we'll try this out.
>
> If you use a threaded Perl make sure every interpreter loads APR::Table.
>> Do you by chance use PerlOptions +Parent in a VHost?
>>
>> No, the typical configuration is like this:
>
>
> http://webwork.maa.org/viewvc/system/trunk/webwork2/conf/webwork.apache2-config.dist?revision=6531&view=markup
>
> Thanks again,
> Jason
>
>

ModPerl modperl RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.