Re: Auto-tuning work_mem and maintenance_work_mem

From: "Joshua D(dot) Drake" <jd(at)commandprompt(dot)com>
To: Bruce Momjian <bruce(at)momjian(dot)us>, Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
Cc: Andres Freund <andres(at)2ndquadrant(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>, Josh Berkus <josh(at)agliodbs(dot)com>
Subject: Re: Auto-tuning work_mem and maintenance_work_mem
Date: 2013-10-09 17:02:12
Message-ID: 52558C14.2000704@commandprompt.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


On 10/09/2013 07:58 AM, Bruce Momjian wrote:

>> But it still is an independent parameter. I am just changing the default.
>>
>>> maintenance_work_mem can depend on work_mem ~ work_mem * 1 * max_connection / 4
>>
>> That is kind of hard to do because we would have to figure out if the
>> old maintenance_work_mem was set from a default computation or by the
>> user.
>
> FYI, this auto-tuning is not for us, who understand the parameters and
> how they interact, but for the 90% of our users who would benefit from
> better defaults. It is true that there might now be cases where you
> would need to _reduce_ work_mem from its default, but I think the new
> computed default will be better for most users.
>

Just to step in here as a consultant. Bruce is right on here. Autotuning
has nothing to do with us, it has to do with Rails developers who deploy
PostgreSQL and known nothing of it except what ActiveRecord tells them
(I am not being rude here).

We could argue all day what the best equation is for this, the key is to
pick something reasonable, not perfect.

Joshua D. Drake

--
Command Prompt, Inc. - http://www.commandprompt.com/ 509-416-6579
PostgreSQL Support, Training, Professional Services and Development
High Availability, Oracle Conversion, Postgres-XC, @cmdpromptinc
For my dreams of your image that blossoms
a rose in the deeps of my heart. - W.B. Yeats

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2013-10-09 17:07:12 Re: Auto-tuning work_mem and maintenance_work_mem
Previous Message Pavel Stehule 2013-10-09 16:57:25 Re: Assertions in PL/PgSQL