Re: Out of memory error handling in frontend code

Поиск
Список
Период
Сортировка
От Daniel Gustafsson
Тема Re: Out of memory error handling in frontend code
Дата
Msg-id AA71AFEA-CDBB-4D2B-B9F2-DF4C7520235D@yesql.se
обсуждение исходный текст
Ответ на Out of memory error handling in frontend code  (Frédéric Yhuel <frederic.yhuel@dalibo.com>)
Ответы Re: Out of memory error handling in frontend code  (Frédéric Yhuel <frederic.yhuel@dalibo.com>)
Список pgsql-hackers
> On 28 Sep 2023, at 10:14, Frédéric Yhuel <frederic.yhuel@dalibo.com> wrote:

> After some time, we understood that the 20 million of large objects were responsible for the huge memory usage (more
than10 GB) by pg_dump. 

This sounds like a known issue [0] which has been reported several times, and
one we should get around to fixing sometime.

> I think a more useful error message would help for such cases.

Knowing that this is case that pops up, I agree that we could do better around
the messaging here.

> I haven't try to get the patch ready for review, I know that the format of the messages isn't right, I'd like to know
whatdo you think of the idea, first. 

I don't think adding more details is a bad idea, but it shouldn't require any
knowledge about internals so I think messages like the one below needs to be
reworded to be more helpful.

+    if (loinfo == NULL)
+    {
+        pg_fatal("getLOs: out of memory");
+    }

--
Daniel Gustafsson

[0] https://www.postgresql.org/message-id/7da8823d83a2b66bdd917aa6cb2c5c2619d86011.camel@credativ.de




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

Предыдущее
От: Ranier Vilela
Дата:
Сообщение: Re: Avoid a possible out-of-bounds access (src/backend/optimizer/util/relnode.c)
Следующее
От: Данил Столповских
Дата:
Сообщение: Allow deleting enumerated values from an existing enumerated data type