Re: [HACKERS] pg_resetwal is broken if run from v10 against olderversion of PG data directory

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: [HACKERS] pg_resetwal is broken if run from v10 against olderversion of PG data directory
Дата
Msg-id CAB7nPqTVMn=G4nKG0p7TJdt4Y3TqjXQ7w20oiQCNqT7pXFR0Fw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: [HACKERS] pg_resetwal is broken if run from v10 against olderversion of PG data directory  (Amit Kapila <amit.kapila16@gmail.com>)
Список pgsql-hackers
On Mon, May 29, 2017 at 3:19 AM, Amit Kapila <amit.kapila16@gmail.com> wrote:
> I think this happens due to commit
> f82ec32ac30ae7e3ec7c84067192535b2ff8ec0e which renames pg_xlog to
> pg_wal.  It does take care of making some of the modules like
> pg_basebackup to understand both old and new directory structures, but
> not done for all the modules.  I think we should make similar changes
> in pg_resetwal or at the very least update the docs to indicate
> pg_resetwal can give an error if used against pre-10 data directory.

Contrary to pg_basebackup which makes clear in its documentation that
it is compatible with past server versions down to 9.1, pg_resetwal
does not mention such guarantees. And actually, it seems to me that it
is rather unsafe to use it across major versions as the size of
ControlFileData varies across major versions so you can write junk
bytes in the control file by using pg_resetwal from v10 on a 9.6
server.
-- 
Michael



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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: [HACKERS] pg_resetwal is broken if run from v10 against older version of PG data directory
Следующее
От: Christoph Berg
Дата:
Сообщение: Re: [HACKERS] [PATCH] relocation truncated to fit: citus buildfailure on s390x