Re: Improve shutdown during online backup

Поиск
Список
Период
Сортировка
От Heikki Linnakangas
Тема Re: Improve shutdown during online backup
Дата
Msg-id 47FA3005.5070108@enterprisedb.com
обсуждение исходный текст
Ответ на Re: Improve shutdown during online backup  ("Albe Laurenz" <laurenz.albe@wien.gv.at>)
Ответы Re: Improve shutdown during online backup  ("Albe Laurenz" <laurenz.albe@wien.gv.at>)
Список pgsql-patches
Albe Laurenz wrote:
> Moreover, if Shutdown == SmartShutdown, new connections won't be accepted,
> and nobody can connect and call pg_stop_backup().
> So even if I'd add a check for
> (pmState == PM_WAIT_BACKENDS) && !BackupInProgress() somewhere in the
> ServerLoop(), it wouldn't do much good, because the only way for somebody
> to cancel online backup mode would be to manually remove the file.

Good point.

> So the only reasonable thing to do on smart shutdown during an online
> backup is to have the shutdown request fail, right? The only alternative being
> that a smart shutdown request should interrupt online backup mode.

Or we can add another state, PM_WAIT_BACKUP, before PM_WAIT_BACKENDS,
that allows new connections, and waits until the backup ends.

--
   Heikki Linnakangas
   EnterpriseDB   http://www.enterprisedb.com

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: [HACKERS] Database owner installable modules patch
Следующее
От: "Tom Dunstan"
Дата:
Сообщение: Re: [HACKERS] Database owner installable modules patch