views:

50

answers:

1

At completely random times my mod_perl scripts crash for no discernible reason, here's the error I get:

[error] install_driver(mysql) failed: Attempt to reload DBD/mysql.pm aborted.\nCompilation failed in require at (eval 20) line 3.\n\n at

but wait it gets better. Sometimes it's this instead:

[error] install_driver(mysql) failed: Can't load '/usr/lib/perl5/auto/DBD/mysql/mysql.so' for module DBD::mysql: /usr/lib/perl5/auto/DBD/mysql/mysql.so: failed to map segment from shared object: Cannot allocate memory at /usr/lib/perl/5.10/DynaLoader.pm line 196.\n at (eval 17) line 3\nCompilation failed in require at (eval 17) line 3.\nPerhaps a required shared library or dll isn't installed where expected\n at

Mind you that I am the only one hitting this app as I'm in dev mode atm so I doubt it's a concurrency issue.

Everything works very well otherwise, it's weird. I'm on a VPS running Debian 5.0 with apache 2 and mysql 5.0.51a-24+lenny2

Thanks for any help!

A: 

Do you have Apache::Reload loaded? Are you running DBD::MySQL from debian apt or from CPAN?

Malcolm
My DBD::MYSQL is from debian apt (as is everything else on my system.) There's a Reload.pm here: /usr/share/perl5/Apache2/Reload.pmbut there's no 'reload' module in mods-available. Should I be using that? I do restart apache every time I make a change to any of the scripts.However, I did sort of "solve" the problem by just hitting the server once per minute with a cron job that just 'curl's a page!?Thanks for the response!
Phil
Apache2::Reload will (attempt to) reload modules that have changed. It's sometimes useful for development as it saves restarting apache each time you make an edit. However some modules don't like being reloaded.I'm not sure how requesting a page each minute would solve the above, unless it just means you're talking to a different instance. Does it happen if you're in single process (-X) mode?
Malcolm