Re: segfault of autovacuum process during restore - coredumps included

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: segfault of autovacuum process during restore - coredumps included
Дата
Msg-id 9805.1133189757@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: segfault of autovacuum process during restore - coredumps included  (Alvaro Herrera <alvherre@commandprompt.com>)
Ответы Re: segfault of autovacuum process during restore - coredumps included
Re: segfault of autovacuum process during restore - coredumps included
Список pgsql-bugs
Alvaro Herrera <alvherre@commandprompt.com> writes:
> The attached patch should correct the problem, but I'd like to make sure
> it does ...

Rather than that, I'd suggest just setting ActiveSnapshot
unconditionally after each of the StartTransactionCommand calls in
autovacuum.c, ie make the code look just like vacuum.c:

    /* Begin a transaction for vacuuming this relation */
    StartTransactionCommand();
    /* functions in indexes may want a snapshot set */
    ActiveSnapshot = CopySnapshot(GetTransactionSnapshot());

This seems more future-proof.  The patch as proposed is assuming a whole
lot about where snapshots might or might not get used.

            regards, tom lane

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