Re: increasing the default WAL segment size

From: Magnus Hagander <magnus(at)hagander(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: increasing the default WAL segment size
Date: 2016-08-25 13:34:35
Message-ID: CABUevEyS9T+01zHYZq-JW-2TGggkpjrtVvXPN4QAaQvs815+YA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Aug 25, 2016 at 5:32 AM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:

> Robert Haas <robertmhaas(at)gmail(dot)com> writes:
> > On Wed, Aug 24, 2016 at 10:33 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> >> ... but I think this is just folly. You'd have to do major amounts
> >> of work to keep, eg, slave servers on the same page as the master
> >> about what the segment size is.
>
> > I said an initdb-time parameter, meaning not capable of being changed
> > within the lifetime of the cluster. So I don't see how the slave
> > servers would get out of sync?
>
> The point is that that now becomes something to worry about. I do not
> think I have to exhibit a live bug within five minutes' thought before
> saying that it's a risk area. It's something that we simply have not
> worried about before, and IME that generally means there's some squishy
> things there.
>

If we ignore the possible performance implications (which we shouldn't, of
course, but for the sake of argument), I think having it as a configurable
parameter in initdb would make it *less* of something to worry about.

Because it comes with the cluster during replication. I think it's more
likely that you accidentally end up with two instances compiled with
different values than that you get an issue from this.

That said, I think it also has to be a *very* bad painpoint for somebody to
care about changing it if it requires recompilation. The vast majority of
users run the packaged versions, and they don't want to run anything else.
So you will have whatever the RPMs or the DEBs or installers pick for you.
Anything that is a ./configure-time option,is something we should expect
almost nobody to change.

Changing the default will of course help/hurt those as well. But if we
change the default to something high and say "hey those of you who just run
it on a smaller system should recompile with a different --configure", we
are being *very* user-unfriendly. Or the other way around.

That doesn't mean we shouldn't change the default. We just need to be a lot
more careful about what we change it to if it's ./configure to reset it.

--
Magnus Hagander
Me: http://www.hagander.net/
Work: http://www.redpill-linpro.com/

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Stephen Frost 2016-08-25 13:48:02 Re: increasing the default WAL segment size
Previous Message Robert Haas 2016-08-25 13:33:42 Re: increasing the default WAL segment size