[Koha-devel] [Koha] How to update two koha databases in different servers.

Robin Sheat robin at catalyst.net.nz
Sun May 12 03:38:49 CEST 2013


Op 12-05-13 03:00, Waylon Robertson schreef:
> Yes, easiest method, doing realtime updates, is mysql replication. Now,
> theres two methods of doing this, first is using mysql's own replication
> method, and second is using MySQL::Replication as found on cpan.
> Brilliant perl based replication system.

Be aware that replication is not a backup*. It's good for hot/warm
standby in the case that the primary fails, however if you typo on the
databased and drop a table you didn't want to, you can't restore that
from a replicated slave as the typo will be replicated too.

What we do is have daily snapshots (which are automatically created by
the packages in /var/spool/koha) synced off the Koha servers and
included as part of our standard server backup régime.

I've also set up a system for a client that took the dump from their
production site and restored it onto their staging server every week or
so, so they have a place they can experiment with. This wasn't hard at
all to automate with a cron job (a copy of the database is put in a
location apache can access, protected with .htpasswd, the staging server
fetches it when it wants to and replaces the current database with the
new one.)

What you need, of these options, is certainly dependent on your
requirements, and it's quite possible replication is what you want. But
don't forget about backups, too.

Robin.

* I'm not actually claiming that you said this, but it's a common thing
to hear people say things like "oh, I have backups: the server
replicates/has RAID", which is a code for them saying that they don't
have backups :)

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 263 bytes
Desc: OpenPGP digital signature
URL: <http://lists.koha-community.org/pipermail/koha-devel/attachments/20130512/bba997a8/attachment.pgp>


More information about the Koha-devel mailing list