Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id CF6501337E8D for ; Sat, 18 Sep 2010 00:15:42 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.29]) (amavisd-maia, port 10024) with ESMTP id 71245-10 for ; Sat, 18 Sep 2010 03:15:33 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.17.8]) by mail.postgresql.org (Postfix) with ESMTP id 13EA41337EB4 for ; Sat, 18 Sep 2010 00:15:33 -0300 (ADT) Received: from [192.168.1.6] (static-71-179-240-8.bltmmd.fios.verizon.net [71.179.240.8]) by mrelayeu.kundenserver.de (node=mreu0) with ESMTP (Nemesis) id 0LhzeA-1OSfoz35e6-00n601; Sat, 18 Sep 2010 05:15:28 +0200 Message-ID: <4C942ECD.3040001@2ndquadrant.com> Date: Fri, 17 Sep 2010 23:15:25 -0400 From: Greg Smith User-Agent: Thunderbird 2.0.0.24 (X11/20100317) MIME-Version: 1.0 To: Kasia Tuszynska CC: "pgsql-admin@postgresql.org" Subject: Re: question about HA in PG 9.0 References: <232B5217AD58584C87019E8933556D110214AB147C@redmx2.esri.com> In-Reply-To: <232B5217AD58584C87019E8933556D110214AB147C@redmx2.esri.com> Content-Type: multipart/alternative; boundary="------------030502000609040103040404" X-Provags-ID: V02:K0:Sr/bHl9qBONxKvZk3g8hNfo2gR0YLprfu3pCvf81aDq 0sQixCK1Kkm0IMQzFdYlAbV2XgxAPqDhDMVNo6IcVfhKf4NxPk 2tA7nc0GYAE0IVsotL+nxGih2BuAXhEhyNwrQ7H5Hh/oiLfJGI lrkYnH6MiUuK1OpMmZIxLEA9Yfo09IKxl5WTefwoBUFaqqmHDS bWij7HtZHH3n0uwLzJuJaKbckYgshBUtPTkjW+Ijak= X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.899 tagged_above=-10 required=5 tests=BAYES_00=-1.9, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001 X-Spam-Level: X-Archive-Number: 201009/112 X-Sequence-Number: 35656 This is a multi-part message in MIME format. --------------030502000609040103040404 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Kasia Tuszynska wrote: > > The doc is lovely but all of the examples are for linux, has anyone > tired a Hot Standby streaming scenario on windows? Any issues > specific to windows? I know that linux and windows environments > "should" behave the same but actually running in both of those > environments exposes many differences. > As there is a certain amount of helper scripting required to get Streaming Replication setup, and the usual scripting languages people tend to write them in (bash, Python, Perl) don't ship with Windows, you will have a bit of extra work to do here. I'm not aware of any production-quality setups that have tested the 9.0 implementation under Windows yet, but the similar hard parts have certainly been done before with earlier versions. > I have been reading up on this issue most notably on > http://wiki.postgresql.org/wiki/Shared_Storage, where the suggestions > have been gravitating to solutions on the physical level. > > Are there any software level solutions? ( I have a feeling that this > may be a stupid question, but I want to implement this in the cloud, > and not potentially kill an ami instance) > The only way you will implement "Shoot the other node in the head" on EC2 approaching the same level of reliability a hardware solution provides is to do just that: don't begin failover to a new node until you've made sure the unreponsive master has been killed, and its AMI instance disabled from powering back up again. Automating that is exactly where I plan to go with redundant EC2 deployments of this type. But you could do it as part of a manual failover if you had to. You cannot let the original master touch the shared data store ever again once it's been taken out of the loop. If your storage is on EBS, I'm not sure how that handles two attempts to attach a writer to the store, but you'd want to test that out too. -- Greg Smith, 2ndQuadrant US greg@2ndQuadrant.com Baltimore, MD PostgreSQL Training, Services and Support www.2ndQuadrant.us Author, "PostgreSQL 9.0 High Performance" Pre-ordering at: https://www.packtpub.com/postgresql-9-0-high-performance/book --------------030502000609040103040404 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Kasia Tuszynska wrote:

The doc is lovely but all of the examples are for linux, has anyone tired a Hot Standby streaming scenario on windows?  Any issues specific to windows?  I know that linux and windows environments “should” behave the same but actually running in both of those environments exposes many differences.


As there is a certain amount of helper scripting required to get Streaming Replication setup, and the usual scripting languages people tend to write them in (bash, Python, Perl) don't ship with Windows, you will have a bit of extra work to do here.  I'm not aware of any production-quality setups that have tested the 9.0 implementation under Windows yet, but the similar hard parts have certainly been done before with earlier versions.

I have been reading up on this issue most notably on http://wiki.postgresql.org/wiki/Shared_Storage, where the suggestions have been gravitating to solutions on the physical level.

Are there any software level solutions? ( I have a feeling that this may be a stupid question, but I want to implement this in the cloud, and not potentially kill an ami instance)


The only way you will implement "Shoot the other node in the head" on EC2 approaching the same level of reliability a hardware solution provides is to do just that:  don't begin failover to a new node until you've made sure the unreponsive master has been killed, and its AMI instance disabled from powering back up again.  Automating that is exactly where I plan to go with redundant EC2 deployments of this type.  But you could do it as part of a manual failover if you had to.  You cannot let the original master touch the shared data store ever again once it's been taken out of the loop.  If your storage is on EBS, I'm not sure how that handles two attempts to attach a writer to the store, but you'd want to test that out too.

-- 
Greg Smith, 2ndQuadrant US greg@2ndQuadrant.com Baltimore, MD
PostgreSQL Training, Services and Support  www.2ndQuadrant.us
Author, "PostgreSQL 9.0 High Performance"    Pre-ordering at:
https://www.packtpub.com/postgresql-9-0-high-performance/book
--------------030502000609040103040404--