Monday, January 17, 2011

Breaking Koha

(following is mostly for my benefit)  In playing with the test version of Koha (just doing the simple things), I managed to break it.  After deleting a record, OPAC searches return the following error:

Can't call method "as_usmarc" on an undefined value at /usr/share/koha/lib/C4/ line 2384.

It took a bit of search in Google but I did come across this post from Mason James.  His recommendation is to run:

./bin/migration_tools/ *or*./bin/migration_tools/

Problem is that if you run the above from /usr/share/koha, you receive complaints about not being able to find the Perl module C4::Context. The solution is to run the script with the full path, like:


The above rebuilds the BIBLIO and AUTHORITIES indexes and you should be able to search via the OPAC page again.