[GENERAL] - PostgreSQL Replication Types

2015-12-17 Thread Will McCormick
I inherited a 9.1 replication environment Few basic questions that I can't find clear answers / clarifications for if possible: 3 types of replication in 9.1 I've read about from the offical docs: 1) warm standby 2) hot standby 3) streaming replication I'm using streaming replication I believe,

Re: [GENERAL] - PostgreSQL Replication Types

2015-12-17 Thread Adrian Klaver
On 12/17/2015 07:17 AM, Will McCormick wrote: I inherited a 9.1 replication environment Few basic questions that I can't find clear answers / clarifications for if possible: 3 types of replication in 9.1 I've read about from the offical docs: 1) warm standby 2) hot standby 3) streaming replica

Re: [GENERAL] - PostgreSQL Replication Types

2015-12-17 Thread David Steele
Hi Will, On 12/17/15 10:17 AM, Will McCormick wrote: > I inherited a 9.1 replication environment > > Few basic questions that I can't find clear answers / clarifications for > if possible: > > 3 types of replication in 9.1 I've read about from the offical docs: > > 1) warm standby This is a s

[GENERAL] Error promoting slave on cascading replication using replication slots

2015-12-17 Thread Alvaro Melo
Hi, I'm configuring a cascading replication environment, with replication slots, but I'm having a problem when the master goes down and I promote a slave. All servers start from a cluster created from scratch, with default config options. The process that I'm using to set up the cascading rep

Re: [GENERAL] - PostgreSQL Replication Types

2015-12-17 Thread Will McCormick
Thanks a ton for the prompt response. I've read most of this but some it was not clear until we discussed. Updated with WLM: On 12/17/2015 07:17 AM, Will McCormick wrote: > > I inherited a 9.1 replication environment > > Few basic questions that I can't find clear answers / clarifications for >

Re: [GENERAL] Check old and new tuple in row-level policy?

2015-12-17 Thread Karl Czajkowski
I feel that the fundamental question here is about the semantics of "row" in row security. The core question is whether UPDATE has a different semantics with respect to row identity and security context than a sequence of DELETE, INSERT. At the moment, the documented solution feels like "tuple se

Re: [GENERAL] - PostgreSQL Replication Types

2015-12-17 Thread Adrian Klaver
On 12/17/2015 07:56 AM, Will McCormick wrote: Thanks a ton for the prompt response. I've read most of this but some it was not clear until we discussed. Updated with WLM: On 12/17/2015 07:17 AM, Will McCormick wrote: I inherited a 9.1 replication environment Few basic questions that

Re: [GENERAL] - PostgreSQL Replication Types

2015-12-17 Thread Will McCormick
Thanks for the great assistance On Thu, Dec 17, 2015 at 11:27 AM, Adrian Klaver wrote: > On 12/17/2015 07:56 AM, Will McCormick wrote: > >> Thanks a ton for the prompt response. >> >> I've read most of this but some it was not clear until we discussed. >> >> Updated with WLM: >> >> On 12/17/2015

Re: [GENERAL] - PostgreSQL Replication Types

2015-12-17 Thread Adrian Klaver
On 12/17/2015 07:56 AM, Will McCormick wrote: Thanks a ton for the prompt response. I've read most of this but some it was not clear until we discussed. See here for more detail: WLM: Reading now :) While reading I would suggest having the postgres.conf files on the master and the stan

Re: [GENERAL] - PostgreSQL Replication Types

2015-12-17 Thread Will McCormick
Almost forgot this: SELECT pg_current_xlog_location(); ERROR: recovery is in progress HINT: WAL control functions cannot be executed during recovery. bms=> SELECT pg_current_xlog_location(); ERROR: recovery is in progress HINT: WAL control functions cannot be executed during recovery.

Re: [GENERAL] - PostgreSQL Replication Types

2015-12-17 Thread Adrian Klaver
On 12/17/2015 08:43 AM, Will McCormick wrote: Almost forgot this: SELECT pg_current_xlog_location(); I was not paying attention earlier that should be: pg_last_xlog_receive_location() from: http://www.postgresql.org/docs/9.1/interactive/functions-admin.html Table 9-58. Recovery I

Re: [GENERAL] Index contains unexpected zero page at block

2015-12-17 Thread Merlin Moncure
On Wed, Dec 16, 2015 at 9:48 PM, Victor Blomqvist wrote: > From time to time I get this and similar errors in my Postgres log file: > > < 2015-12-17 07:45:05.976 CST >ERROR: index > "user_pictures_picture_dhash_idx" contains unexpected zero page at block > 123780 > < 2015-12-17 07:45:05.976 CST >

Re: [GENERAL] Error promoting slave on cascading replication using replication slots

2015-12-17 Thread Andreas Kretschmer
Alvaro Melo wrote: > > I found a instruction to add the following line to recovery.conf: > recovery_target_timeline = 'latest' > > When this line is added, slave2 keeps its replication with slave 1: > 2015-12-17 13:37:54 BRST [868-2] LOG: replication terminated by primary > server > 2015-12-17