allowing wal_level change at run time

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: allowing wal_level change at run time
Date: 2015-08-18 11:59:09
Message-ID: 55D31E0D.8060801@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

In [1], it was discussed to make wal_level changeable at run time
(PGC_SIGHUP), as part of an effort to make replication easier to set up
and/or provide better defaults. I was wondering what it would take to
do that.

I looks like increasing the setting is doable, as long as we WAL-log the
change using existing facilities. I don't understand the hot_standby ->
logical transition, so maybe something else is necessary there.

How would we handle decreases at run time? We can prevent >=archive ->
minimal if archiving is running or there are physical replication slots,
and we can prevent logical -> something less if there are logical
replication slots, but AFAICT, we don't have a way to check whether
anyone currently needs level hot_standby. (Thread [1] originally
proposed to get rid of the archive/hot_standby distinction, which would
help here.) Or we could just let users make their own mess if they want to.

Comments?

[1]
http://www.postgresql.org/message-id/CA+TgmoZLji0tAjoVOPFAPJ8d2e8Q=ZM4ZdTQXSKA3J+z-PNi4A@mail.gmail.com

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Magnus Hagander 2015-08-18 12:04:21 Re: allowing wal_level change at run time
Previous Message Masahiko Sawada 2015-08-18 11:27:24 Re: Freeze avoidance of very large table.