Database Reference
In-Depth Information
Selective replication using Londiste
Londiste is part of the Skytools suite of software, produced by and used by Skype for their
production transactional databases. Londiste is a replication system built on top of a generic
event-queuing system named PgQ (pronounced as pg-queue), a PostgreSQL extension module.
It's simple, easy, and robust.
One of the most important features is that Londiste achieves eventual consistency between
Master and Standby in a relaxed manner, ensuring that operations on the Master are lock-free.
Getting ready
If you haven't read the recipes on Replication Concepts and Replication best practice at the
start of this chapter, please go and read them now. Replication is complex, and even if you
think "no problem, I know that", it's worth just checking the basic concepts and names that I'll
be using here.
How to do it...
Carry out the following steps to configure Londiste replication:
1. Install the software and create directories: On Debian/Ubuntu the software installed
using the names without the .py suffix, so just pgqadm and Londiste.
2. Configure clustname_ticker.ini as follows:
[pgqadm]
job_name = clustname_ticker
db = dbname=ticker
# how often to run maintenance [seconds]
maint_delay = 600
# how often to check for activity [seconds]
loop_delay = 0.1
logfile = /var/log/londiste/%(job_name)s.log
pidfile = /var/log/londiste/%(job_name)s.pid
3. Configure clustname_londiste.ini as follows:
[londiste]
job_name = clustname_londiste
provider_db = dbname=source port=6000 host=groucho
subscriber_db = dbname=target port=6000 host=zeppo
pgq_queue_name = clustname_queue
pgq_lazy_fetch = 500
logfile = /var/log/londiste/%(job_name)s.log
pidfile = /var/run/londiste/%(job_name)s.pid
 
Search WWH ::




Custom Search