Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1X2PLM-00012B-7p for pgsql-admin@arkaria.postgresql.org; Wed, 02 Jul 2014 18:33:20 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1X2PLL-0006m0-OR for pgsql-admin@arkaria.postgresql.org; Wed, 02 Jul 2014 18:33:19 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1X2PJN-0005F2-Hn for pgsql-admin@postgresql.org; Wed, 02 Jul 2014 18:31:17 +0000 Received: from qmta07.emeryville.ca.mail.comcast.net ([2001:558:fe2d:43:76:96:30:64]) by magus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1X2PJJ-000329-S7 for pgsql-admin@postgresql.org; Wed, 02 Jul 2014 18:31:16 +0000 Received: from omta06.emeryville.ca.mail.comcast.net ([76.96.30.51]) by qmta07.emeryville.ca.mail.comcast.net with comcast id MWJ41o00816AWCUA7WXAQw; Wed, 02 Jul 2014 18:31:10 +0000 Received: from jerry.enova.com ([38.98.177.132]) by omta06.emeryville.ca.mail.comcast.net with comcast id MWWz1o00b2rmZlA8SWX2XA; Wed, 02 Jul 2014 18:31:08 +0000 Received: by jerry.enova.com (Postfix, from userid 1001) id 874A67401EE; Wed, 2 Jul 2014 13:30:59 -0500 (CDT) From: Jerry Sievers To: John Scalia Cc: "pgsql-admin\@postgresql.org" Subject: Re: WAL archiving to 2 standby servers References: <53B44151.4030200@gmail.com> Date: Wed, 02 Jul 2014 13:30:59 -0500 In-Reply-To: <53B44151.4030200@gmail.com> (John Scalia's message of "Wed, 02 Jul 2014 13:28:49 -0400") Message-ID: <86ionfmx3w.fsf@jerry.enova.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.4 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcast.net; s=q20140121; t=1404325870; bh=r22iIe03O+fOp7MnjayvYABqEl2ABOJK/F+OIgg3Gdg=; h=Received:Received:Received:From:To:Subject:Date:Message-ID: MIME-Version:Content-Type; b=wC6kaSfcSwYSCtfjY1DWnYY1u7hMe/6nKm4R8gka2IFOvvuGh1s0DSQ21ushakq3l EATNiok+t4BbnN8rGcFR3PqLAS0vVLBIpeD0y4zP5xAwwu7IGczCWr2H/J0qUvc94Q 5UgxkIijzrR86H+pj4VDp2KLjGgk+oACOAsgMXnyBdgEg5qBSeVg7rSiiSkuLMYVQW mtIt3A2tsbkTmMSIj1I+3MB1ALyYbsCBXZnYtd7bND+TWYzm32biYYu9MfW1Cz0EJj IY8FHAtxKkwMpUwgEJVAKA3vwzXYgza+e0/aIFO7gwrTCWBfJ+USs0zMgkFto628tR ZT+yRnMVpi0TA== X-Pg-Spam-Score: -0.8 (/) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-admin Precedence: bulk Sender: pgsql-admin-owner@postgresql.org John Scalia writes: > Hi all, > > I'm wondering as I've never seen anyone doing this if I can/should > setup WAL archiving from the primary server to 2 different standby > servers. These machines are configured to be streaming replication and > I've got the archive command on the primary doing an scp to both > standbys, but for some reason the second one isn't getting > anything. What the archive_command looks like is "scp %p > user@standby1://%f; scp %p user@standby2:/%f". That's not > wokring correctly, but I'm wondering if it's even necessary for the > 2nd standby? Look in your server log for errors on the 2nd scp. Also check your $PGDATA/pg_xlog/archive_status directory for a pile-up of *.ready files. If your archive command isn't fully operational and is returning non-zero to the caller, then Pg thinks archiving is failing and will *not* recycle the related xlog files. I'd suggest also you get on the server box as user postgres and make sure you can manually ssh without being prompted for a password and/or asked to verify host keys... fix mismatching lines in ~/.ssh/known_hosts file etc. As for whether or not you should be sending WALs to both instances, it depends on what you need to accomplish. HTH > > Just askin', > Jay > > PS. There are two standby's to deal with the problem of synchronous_commit and the failure of one of the standby's. -- Jerry Sievers Postgres DBA/Development Consulting e: postgres.consulting@comcast.net p: 312.241.7800 -- Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-admin