Re: [GENERAL] Re: Is there possibility btree_redo withXLOG_BTREE_DELETE done between standby_redo and the end of backup - Mailing list pgsql-general

From Michael Paquier
Subject Re: [GENERAL] Re: Is there possibility btree_redo withXLOG_BTREE_DELETE done between standby_redo and the end of backup
Date
Msg-id CAB7nPqRwLzPL8c3Q+2vJ=KPEgULZqP9uPfTig4SwUtuZpW8fjw@mail.gmail.com
Whole thread Raw
In response to [GENERAL] Re: Is there possibility btree_redo with XLOG_BTREE_DELETE donebetween standby_redo and the end of backup  (y39chen <yan-jack.chen@nokia.com>)
List pgsql-general
On Thu, May 25, 2017 at 5:23 AM, y39chen <yan-jack.chen@nokia.com> wrote:
> My doubt is Standby is redoing the records in WAL from master. how accept
> connection in standby side while recovering would trigger
> btree_xlog_delete_get_latestRemovedXid() and panic happen.

You should look at the relationship between the code of postmaster.c
dealing with updates of pmState and how the startup process (xlog.c)
lets the postmaster know when it can accept incoming connections. Once
a set of conditions is met, the startup process will let the
postmaster know if it is safe to accept connections on a hot standby.
That's a good study and the code is well-commented, so I let you guess
what are those conditions and how they are met during recovery.
--
Michael


pgsql-general by date:

Previous
From: Achilleas Mantzios
Date:
Subject: Re: [GENERAL] Inheritance and foreign keys
Next
From: Tom Lane
Date:
Subject: Re: [GENERAL] pg_dump 8.3.3 ERROR: invalid page header in block 2264419 of relation "pg_largeobject"