Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister

Re: Class::DBI explodes on mod_perl/Win32 due to Clone

by GeneralElektrix (Acolyte)
on Oct 03, 2012 at 19:39 UTC ( #997122=note: print w/replies, xml ) Need Help??

in reply to Class::DBI explodes on mod_perl/Win32 due to Clone


I need to share how I solved a similar problem with Package::Stash. Active Perl 5.10.1 Win32, mod_perl 2.0.4. It's a webapp using Template::Toolkit to render the user interface. I have the same "Free to wrong pool" message in Apache's error log.

For example: Free to wrong pool 2248d88 not 2264038 at X:/Path_to_Perl_site_lib/Package/ line 40.. Each one triggered an Apache restart like this: [notice] Parent: child process exited with status 255 -- Restarting.

After a lot of research on Google and reading obscure posts about how Apache, mod_perl and XS manage threads on Win32, I went to and noticed it chooses between a Pure Perl and an XS implementation around line 24:

for my $impl ('XS', 'PP') { if (eval "require Package::Stash::$impl; 1;") { $IMPLEMENTATION = $impl; last; } else { $err .= $@; } }

I simply switched 'XS' and 'PP' around in this for loop and now it chooses the Pure Perl implementation first. Problem solved. I restarted Apache and the error log don't show the "Free to wrong pool" message anymore.

Thanks to the monks who reported this problem here and helped me solve a similar issue!

Replies are listed 'Best First'.
Re^2: Class::DBI explodes on mod_perl/Win32 due to Clone
by ribasushi (Monk) on Dec 10, 2012 at 10:20 UTC
    Could you please provide more information about this issue? The authors would like to have this fixed, but more details are needed. Corresponding RT ticket #81861
      More information? The only information I didn't give is the source code for my application. I could share some if necessary. Please tell me what more you'd like to have and I will see what I can do.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://997122]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (8)
As of 2018-02-22 15:45 GMT
Find Nodes?
    Voting Booth?
    When it is dark outside I am happiest to see ...

    Results (294 votes). Check out past polls.