Skip site navigation (1) Skip section navigation (2)

Re: [HACKERS] Streaming replication document improvements

From: Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>
To: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>, pgsql-docs(at)postgresql(dot)org
Subject: Re: [HACKERS] Streaming replication document improvements
Date: 2010-04-01 13:09:32
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-docspgsql-hackers
Fujii Masao wrote:
> On Thu, Apr 1, 2010 at 11:00 AM, Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
>> On Wed, Mar 31, 2010 at 9:58 PM, Fujii Masao <masao(dot)fujii(at)gmail(dot)com> wrote:
>>> You mean that we should change replication connection not to consume
>>> superuser_reserved_connections slots in 9.0?
>> Yes.

I think it's good that walsenders can use the superuser reserved slots,
that way a client that opens max_connections connections can't block out
standby servers from connecting.

> Preventing superuser connections from consuming superuser_reserved_connections
> slots seems strange for me. So I'm leaning toward just removing superuser
> privilege from replication connection again. Thought?

That would be good, but I fear it's a bigger change than we should be
doing at this point.

How about we adjust the backends math a bit:


ReservedBackends = superuser_reserved_connections
MaxBackends = max_connections + autovacuum_max_workers + 1;


ReservedBackends = superuser_reserved_connections + max_wal_senders
MaxBackends = max_connections + autovacuum_max_workers + max_wal_senders + 1

So we implicitly reserve a slot and a superuser reserved slot for each
walsender. Walsenders use the slots reserved for superusers, but if you
set superuser_reserved_connections=3, there's still always at least
three slots available for superuser to log in with psql, even if the
maximum number of walsenders are connected.

  Heikki Linnakangas

In response to


pgsql-docs by date

Next:From: Bruce MomjianDate: 2010-04-01 13:52:57
Subject: Re: confusing archive_command example
Previous:From: Greg SmithDate: 2010-04-01 12:17:37
Subject: Re: confusing archive_command example

pgsql-hackers by date

Next:From: Pavel StehuleDate: 2010-04-01 13:23:00
Subject: patch: preload dictionary new version
Previous:From: Yeb HavingaDate: 2010-04-01 12:52:59
Subject: Re: explain and PARAM_EXEC

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group