From: | Jeff Janes <jeff(dot)janes(at)gmail(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | Andres Freund <andres(at)2ndquadrant(dot)com>, Simon Riggs <simon(at)2ndquadrant(dot)com>, Heikki Linnakangas <hlinnakangas(at)vmware(dot)com>, Noah Misch <noah(at)leadboat(dot)com>, Pg Bugs <pgsql-bugs(at)postgresql(dot)org> |
Subject: | Re: PITR potentially broken in 9.2 |
Date: | 2012-12-05 19:08:42 |
Message-ID: | CAMkU=1wzisb=qRwQRN+nSSXqAB=PJsb+vkYE1SEhGZVhrs775w@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs pgsql-hackers |
On Wed, Dec 5, 2012 at 8:40 AM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> The real question here probably needs to be "what is the point of
> recoveryPauseAtTarget in the first place?". I find it hard to envision
> what's the point of pausing unless the user has an opportunity to
> make a decision about whether to continue applying WAL.
Right now if I'm doing a PITR and want to look around before blessing
the restore, I have to:
0) restore from the base backup.
1) change pg_hba to lock out everyone else
2) do the restore to my best guess of what was just before the tragic DML.
3) Look around and see if I guessed correctly.
4a) If I replayed to far, blow everything away and start over.
4b) If I replayed not far enough, and opened the database normally
upon completion so I could look around, then blow everything away and
start over.
4c) If I replayed not far enough and opened the database in hot
standby, I don't have to blow everything away, I just have to shut
down the server, change the restore point forward, and restart it.
5) change pg_hba back to normal and restart the server.
It would be nice if I could execute 4c without a shutdown/restart, but
certainly a shutdown/restart is better than blowing everything away
and starting over, like you have to do once the restore picks a new
time line. So while the current pause behavior is incomplete, it is
still useful.
I would also be nice if only the superuser is allowed to connect to
the hot standby when pause_at_recovery_target=true, until after
pg_xlog_replay_resume() is called. That way I could skip steps 1 and
5--steps which are very easy to forget to do.
Cheers,
Jeff
From | Date | Subject | |
---|---|---|---|
Next Message | Andres Freund | 2012-12-05 19:12:31 | Re: PITR potentially broken in 9.2 |
Previous Message | Tom Lane | 2012-12-05 18:48:53 | Re: PITR potentially broken in 9.2 |
From | Date | Subject | |
---|---|---|---|
Next Message | Robert Haas | 2012-12-05 19:10:34 | Re: Dumping an Extension's Script |
Previous Message | Andres Freund | 2012-12-05 19:01:57 | Re: Dumping an Extension's Script |