[Koha] How to snapshot / restore a Koha Database?

Doug Dearden dearden at sarsf.org
Fri Feb 9 10:06:00 NZDT 2018

Hi Chris,

I am thinking this works if you do koha-dump / koha-restore.  I think when you do the koha-remove that is when you lose your apache configs and some other stuff.  You would need a koha-create to put all those in place, then koha-restore.  Leave koha-remove out of the sequence and you don't need koha-create, everything will be there and a koha-restore puts the database back to where it was when you did koha-dump.

That's just off the top of my head.  I didn't test it.


Doug Dearden

-----Original Message-----
From: Koha [mailto:koha-bounces at lists.katipo.co.nz] On Behalf Of Chris Brown
Sent: Thursday, February 8, 2018 8:53 AM
To: koha <koha at lists.katipo.co.nz>
Subject: [Koha] How to snapshot / restore a Koha Database?

Gentle Reader,

I need to deliver multiple Koha training sessions for several groups of
volunteers who work on our front desk. I'll be setting a specific series of
tasks and it will be much easier if I can "reset" the database to a
previous checkpoint before each session so we can re-run the same tasks.

So ... I've tried the sequence koha-dump / koha-remove / koha-restore; I
got a list of "File exists" errors when I did the koha-restore (mostly in
/var/lib/koha/stand, where "stand" is my instance name). These didn't
trouble me too much but I then had to fix a missing
/etc/apache2/sites-enabled/stand.conf and a missing /var/log/koha/stand
directory before apache would start up.

Now, when I try to log in I get a perl error about an unblessed reference
in /usr/share/koha/lib/Koha/Database.pm (line 56). This is getting too deep
into the code for me to have much hope of debugging it, so before I spend
more time on this (or give up entirely) does anyone have any advice on the
right command sequence (with the right options) that I can use to achieve
this in a clean, pain-free way?

Thanks and Best Regards,

Chris Brown
Koha mailing list  http://koha-community.org
Koha at lists.katipo.co.nz

More information about the Koha mailing list