Received: from localhost (unknown [200.46.204.183]) by developer.postgresql.org (Postfix) with ESMTP id DF97A2E0038 for ; Mon, 5 May 2008 13:10:21 -0300 (ADT) Received: from developer.postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 35122-08 for ; Mon, 5 May 2008 13:10:18 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from relay-1.mail.nethere.net (relay-1.mail.nethere.net [66.63.128.161]) by developer.postgresql.org (Postfix) with ESMTP id D20A82E0032 for ; Mon, 5 May 2008 13:10:18 -0300 (ADT) Received: from scan-1.mail.nethere.net (scan-1.mail.nethere.net [66.63.128.132]) by relay-1.mail.nethere.net (Postfix) with ESMTP id 07B2529388; Mon, 5 May 2008 09:10:17 -0700 (PDT) Received: from mta-1.mail.nethere.net by scan-1.mail.nethere.net with LMTP id R+bgfXApgOyV; Mon, 5 May 2008 09:10:16 -0700 (PDT) Received: from lisa-james-computer.local (wsip-68-224-174-233.sd.sd.cox.net [68.224.174.233]) by mta-1.mail.nethere.net (Postfix) with ESMTP id C9CBAF1831; Mon, 5 May 2008 09:10:16 -0700 (PDT) Message-ID: <481F3168.8050600@emolecules.com> Date: Mon, 05 May 2008 09:10:16 -0700 From: Craig James User-Agent: Thunderbird 2.0.0.14 (Macintosh/20080421) MIME-Version: 1.0 To: "Campbell, Lance" CC: pgsql-performance@postgresql.org Subject: Re: Backup causing poor performance - suggestions References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200805/55 X-Sequence-Number: 30023 Campbell, Lance wrote: > We currently backup all of our database tables per schema using pg_dump > every half hour. We have been noticing that the database performance > has been very poor during the backup process. How can I improve the > performance? It sounds like the goal is to have frequent, near-real-time backups of your databases for recovery purposes. Maybe instead of looking at pg_dump's performance, a better solution would be a replication system such as Slony, or a "warm backup" using Skype Tools. Backing up the database every half hour puts a large load on the system during the dump, and means you are re-dumping the same data, 48 times per day. If you use a replication solution, the backup process is continuous (spread out through the day), and you're not re-dumping static data; the only data that moves around is the new data. I've used Slony with mixed success; depending on the complexity and size of your database, it can be quite effective. I've heard very good reports about Skype Tools, which has both a Slony-like replicator (not as configurable as Slony, but easier to set up and use), plus an entirely separate set of scripts that simplifies "warm standby" using WAL logging. Craig