Item9118: Plugin breaks entire installation: Can't call method "db_get" on an undefined value
Priority: Urgent
Current State: Closed
Released In:
Target Release: n/a
Description
When
DBCachePlugin is enabled in
configure
, the entire Foswiki installation stops working as on every page request, the server only replies
Can't call method "db_get" on an undefined value at /var/lib/foswiki/lib/Foswiki/Contrib/DBCacheContrib/Archivist/BDB.pm line 66., referer: http://intwiki.fzk.de/System/SpreadSheetPlugin
, regardless which page was requested.
Entire apache2 log for one single page load:
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] Can't call method "db_get" on an undefined value at /var/lib/foswiki/lib/Foswiki/Contrib/DBCacheContrib/Archivist/BDB.pm line 66., referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] at /var/lib/foswiki/lib/Foswiki/Contrib/DBCacheContrib/Archivist/BDB.pm line 66, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::Contrib::DBCacheContrib::Archivist::BDB::db_get('Foswiki::Contrib::DBCacheContrib::Archivist::BDB=HASH(0x984bce8)', '__ROOT__') called at /var/lib/foswiki/lib/Foswiki/Contrib/DBCacheContrib/Archivist/BDB.pm line 96, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::Contrib::DBCacheContrib::Archivist::BDB::getRoot('Foswiki::Contrib::DBCacheContrib::Archivist::BDB=HASH(0x984bce8)') called at /var/lib/foswiki/lib/Foswiki/Contrib/DBCacheContrib.pm line 473, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::Contrib::DBCacheContrib::load('Foswiki::Plugins::DBCachePlugin::WebDB=HASH(0x984bcc8)', 0) called at /var/lib/foswiki/lib/Foswiki/Plugins/DBCachePlugin/WebDB.pm line 61, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::Plugins::DBCachePlugin::WebDB::load('Foswiki::Plugins::DBCachePlugin::WebDB=HASH(0x984bcc8)', 0) called at /var/lib/foswiki/lib/Foswiki/Plugins/DBCachePlugin/Core.pm line 1251, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::Plugins::DBCachePlugin::Core::getDB('System') called at /var/lib/foswiki/lib/Foswiki/Plugins/DBCachePlugin/Core.pm line 167, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::Plugins::DBCachePlugin::Core::getTopicTitle('System', 'CategoryCategory') called at /var/lib/foswiki/lib/Foswiki/Plugins/DBCachePlugin/Core.pm line 85, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::Plugins::DBCachePlugin::Core::renderWikiWordHandler('CategoryCategory', 1, 'System', 'CategoryCategory') called at /var/lib/foswiki/lib/Foswiki/Plugins/DBCachePlugin.pm line 139, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::Plugins::DBCachePlugin::renderWikiWordHandler('CategoryCategory', 1, 'System', 'CategoryCategory') called at /var/lib/foswiki/lib/Foswiki/Plugin.pm line 273, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::Plugin::invoke('Foswiki::Plugin=HASH(0x89f54e0)', 'renderWikiWordHandler', 'CategoryCategory', 1, 'System', 'CategoryCategory') called at /var/lib/foswiki/lib/Foswiki/Plugins.pm line 316, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::Plugins::dispatch('Foswiki::Plugins=HASH(0x85058a0)', 'renderWikiWordHandler', 'CategoryCategory', 1, 'System', 'CategoryCategory') called at /var/lib/foswiki/lib/Foswiki/Render.pm line 634, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::Render::internalLink('Foswiki::Render=HASH(0x8a8ee40)', 'System', 'CategoryCategory', 'CategoryCategory', '', 1, undef, 1) called at /var/lib/foswiki/lib/Foswiki/Render.pm line 886, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::Render::_handleSquareBracketedLink('Foswiki::Render=HASH(0x8a8ee40)', 'System', 'InstalledPlugins', undef, undef) called at /var/lib/foswiki/lib/Foswiki/Render.pm line 1342, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::Render::getRenderedVersion('Foswiki::Render=HASH(0x8a8ee40)', '\\x{a}\\x{a}<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//...', 'System', 'InstalledPlugins') called at /var/lib/foswiki/lib/Foswiki/UI/View.pm line 389, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::UI::View::_prepare('\\x{a}\\x{a}<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//...', 'Foswiki=HASH(0x8198278)', 'System', 'InstalledPlugins', 'Foswiki::Meta=HASH(0x940dfe0)', 0) called at /var/lib/foswiki/lib/Foswiki/UI/View.pm line 348, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::UI::View::view('Foswiki=HASH(0x8198278)') called at /var/lib/foswiki/lib/Foswiki/UI.pm line 304, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::UI::__ANON__() called at /usr/share/perl5/Error.pm line 416, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \teval {...} called at /usr/share/perl5/Error.pm line 408, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tError::subs::try('CODE(0x8219500)', 'HASH(0x8a8d4b0)') called at /var/lib/foswiki/lib/Foswiki/UI.pm line 391, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::UI::_execute('Foswiki::Request=HASH(0x8505b70)', 'CODE(0x8505730)', 'view', 1) called at /var/lib/foswiki/lib/Foswiki/UI.pm line 275, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::UI::handleRequest('Foswiki::Request=HASH(0x8505b70)') called at /var/lib/foswiki/lib/Foswiki/Engine/CGI.pm line 29, referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
[Mon Jun 07 15:35:20 2010] [error] [client ZEN.SO.RED.149] \tFoswiki::Engine::CGI::run('Foswiki::Engine::CGI=HASH(0x83f1280)') called at /var/lib/foswiki/bin/view line 45., referer: http://ZENSORED.HOST/System/SpreadSheetPlugin
Disabling the plugin turns everything alright again...
Installed Versions
We are running the most recent debian packages...
--
PhilippLeufke - 07 Jun 2010
Check if you installed
CPAN:BerlekeyDB on you server.
In any case, please use these settings:
$Foswiki::cfg{DBCacheContrib}{Archivist} = 'Foswiki::Contrib::DBCacheContrib::Archivist::Storable';
$Foswiki::cfg{DBCache}{MemoryCache} = 1;
$Foswiki::cfg{DBCacheContrib}{AlwaysUpdateCache} = 0;
$Foswiki::cfg{DBCacheContrib}{LoadFileLimit} = 0;
The default BDB archivist doesn't seem to be stable. See also
Support.Question544
--
MichaelDaum - 07 Jun 2010
Thanks for the tip. It worked after doing so plus deleting the old caches in
/var/lib/foswiki/working/work_areas/DBCacheContrib
.
Before closing this bug, please tell me what the
$Foswiki::cfg{DBCache}{MemoryCache} = 1;
option is for. It's not documented in
configure
.
--
PhilippLeufke - 08 Jun 2010
When using fastcgi or mod_perl it keeps the cache in memory instead of loading it from disk on each request.
--
MichaelDaum - 08 Jun 2010