Re: standby recovery fails (tablespace related) (tentative patch and discussion)

From: Asim R P <apraveen(at)pivotal(dot)io>
To: Paul Guo <pguo(at)pivotal(dot)io>, Anastasia Lubennikova <a(dot)lubennikova(at)postgrespro(dot)ru>, Alexandra Wang <leiwang(at)pivotal(dot)io>
Cc: Thomas Munro <thomas(dot)munro(at)gmail(dot)com>, Kyotaro HORIGUCHI <horiguchi(dot)kyotaro(at)lab(dot)ntt(dot)co(dot)jp>, PostgreSQL mailing lists <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: standby recovery fails (tablespace related) (tentative patch and discussion)
Date: 2019-09-20 12:23:56
Message-ID: CANXE4Td1udkoCX5tyBUKiax5r_qFZDwR6iG1Ymm3t2CfW9zTuw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Sep 19, 2019 at 5:29 PM Asim R P <apraveen(at)pivotal(dot)io> wrote:
>
> In order to fix the test failures, we need to distinguish between a
missing database directory and a missing tablespace directory. And also
add logic to forget missing directories during tablespace drop. I am
working on it.

Please find attached a solution that builds on what Paul has propose. A
hash table, similar to the invalid page hash table is used to track missing
directory references. A missing directory may be a tablespace or a
database, based on whether the tablespace is found missing or the source
database is found missing. The crash recovery succeeds if the hash table
is empty at the end.

Asim

Attachment Content-Type Size
v6-0001-Support-node-initialization-from-backup-with-tabl.patch application/octet-stream 2.1 KB
v6-0002-Tests-to-replay-create-database-operation-on-stan.patch application/octet-stream 9.8 KB
v6-0003-Fix-replay-of-create-database-records-on-standby.patch application/octet-stream 12.4 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Jeff Janes 2019-09-20 12:45:34 WAL recycled despite logical replication slot
Previous Message Michael Paquier 2019-09-20 11:58:27 Re: [PATCH] src/test/modules/dummy_index -- way to test reloptions from inside of access method