<div dir="ltr"><strong><pre><font color="#373791">
Hello hackers.
I am struggling to understand why standby.max_connections must be higher than
<a href="http://primary.max_connections.Do">primary.max_connections.Do</a> someone know the reason why?
I know that standby cluster can not start if standby.max_connections
is higher than primary.max_connections.
<a href="http://www.postgresql.org/docs/9.3/static/hot-standby.html"
target="_blank">http://www.postgresql.org/docs/9.3/static/hot-standby.html</a>
-------
The setting of some parameters on the standby will need reconfiguration
if they have been changed on the primary. For these parameters, the value on
the standby must be equal to or greater than the value on the primary. If
these parameters are not set high enough then the standby will refuse to
start.
Higher values can then be supplied and the server restarted to begin
recovery again.
These parameters are:
max_connections
max_prepared_transactions
max_locks_per_transaction
-------
I've also read src/backend/access/transam/xlog.c.
But there are no comments about a reason.
(I cannot find the reason,why standby.max_connections must be higher
than primary.max_connections.)
I think this restriction obstructs making a flexible load balancing.
I'd like to make standby database to use load balancing.Of course
a role of a standby server is different from one of a master server.
So I think it it natural that I want to set standby.max_connections less than
primary.max_connections.
thanks & regards</font></pre></strong></div>