pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Jeff Janes <jeff.janes@gmail.com>
Cc: Clemens Eisserer <linuxhippy@gmail.com>
Cc: Pg Bugs <pgsql-bugs@postgresql.org>
Subject: Re: BUG #9161: wal_writer_delay is limited to 10s
Date: Mon, 17 Feb 2014 16:39:44 -0500
Message-ID: <7090.1392673184@sss.pgh.pa.us> (raw)
In-Reply-To: <CAMkU=1zvJcUzJjztsEeTMqi1mAbZsa7=eXCxC9N3yX_dnLrM-Q@mail.gmail.com>
References: <20140209122404.26449.49425@wrigleys.postgresql.org>
	<15612.1391966046@sss.pgh.pa.us>
	<CAMkU=1zvJcUzJjztsEeTMqi1mAbZsa7=eXCxC9N3yX_dnLrM-Q@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>

Jeff Janes <jeff.janes@gmail.com> writes:
> We seem to be arguing both that making it larger would do absolutely
> nothing, and that making it larger would do something very bad.

The question to me is not so much whether it would do anything bad,
as whether it would do anything good.  I think it's entirely unproven
that merely raising this limit would solve anything for Clemens'
use-case; it seems likely that additional behavioral changes would
be needed, and we've not seen what's under that rock.

What it definitely would do, however, is encourage people to raise
the setting, perhaps to larger values than are good for them.  The
system is currently tuned on the assumption that wal_writer_delay
is a fractional second; we have no data on how it performs with
significantly larger settings.

Also, a closer look shows that the wal writer doesn't write anything
merely because it's woken up.  Unless I'm misreading XLogBackgroundFlush,
it will write only (1) any completed full pages of WAL, or (2) data up
to an async commit.  As for (1), writing out completed pages (which
are not going to get overwritten) doesn't seem like it should be a problem
for a flash drive.  If it is a problem, maybe recompiling with a bigger
XLOG page size is indicated.  As for (2), while I grant Clemens' claim
that he's willing to tolerate loss of async commits, it's a bit hard
to credit that he's willing to lose three hours worth of async commits.
Which is what he'd be risking with wal_writer_delay set to 1h.

There's also the existing "hibernate" mode, which has unclear interactions
with a desire to put off writes for such long intervals.

Basically, this proposal needs a lot more evidence than has been
provided, IMO.

			regards, tom lane


-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs



view thread (15+ messages)  latest in thread

Message-ID: <7090.1392673184@sss.pgh.pa.us>
Permalink:  ../7090.1392673184@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/7090.1392673184@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-bugs@postgresql.org
  Cc: tgl@sss.pgh.pa.us, jeff.janes@gmail.com, linuxhippy@gmail.com
  Subject: Re: BUG #9161: wal_writer_delay is limited to 10s
  In-Reply-To: <7090.1392673184@sss.pgh.pa.us>
  References: <20140209122404.26449.49425@wrigleys.postgresql.org> <15612.1391966046@sss.pgh.pa.us> <CAMkU=1zvJcUzJjztsEeTMqi1mAbZsa7=eXCxC9N3yX_dnLrM-Q@mail.gmail.com> <7090.1392673184@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox