Re: Should pg 11 use a lot more memory building an spgist index? - Mailing list pgsql-general

From Tom Lane
Subject Re: Should pg 11 use a lot more memory building an spgist index?
Date
Msg-id 25927.1540557847@sss.pgh.pa.us
Whole thread Raw
In response to Re: Should pg 11 use a lot more memory building an spgist index?  (Bruno Wolff III <bruno@wolff.to>)
Responses Re: Should pg 11 use a lot more memory building an spgist index?
Re: Should pg 11 use a lot more memory building an spgist index?
List pgsql-general
Bruno Wolff III <bruno@wolff.to> writes:
>   Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> Hmm, in my hands this produces the same size leak (~28GB) in either v10
>> or v11.  In HEAD, somebody's made it even worse (~43GB).  So this is
>> certainly pretty broken, but I'm not sure why it seems worse to you in
>> v11 than before.

> As a short term work around, could I create the index first and use 
> insert statements, each in their own transaction, to get the table loaded 
> with the index?

Yes; it might also be that you don't even need to break it up into
separate statements.

> Is the issue on Fedora taking very long to build a normal spgist index for 
> network addresses worth pursuing separately, or is it likely to be the same 
> underlying cause?

This issue only applies if it was an exclusion constraint.  If you saw
slowness or bloat with a plain index, that would be worth investigating
separately.

            regards, tom lane


pgsql-general by date:

Previous
From: Andrew Gierth
Date:
Subject: Re: Shell Command within function
Next
From: Thomas Kellerer
Date:
Subject: Different memory allocation strategy in Postgres 11?