Miguel Ramos <org.postgresql@miguel.ramos.name> writes:
> �s 15:40 de 12-07-2016, Tom Lane escreveu:
>> Unless you're running pg_restore under a really small ulimit, this would
>> seem to suggest some kind of memory leak in pg_restore itself. I wonder
>> how many objects in your dump (how long is "pg_restore -l" output)?
> pg_restore -l | wc gives me:
> 1055 7984 70675
> It looks small to me.
Yeah, the archive TOC is clearly not large enough to cause any problem in
itself. I'm wondering at this point about libpq buffer bloat. We've
fixed a number of problems in that area over the last few years, though
in a quick review of the commit logs I don't see anything that clearly
bears on your problem. (Commit 86888054a92aeca4 is pretty interesting
but applies to mostly-server-to-client data transfer, which is the wrong
direction.) I wonder whether your data is such that loading it would
trigger a bunch of NOTICEs from the server?
Anyway, it would be useful to try running the restore with a more modern
version of pg_restore, to see if that helps.
regards, tom lane