Re: ERROR: invalid memory alloc request size

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: ERROR: invalid memory alloc request size
Дата
Msg-id 18713.1130422987@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: ERROR: invalid memory alloc request size  (Alvaro Herrera <alvherre@alvh.no-ip.org>)
Ответы Re: ERROR: invalid memory alloc request size  (Martijn van Oosterhout <kleptog@svana.org>)
Re: ERROR: invalid memory alloc request size  (Alvaro Herrera <alvherre@alvh.no-ip.org>)
Список pgsql-hackers
Alvaro Herrera <alvherre@alvh.no-ip.org> writes:
> I think the problem is that CreateMultiXactId calls
> GetNewMultiXactId and then RecordNewMultiXact, and the lock is released
> between the calls.  So one backend could try to read the offset before
> another one had the time to finish writing it.

Ugh, yes, that is clearly a hole :-( even if it turns out not to explain
Matteo's observation.

I don't see any easy way to fix this except by introducing a lot more
locking than is there now --- ie, holding the MultiXactGenLock until the
new mxact's starting offset has been written to disk.  Any better ideas?
        regards, tom lane


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

Предыдущее
От: Matteo Beccati
Дата:
Сообщение: Re: ERROR: invalid memory alloc request size
Следующее
От: Martijn van Oosterhout
Дата:
Сообщение: Re: ERROR: invalid memory alloc request size