Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id DA7BA1337B50 for ; Mon, 20 Sep 2010 14:28:18 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 48696-03 for ; Mon, 20 Sep 2010 17:28:11 +0000 (UTC) Received: from news.hub.org (news.hub.org [200.46.204.72]) by mail.postgresql.org (Postfix) with ESMTP id C875A1336018 for ; Mon, 20 Sep 2010 14:28:10 -0300 (ADT) Received: from news.hub.org (news.hub.org [200.46.204.72]) by news.hub.org (8.14.4/8.14.4) with ESMTP id o8KHSASw069790 for ; Mon, 20 Sep 2010 14:28:10 -0300 (ADT) (envelope-from news@news.hub.org) Received: (from news@localhost) by news.hub.org (8.14.4/8.14.4/Submit) id o8KH82ri020313 for pgsql-general@postgresql.org; Mon, 20 Sep 2010 14:08:02 -0300 (ADT) (envelope-from news) From: Chris Browne X-Newsgroups: pgsql.general Subject: Re: Binary Replication and Slony Date: Mon, 20 Sep 2010 12:22:14 -0400 Organization: cbbrowne Computing Inc Lines: 54 Message-ID: <87hbhkcrm1.fsf@cbbrowne.afilias-int.info> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Complaints-To: usenet@news.hub.org User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) Cancel-Lock: sha1:GDKlWvvUkKZwFkh1hnOna8QQyyk= To: pgsql-general@postgresql.org X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=2.409 tagged_above=-5 required=5 tests=BAYES_00=-1.9, FS_REPLICA=3.599, SARE_SPEC_REPLICA=0.72, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: ** X-Archive-Number: 201009/612 X-Sequence-Number: 167414 johnlicheng@gmail.com (John Cheng) writes: > Congrats on the 9.0 release of PostgreSQL. One of the features I am really > interested in is the built-in binary replication. > > Our production environment has been using PostgreSQL for more than 5 years > (since this project started). We have been using Slony-I as our replication > mechanism. I am interested to find out the pros and cons of Slony vs the > built-in replication in 9.0. Based on what I understand: > > * Slony has a higher overhead than the binary replication in 9.0 > * When using Slony, schema change must be applied via slonik (in most cases) > * Unfortunately, IMO it is easy to make a mistake when applying schema changes > in Slony, fortunately, it is easy to drop and recreate the replication sets > * Slony is an asynchronous replication mechanism > * Slony allows you to replication some tables, while ignoring others > > * PostgreSQL 9.0 with hot standby & streaming replication is an asynchronous > replication mechanism > * Overhead is low compared to Slony > > Are there some cases where it is better to use Slony, for example, when you > must specifically exclude tables from replication? I believe our system will be > better off using the built-in replication mechanism of 9.0, and I am guessing > most people will be in the same boat. There are three characteristic kinds of cases where you'll need something like Slony-I, where the built-in WAL-based replication won't work: a) You need to interact between PostgreSQL versions. Slony (and similar systems like Londiste and Bucardo) can cope with having nodes running different versions of PostgreSQL. WAL-based replication requires that all databases use *identical* versions of PostgreSQL, running on identical architectures. b) You only want to replicate parts of the changes that are going on. WAL-based replication duplicates *absolutely everything*. c) You need for there to be extra behaviours taking place on subscribers, for instance, populating cache management information. WAL-based replication duplicates *absolutely everything*, and nothing extra that changes data can run on a WAL-based replica. If you don't need any of those things, then, yes, I'd think the built-in replication is a good choice, quite likely preferable to using the trigger-based replication systems like Slony. -- output = reverse("ofni.secnanifxunil" "@" "enworbbc") "What you said you want to do is roughly equivalent to nailing horseshoes to the tires of your Buick." -- danceswithcrows@usa.net on the question "Why can't Linux use Windows Drivers?"