Re: Online base backup from the hot-standby

Поиск
Список
Период
Сортировка
От Steve Singer
Тема Re: Online base backup from the hot-standby
Дата
Msg-id BLU0-SMTP71E66DDD5D8B47F6DCF4DE8EE20@phx.gbl
обсуждение исходный текст
Ответ на Re: Online base backup from the hot-standby  (Jun Ishiduka <ishizuka.jun@po.ntts.co.jp>)
Ответы Re: Online base backup from the hot-standby
Список pgsql-hackers
On 11-10-11 11:17 AM, Jun Ishiduka wrote: <blockquote cite="mid:201110111518.p9BFIhpk032107@ccmds32.silk.ntts.co.jp"
type="cite"><prewrap="">
 
Done.

Updated patch attached.

</pre></blockquote><br /> I have taken Jun's latest patch and applied it on top of Fujii's most recent patch.  I did
sometesting with the result but nothing theory enough to stumble on any race conditions.<br /><br /> Some testing
notes<br/> ------------------------------<br />  select pg_start_backup('x');<br /> ERROR:  full_page_writes on master
isset invalid at least once since latest checkpoint<br /><br /> I think this error should be rewritten as <br />
ERROR: full_page_writes on master has been off at some point  since latest checkpoint<br /><br /> We should be using
'off'instead of 'invalid' since that is what is what the user sets it to.<br /><br /><br /> I switched
full_page_writes=on, on the master<br /><br /> did a pg_start_backup() on the slave1.<br /><br /> Then I switched
full_page_writes=offon the master, did a reload + checkpoint.<br /><br /> I was able to then do my backup of slave1,
copythe control file, and pg_stop_backup(). <br /> When I did the test slave2 started okay, but is this safe?  Do we
need a warning from pg_stop_backup() that is printed if it is detected that full_page_writes was turned off on the
masterduring the backup period?<br /><br /><br /> Code Notes<br /> ---------------------<br /> *** 6865,6870 ****<br />
---6871,6886 ----<br />       /* Pre-scan prepared transactions to find out the range of XIDs present */<br />      
oldestActiveXID= PrescanPreparedTransactions(NULL, NULL);<br />   <br /> +     /*<br /> +      * The startup updates
FPWin shaerd-memory after REDO. However, it must<br /> +      * perform before writing the WAL of the CHECKPOINT. The
reasonis that<br /> +      * it uses a value of fpw in shared-memory when it writes a WAL of its<br /> +      *
CHECKPOTNT.<br/> +      */<br /><br /> Minor typo above at 'CHECKPOTNT'<br /><br /><br /><br /> If my concern about
fullpage writes being switched to off in the middle of a backup is unfounded then I think this patch is ready for a
committer. They can clean the two editorial changes when they apply the  patches.<br /><br /> If do_pg_stop_backup is
goingto need some logic to recheck the full page write status then an updated patch is required.<br /><br /><br /><br
/><br/><br /><blockquote cite="mid:201110111518.p9BFIhpk032107@ccmds32.silk.ntts.co.jp" type="cite"><pre
wrap="">Regards.

--------------------------------------------
Jun Ishizuka
NTT Software Corporation
TEL:045-317-7018
E-Mail: <a class="moz-txt-link-abbreviated" href="mailto:ishizuka.jun@po.ntts.co.jp">ishizuka.jun@po.ntts.co.jp</a>
--------------------------------------------
</pre> <pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>

</pre></blockquote><br />

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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: Overhead cost of Serializable Snapshot Isolation
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: Overhead cost of Serializable Snapshot Isolation