Slony-I is a "master to multiple slaves" replication system supporting cascading (e.g. - a node can feed another node which feeds another node...) and failover.
- Version 1.2
- Legacy version (last to work with Postgresql <8.3)
- Version 2.0
- Version 2.1
- Version 2.2
- Released (recommended for production)
|Scalability||Single origin (master), up to 20 subscribers.|
|Write scaling||no/slight inverse|
|Triggers/procedures||Yes, all triggers in C language|
|Detached node/WAN||Yes, but can be clumsy|
|PostgreSQL core modifications required||No|
|Programming languages||SQL, pl/pgsql, C/SPI, C|
|Complete clustering solution||No. (load balancer, pooler required)|
|PostgreSQL versions||Multiple PG versions - varies somewhat by Slony-I version.|
Asynchronous cascading master-slave replication, row-based, using triggers and queueing in the database.
Slony-I can be combined with a pooler and load-balancer, such as pgPool2 or DBD::Multiplex, to form a complete clustering system.
- Cascading replication (master-->slave-->slave)
- Partial replication
- Upgrades of PostgreSQL and server platform
- Failover and slave promotion
- Online provisioning
- Limited detach/reattach slaves
- Maturity and field-testing (in production for 5 years)
Slony-I is a "master to multiple slaves" replication system supporting cascading (e.g. - a node can feed another node which feeds another node...) and failover. The big picture for the development of Slony-I is that it is a master-slave replication system that includes all features and capabilities needed to replicate large databases to a reasonably limited number of slave systems. Slony-I is a system designed for use at data centers and backup sites, where the normal mode of operation is that all nodes are available.
- Not a complete clustering solution
- Complexity of setup
- Limitations on schema changes
- Performance of large bulk loads and large object replication
- Write overhead and associated maintenance (vacuum etc.)
- Multiple points of monitoring required
- Master-slave, replication lag
The main drawback to Slony-I even as a replication system is the complexity of its setup and administration. The design of the system, with the database itself being used for queueing row updates, also significantly increases the amount of data writing and I/O done by the DBMS.
Also, since Slony-I is asynchronous master-slave, all writes have to be segregated to the master. Additionally, there is a noticeable lag (1-3 seconds) between the master and the slaves which may cause users to have an inconsistent view of the data.
Work sponsored by Afilias (Christopher Browne, Steven Singer) and OpenSCG (Jan Wieck).
Web site hosted by CommandPrompt
Slony-I is probably the best commercially supported replication/clustering solution. The following companies offer Slony-I support with PostgreSQL support: CommandPrompt, EnterpriseDB, Fujitsu Australia, and 2ndQuadrant. Consulting on Slony-I is also available from such companies as PostgreSQL Experts, SRA, Credativ, and End Point.