Re: Why is wal_writer_delay limited to 10s?

From: Clemens Eisserer <linuxhippy(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Why is wal_writer_delay limited to 10s?
Date: 2014-02-02 06:49:55
Message-ID: CAFvQSYS+x2RG0=t2zyjsBTrGG09spGrimqDcMBv7BQm010wNwA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi Peter,

Thanks a lot for your reply.

> What Postgres version? The WAL Writer will hibernate on Postgres 9.2+.
> walwriter.c says:

I am using Postgresql-9.1 shipped with Raspbian (debian for raspberry pi).

> /*
> * Number of do-nothing loops before lengthening the delay time, and the
> * multiplier to apply to WalWriterDelay when we do decide to hibernate.
> * (Perhaps these need to be configurable?)
> */
> #define LOOPS_UNTIL_HIBERNATE 50
> #define HIBERNATE_FACTOR 25

In my case there will always be work at a higher frequency as the
delay time - in the hope to write out multiple transactions with a
single fsync, so the do-nothing case will most likely not happen.

My question on the list was merely to make sure there are no
side-effects when increasing this delay above what seems to be
considered safe limits. However, I still wonder why this parameter is
capped to 10s and whether this restriction could be lifted in future
postgresql versions?

Thanks & regards, Clemens

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Peter Geoghegan 2014-02-02 07:32:22 Re: Why is wal_writer_delay limited to 10s?
Previous Message John R Pierce 2014-02-02 06:24:03 Re: Transparent exchange BDE from Oracle to PostgreSQL