Re: Setting up HA postgresql

From: William Dunn <dunnwjr(at)gmail(dot)com>
To: Tatsuo Ishii <ishii(at)postgresql(dot)org>
Cc: אביאל בוסקילה <aviel33(at)gmail(dot)com>, PostgreSQL General <pgsql-general(at)postgresql(dot)org>
Subject: Re: Setting up HA postgresql
Date: 2015-07-23 19:50:46
Message-ID: CAEva=VkzHiyYTFQqTDYjCYeSVAar3rgi3nqRa-Fjf+fR7BsgVA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Thanks so much for lending your expertise Tatsuo.

Aviel I have found and linked below the relevant section of the official
pgpool-II docs on using pgpool-II for failover. It is available starting in
pgpool-II version 3.1:
http://www.pgpool.net/docs/latest/pgpool-en.html#stream

*Will J. Dunn*

On Tue, Jul 21, 2015 at 10:07 PM, Tatsuo Ishii <ishii(at)postgresql(dot)org> wrote:

> > But it appears that the fail condition for "watchdog" is the failure of a
> > pgpool-II instance. In the configuration described in the wiki you would
> > put a pgpool-II instance on each Postgres node, and if one of the
> pgpool-II
> > instances fails it executes a script (which can create the trigger file
> to
> > promote the standby to master). However, if the fail condition for
> watchdog
> > is a failure of the pgpool-II instance what happens if the DBMS has
> > availability issues but the pgpool-II process on that server is ok? The
> > fail condition would never be triggered, right?
>
> No. The condition (PostgreSQL failure) will be detected by one of
> pgpool-II (not watchdog process) and the pgpool-II will disconnect the
> failed PostgreSQL, then execute failover script (if defined) which
> will usually promote standby PostgreSQL (if failed PostgreSQL was
> primary) or just ignore the broken PostgreSQL if it was standby.
>
> Best regards,
> --
> Tatsuo Ishii
> SRA OSS, Inc. Japan
> English: http://www.sraoss.co.jp/index_en.php
> Japanese:http://www.sraoss.co.jp
>
> > *Will J. Dunn*
> > *willjdunn.com <http://willjdunn.com>*
> >
> > On Tue, Jul 21, 2015 at 4:27 PM, Joshua D. Drake <jd(at)commandprompt(dot)com>
> > wrote:
> >
> >>
> >> On 07/21/2015 01:21 PM, William Dunn wrote:
> >>
> >>> That's pretty cool! But the intended use of watchdog is so you can have
> >>> multiple pgpool-II instances and failover among them
> >>> (http://www.pgpool.net/docs/latest/pgpool-en.html#watchdog) rather
> than
> >>> failure of Postgres. In the configuration described in that wiki what
> >>> happens when the DBMS goes down but pgpool-II is fine? The watchdog
> >>> appears to be monitoring the pgpool-II process, not the
> >>> postgres/postmaster process.
> >>>
> >>
> >> From what I see, it has the ability to execute a command/script based
> on a
> >> failed condition which could include but not be limited to a command to
> >> fail over a standby.
> >>
> >>
> >> JD
> >>
> >> --
> >> Command Prompt, Inc. - http://www.commandprompt.com/ 503-667-4564
> >> PostgreSQL Centered full stack support, consulting and development.
> >> Announcing "I'm offended" is basically telling the world you can't
> >> control your own emotions, so everyone else should do it for you.
> >>
>

In response to

Browse pgsql-general by date

  From Date Subject
Next Message twoflower 2015-07-23 20:17:46 The fastest way to update thousands of rows in moderately sized table
Previous Message Jon Lapham 2015-07-23 19:04:56 Re: Using the database to validate data