Re: Fwd: Add tablespace tap test to pg_rewind

Поиск
Список
Период
Сортировка
От Shaoqi Bai
Тема Re: Fwd: Add tablespace tap test to pg_rewind
Дата
Msg-id CAGRcZQVAaCm7QFLKDReSP2919tGZd7Z-bdfgiDnM164Sf_EPvQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Fwd: Add tablespace tap test to pg_rewind  (Michael Paquier <michael@paquier.xyz>)
Ответы Re: Fwd: Add tablespace tap test to pg_rewind
Список pgsql-hackers
Thanks, will work on it as you suggested
Add pg_basebackup --T olddir=newdir to support check the consistency of a tablespace created before promotion
Add run_test('remote');

On Mon, Mar 11, 2019 at 6:50 AM Michael Paquier <michael@paquier.xyz> wrote:
On Sat, Mar 09, 2019 at 09:09:24AM +0900, Michael Paquier wrote:
> When working on the first version of pg_rewind for VMware with Heikki,
> tablespace support has been added only after, so what you propose is
> sensible I think.
>
> +# Run the test in both modes.
> +run_test('local');
> Small nit: we should test for the remote mode here as well.

I got to think more about this one a bit more, and I think that it
would be good to also check the consistency of a tablespace created
before promotion.  If you copy the logic from 002_databases.pl, this
is not going to work because the primary and the standby would try to
create the tablespace in the same path, stepping on each other's
toes.  So what you need to do is to create the tablespace on the
primary because creating the standby.  This requires a bit more work
than what you propose here though as you basically need to extend
RewindTest::create_standby so as it is possible to pass extra
arguments to $node_master->backup.  And in this case the extra option
to use is --tablespace-mapping to make sure that the primary and the
standby have the same tablespace, but defined on different paths.
--
Michael

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Andy Fan
Дата:
Сообщение: Re: I have some troubles to run test_shm_mq;
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: Fix volatile vs. pointer confusion