Re: COPY FREEZE and PD_ALL_VISIBLE

Поиск
Список
Период
Сортировка
Искать
От
Amit Kapila
Тема
Re: COPY FREEZE and PD_ALL_VISIBLE
Дата
Msg-id
CAA4eK1L1bCiOjYxWDP7_8+_wUE+BYrQFhYNbAEGXWEJe17n1zQ@mail.gmail.com
Ответ на
Список
Дерево обсуждения
COPY FREEZE and PD_ALL_VISIBLE Jeff Janes <jeff.janes@gmail.com>
Re: COPY FREEZE and PD_ALL_VISIBLE Robert Haas <robertmhaas@gmail.com>
Re: COPY FREEZE and PD_ALL_VISIBLE Jeff Janes <jeff.janes@gmail.com>
Re: COPY FREEZE and PD_ALL_VISIBLE Robert Haas <robertmhaas@gmail.com>
Re: COPY FREEZE and PD_ALL_VISIBLE Amit Kapila <amit.kapila16@gmail.com>
Re: COPY FREEZE and PD_ALL_VISIBLE Simon Riggs <simon@2ndQuadrant.com>
Re: COPY FREEZE and PD_ALL_VISIBLE Amit Kapila <amit.kapila16@gmail.com>
Re: COPY FREEZE and PD_ALL_VISIBLE Simon Riggs <simon@2ndQuadrant.com>
Re: COPY FREEZE and PD_ALL_VISIBLE Amit Kapila <amit.kapila16@gmail.com>
Re: COPY FREEZE and PD_ALL_VISIBLE Michael Paquier <michael.paquier@gmail.com>
Re: COPY FREEZE and PD_ALL_VISIBLE Jeff Janes <jeff.janes@gmail.com>
Re: COPY FREEZE and PD_ALL_VISIBLE Jeff Janes <jeff.janes@gmail.com>
Re: [HACKERS] COPY FREEZE and PD_ALL_VISIBLE Darafei "Komяpa" Praliaskouski <me@komzpa.net>
Re: [HACKERS] COPY FREEZE and PD_ALL_VISIBLE Pavan Deolasee <pavan.deolasee@gmail.com>
Re: COPY FREEZE and PD_ALL_VISIBLE Simon Riggs <simon@2ndQuadrant.com>
On Fri, Oct 23, 2015 at 6:29 AM, Simon Riggs <simon@2ndquadrant.com> wrote:
On 21 October 2015 at 13:31, Jeff Janes <jeff.janes@gmail.com> wrote:

Index-only scans will visit the heap for each tuple until the first VACUUM is done.

The first vacuum will read the entire table, but not need to write it anymore.  And will create the _vm file.

I think we really want to create _vm file as well as set PD_ALL_VISIBLE, but I don't know the best way to do that.  Set a flag somewhere and then create it in bulk at the end of the transaction?  Set it bit by bit as the pages are extended and initialized?

Easy enough to do it at the end of the COPY FREEZE in one step.

Here, we might want to consider that setting bit in visibility map
will generate WAL log whereas Copy Freeze otherwise skip WAL
when wal_level is less than archive.  This can lead to extra disk
writes which can slow down Copy Freeze, but OTOH that might
be acceptable.


With Regards,
Amit Kapila.
EnterpriseDB: http://www.enterprisedb.com
В списке pgsql-hackers по дате отправления
От: Robert Haas
Дата:
От: Merlin Moncure
Дата:
FAQ