Re: curious postgres (crash) recovery behavior

Поиск
Список
Период
Сортировка
От Rébeli-Szabó Tamás
Тема Re: curious postgres (crash) recovery behavior
Дата
Msg-id c32c6f19-86fc-3066-6c5d-de5396c00aff@rblst.info
обсуждение исходный текст
Ответ на curious postgres (crash) recovery behavior  ("Zwettler Markus (OIZ)" <Markus.Zwettler@zuerich.ch>)
Список pgsql-general
I think your log shows a continued archive recovery (PITR), not a crash 
recovery.


For a crash recovery (automatic recovery), you would see something like 
this in the server log:

LOG:  database system was interrupted; last known up at 2022-12-23 
20:50:13 CET
LOG:  database system was not properly shut down; automatic recovery in 
progress

In your case, the server started in archive recovery mode (standby mode) 
again, restored archived WAL, and recovered the cluster from it.

You must have set the recovery_target_action parameter to 'promote' 
(probably via pgbackrest's --target-action parameter), because the 
server started in production mode (read-write mode) after a successful 
archive recovery.

The server started in standby mode again because the recovery had not 
completed, so the standby.signal file had not been deleted from the data 
directory.

The server knew that it was an interrupted recovery by looking at the 
database cluster state in the control file ("in archive recovery" 
instead of "shutdown in recovery").




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

Предыдущее
От: Rébeli-Szabó Tamás
Дата:
Сообщение: Re: REINDEX vs VACUUM
Следующее
От: Rob Sargent
Дата:
Сообщение: Re: What is the best setup for distributed and fault-tolerant PG database?