Re: Async replication: how to get an alert on failure

From: Edson Richter <edsonrichter(at)hotmail(dot)com>
To: Karl Denninger <karl(at)denninger(dot)net>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Async replication: how to get an alert on failure
Date: 2012-08-03 11:12:23
Message-ID: BLU0-SMTP426153230E935CC7FCC204DCFCA0@phx.gbl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Em 02/08/2012 00:22, Karl Denninger escreveu:
> On 8/1/2012 5:29 PM, Edson Richter wrote:
>> I have few PostgreSQL servers established with replication.
>> Now, is there any way to receive an e-mail in case of error during
>> synchronization?
>> I mean, is there an script I can run (maybe every 5 minutes) that
>> will check if replication is stolen, and send an e-mail in case of
>> failure?
>>
>> Thanks,
>> --
>
> I wrote a small program that goes to each of the servers in the
> replication group and checks its status on the log, computes the
> difference, and if off by more than "X" bytes prints a notification.
>
> If this is run from the cron it will remain silent unless the offset
> is breached at which point it will emit an email to the submitting
> owner of the job.
>
> --
> -- Karl Denninger
> /The Market Ticker ®/ <http://market-ticker.org>
> Cuda Systems LLC

Can you please share the query are you using so I can have a start point?

Thanks,

Edson

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Julian 2012-08-03 12:59:52 Re: How to don't update sequence on rollback of a transaction
Previous Message Frank Lanitz 2012-08-03 07:56:42 Re: How to don't update sequence on rollback of a transaction