Re: pg_dump: largeobject behavior issues (possible bug)
От | Andrew Gierth |
---|---|
Тема | Re: pg_dump: largeobject behavior issues (possible bug) |
Дата | |
Msg-id | 874mo64omp.fsf@news-spur.riddles.org.uk обсуждение исходный текст |
Ответ на | pg_dump: largeobject behavior issues (possible bug) ("Joshua D. Drake" <jd@commandprompt.com>) |
Ответы |
Re: pg_dump: largeobject behavior issues (possible bug)
|
Список | pgsql-hackers |
>>>>> "Joshua" == Joshua D Drake <jd@commandprompt.com> writes: Joshua> The database dumps fine as long as we don't dump largeJoshua> objects. However, if we try to dump the large objects,FreeBSDJoshua> will kill pg_dump as it will consume all free memory andJoshua> swap. With Andrew's help we were ableto determine theJoshua> following: Joshua> There is a memory cost of about 160 bytes per largeobject. I may have the exact number here wrong, it was just a quick eyeball of the data structures (and depends on malloc overheads anyway). The relevant code is getBlobs in pg_dump.c, which queries the whole of pg_largeobject_metadata without using a cursor (so the PGresult is already huge thanks to having >100 million rows), and then mallocs a BlobInfo array and populates it from the PGresult, also using pg_strdup for the oid string, owner name, and ACL if any. -- Andrew (irc:RhodiumToad)
В списке pgsql-hackers по дате отправления: