Search Postgresql Archives

Re: Weird error when setting up streaming replication

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Aug 9, 2013 at 9:54 AM, Quentin Hartman
<qhartman@xxxxxxxxxxxxxxxxxxx> wrote:
> OK, figured this out. I had it start copying the pg_xlog directory as well
> when doing the initial sync. I realized this is also the first time I've
> setup replication from scratch using 9.2. All my other 9.2 pairs were setup
> on either 9.0 or 9.1, and have been upgraded from there with replication
> already in place. Previously, and still according to that article in the
> wiki, the pg_xlog directory was specifically excluded.

You exclude the pg_xlog in the rsync so as not to restore them,
because they are not needed and can cause confusion.  But, you don't
want an old copy of pg_xlog from a previous cluster sitting around,
either, which is the case you were having.

By including pg_xlog in the sync, what you were doing is overwriting
the old files from a previous cluster (which are toxic) with ones from
the master, which are useless, but at least not generally toxic.

I think one problem from the wiki is step 3:

3. Edit recovery.conf and postgresql.conf on the standby to start up
replication and hot standby. First, in postgresql.conf, change this
line

It doesn't tell you how you got those files in the first place, in
order to edit them.  You apparently got them from an initdb.  What you
probably want to do instead is get them by copying them from the
master.

> Does anyone know why
> this behavior may have changed?

I don't think it has changed.  I think you are interpretation of the
instructions has changed, so you did something different under 9.0 and
9.1.

Cheers,

Jeff


-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux