Re: monitoring warm standby lag in 8.4?

From: Scott Mead <scott(at)scottrmead(dot)com>
To: Josh Kupershmidt <schmiddy(at)gmail(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: monitoring warm standby lag in 8.4?
Date: 2010-12-10 17:21:26
Message-ID: AANLkTik6FNPMyWkFr6R8Pi_-TVVXaHhXhLKes4xSNVr1@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Yeah, my website is busted. I'll fix it for you.

On Thu, Dec 9, 2010 at 2:30 PM, Josh Kupershmidt <schmiddy(at)gmail(dot)com> wrote:
> Hi all,
>
> I'm wondering if there's an accepted way to monitor a warm standby
> machine's lag in 8.4. The wiki[1] has a link[2] to a script which
> parses the output of pg_controldata, looking for a line like this:
>
>  Time of latest checkpoint:            Thu 09 Dec 2010 01:35:46 PM EST
>
> But I'm not sure whether this timestamp is to be trusted as an
> indicator of how far behind the standby is in its recovery -- this
> timestamp just tells us when the standby last performed a checkpoint,
> regardless of how far behind in the WAL stream it is, right?
>
> I haven't come across any other monitoring suggestions for warm
> standby on 8.4. I've seen suggestions for hot standby slaves to use:
>  SELECT pg_last_xlog_receive_location();
> but this won't work on an 8.4 warm standby of course. I've searched
> around and haven't found[3] any other tips on how to monitor my
> standby.
>
> The manual mentions[4] using pg_xlogfile_name_offset() in the context
> of implementing record-based log shipping. Would this be useful for
> monitoring standby lag? Any other ideas?
>
> Thanks,
> Josh
>
>
> --
> [1] http://wiki.postgresql.org/wiki/Warm_Standby
> [2] http://www.kennygorman.com/wordpress/?p=249
> [3] I was hoping this page would have some relevant info:
> http://www.scottrmead.com/blogs/scott/warm-standby-monitoring , but
> it's down now :(
> [4] http://www.postgresql.org/docs/8.4/static/warm-standby.html#WARM-STANDBY-RECORD
>
> --
> Sent via pgsql-general mailing list (pgsql-general(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-general
>

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Merlin Moncure 2010-12-10 17:22:23 Re: Extended query protocol and exact types matches.
Previous Message Dmitriy Igrishin 2010-12-10 17:20:19 Re: A cronjob for copying a table from Oracle