From: | Mark Kirkwood <mark(dot)kirkwood(at)catalyst(dot)net(dot)nz> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | pgsql-bugs(at)postgresql(dot)org |
Subject: | Re: Massive memory use for star query |
Date: | 2011-04-16 07:21:28 |
Message-ID: | 4DA94378.5030600@catalyst.net.nz |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
On 16/04/11 04:43, Tom Lane wrote:
> Mark Kirkwood<mark(dot)kirkwood(at)catalyst(dot)net(dot)nz> writes:
>> I've recently seen examples of star-like queries using vast amounts of
>> memory in one of our production systems. Here's a simplified example
>> using synthetic data (see attached to generate if desired):
>> SET geqo_threshold = 14;
>> SET from_collapse_limit = 14;
>> SET join_collapse_limit = 14;
> Well, if you're going to do the above, you should be expecting the
> planner to eat a lot of memory. There is a reason why the default
> values of those parameters are significantly lower than that ...
>
Ok - so with the settings at their defaults geqo chooses a semi-random
plan, and at least one of those (for the production variant of this
query anyway) eat massive (>100G) amounts of temp space - not really a
suitable outcome either.
I guess you have answered my first question - i.e yes this should eat
massive amount of ram as written - however are you sure there is no
memory leaking going on here?
regards
Mark
From | Date | Subject | |
---|---|---|---|
Next Message | Greg Stark | 2011-04-16 11:08:17 | Re: Massive memory use for star query |
Previous Message | Mark Kirkwood | 2011-04-16 07:17:00 | Re: Massive memory use for star query |