Re: Auto-tuning work_mem and maintenance_work_mem

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: 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:44:39
Message-ID: 20131009174439.GD22450@momjian.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Oct 9, 2013 at 01:34:21PM -0400, Robert Haas wrote:
> And quite frankly I don't think I really believe the auto-tuning
> formula has much chance of being right in the first place. It's
> generally true that you're going to need to increase work_mem if you
> have more memory and decrease it work_mem if you have more
> connections, but it also depends on a lot of other things, like the
> complexity of the queries being run, whether all of the connection
> slots are actually routinely used, and whether you've really set
> shared_buffers to 25% of your system's total memory, which many people
> do not, especially on Windows. I think we're just going to create the
> false impression that we know what the optimal value is when, in
> reality, that's far from true.

I disagree. There is nothing preventing users from setting their own
values, but I think auto-tuning will be make people who don't change
values more likely to be closer to an optimal values. We can't
auto-tune to a perfect value, but we can auto-tune closer to a perfect
value than a fixed default. Yes, auto-tuned values are going to be
worse for some users, but I believe they will be better for most users.

Having really bad defaults so everyone knows they are bad really isn't
user-friendly because the only people who know they are really bad are
the people who are tuning them already. Again, we need to think of the
typical user, not us.

--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ Everyone has their own god. +

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2013-10-09 17:45:01 Re: Patch for fail-back without fresh backup
Previous Message Robert Haas 2013-10-09 17:34:21 Re: Auto-tuning work_mem and maintenance_work_mem