Monitoring with pg_controldata

From: Tim Uckun <timuckun(at)gmail(dot)com>
To: pgsql-general <pgsql-general(at)postgresql(dot)org>
Subject: Monitoring with pg_controldata
Date: 2009-07-29 22:10:14
Message-ID: 855e4dcf0907291510k375940b7o1ab3b7266d010ca9@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I am trying to monitor my replication lag with pg_controldata and it's
driving me nuts.

If I run pg_controldata from the command line as user postgres or root
I get the following line

Time of latest checkpoint: Thu 30 Jul 2009 00:36:12 NZST

If I run it from the crontab I get this output

Time of latest checkpoint: Wed Jul 29 23:05:34 2009

Here is the cron entity

/usr/lib/postgresql/8.3/bin/pg_controldata
/var/lib/postgresql/8.3/main >> /tmp/pg_standby_log

What is the issue here? Some sort of a timezone problem? How do I tell
it what time zone to use?

Thanks.

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Alan Deane 2009-07-29 22:58:45 V8.3 fails to start after unremming hba_file = 'ConfigDir/pg_hba.conf'
Previous Message Antonio José García Lagar 2009-07-29 21:05:36 Re: OID in $_TD->{new}/$_TD->{old}