Re: New trigger option of pg_standby
От | Heikki Linnakangas |
---|---|
Тема | Re: New trigger option of pg_standby |
Дата | |
Msg-id | 49EE1E3F.9050307@enterprisedb.com обсуждение исходный текст |
Ответ на | Re: New trigger option of pg_standby (Fujii Masao <masao.fujii@gmail.com>) |
Ответы |
Re: New trigger option of pg_standby
|
Список | pgsql-hackers |
Fujii Masao wrote: > Hi, > > On Tue, Apr 14, 2009 at 2:41 PM, Fujii Masao <masao.fujii@gmail.com> wrote: >> I'd like to propose another simple idea; pg_standby deletes the >> trigger file *whenever* the nextWALfile is a timeline history file. >> A timeline history file is restored at the end of recovery, so it's >> guaranteed that the trigger file is deleted whether nextWALfile >> exists or not. >> >> A timeline history file is restored also at the beginning of >> recovery, so the accidentally remaining trigger file is deleted >> in early warm-standby as a side-effect of this idea. > > Here is the revised patch as above. > > If you notice something, please feel free to comment. Ok, looking at this in more detail now. A couple of small things: We mustn't remove the trigger file immediately even in fast mode. As noted elsewhere in this thread, we have the same bug in fast mode where pg_standby gets stuck if you copy WAL files directly into pg_xlog. pg_standby should exit with code 0 only if the file is restore successfully. As the patch stands it also returns 0 when smart failover is done. -- Heikki Linnakangas EnterpriseDB http://www.enterprisedb.com
В списке pgsql-hackers по дате отправления: