Re: [PG_UPGRADE] 9.6 to 10.5

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: [PG_UPGRADE] 9.6 to 10.5
Дата
Msg-id 20180810172329.GA22736@paquier.xyz
обсуждение исходный текст
Ответ на Re: [PG_UPGRADE] 9.6 to 10.5  (Bruce Momjian <bruce@momjian.us>)
Ответы Re: [PG_UPGRADE] 9.6 to 10.5  (Bruce Momjian <bruce@momjian.us>)
Список pgsql-bugs
On Fri, Aug 10, 2018 at 12:53:47PM -0400, Bruce Momjian wrote:
> Oh, good point. I had not tested that.  I can develop a patch to handle
> this.  Was that the case in this upgrade report?

I cannot say if this is the issue reported here for sure, but the OP has
mentioned "clusters", which may point to the fact that he is trying to
upgrade standby(s) as well.

You need visibly a one-liner like that:
--- a/src/bin/pg_upgrade/controldata.c
+++ b/src/bin/pg_upgrade/controldata.c
@@ -150,7 +150,8 @@ get_control_data(ClusterInfo *cluster, bool live_check)
                 /* remove leading spaces */
                 while (*p == ' ')
                     p++;
-                if (strcmp(p, "shut down\n") != 0)
+                if (strcmp(p, "shut down\n") != 0 &&
+                    strcmp(p, "shut down in recovery\n") != 0)
                 {
                     if (cluster == &old_cluster)
                         pg_fatal("The source cluster was not shut down cleanly.\n");

I have not tested it though.
--
Michael

Вложения

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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: [PG_UPGRADE] 9.6 to 10.5
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: [PG_UPGRADE] 9.6 to 10.5