Re: [HACKERS] renaming pg_resetxlog to pg_resetwal has broken pg_upgrade.

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: [HACKERS] renaming pg_resetxlog to pg_resetwal has broken pg_upgrade.
Дата
Msg-id CAB7nPqQbvt9v0wwkO5mO877G-qN=V-AynkA=QKDWwhhfg3LgoQ@mail.gmail.com
обсуждение исходный текст
Ответ на [HACKERS] renaming pg_resetxlog to pg_resetwal has broken pg_upgrade.  (Jeff Janes <jeff.janes@gmail.com>)
Ответы Re: [HACKERS] renaming pg_resetxlog to pg_resetwal has broken pg_upgrade.
Список pgsql-hackers
On Tue, Feb 14, 2017 at 9:09 AM, Jeff Janes <jeff.janes@gmail.com> wrote:
> check for "/usr/local/pgsql9_6/bin/pg_resetwal" failed: No such file or
> directory
>
> This looks somewhat complicated to fix.  Should check_bin_dir test the old
> cluster version, and make a deterministic check based on that?  Or just
> check for either spelling, and stash the successful result somewhere?

The fix does not seem that complicated to me. get_bin_version() just
needs pg_ctl to be present, so we could move that in check_bin_dir()
after looking if pg_ctl is in a valid state, and reuse the version of
bin_version to see if the binary version is post-10 or not. Then the
decision making just depends on this value. Please see the patch
attached, this is passing 9.6->10 and check-world.

I have added as well an open item on the wiki.
-- 
Michael

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

Вложения

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

Предыдущее
От: Amit Kapila
Дата:
Сообщение: Re: [HACKERS] Parallel Index Scans
Следующее
От: Andres Freund
Дата:
Сообщение: Re: [HACKERS] PATCH: two slab-like memory allocators