Re: 'replication' keyword on .pgpass (Streaming Replication)

Поиск
Список
Период
Сортировка
От Heikki Linnakangas
Тема Re: 'replication' keyword on .pgpass (Streaming Replication)
Дата
Msg-id 4B45D60D.5030308@enterprisedb.com
обсуждение исходный текст
Ответ на Re: 'replication' keyword on .pgpass (Streaming Replication)  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Tom Lane wrote:
> Fujii Masao <masao.fujii@gmail.com> writes:
>> The attached patch supports new keyword 'replication' on .pgpass file.
>> This keyword is used to specify the password for the standby server to
>> connect to the primary server.
> 
> This strikes me as a completely bad idea.  We need get no farther than
> the point that it assumes nobody can have a database named "replication"
> (although I notice the patch also appears to assume that libpq knows
> internally that the connection is for replication --- I thought we were
> going to avoid libpq changes for SR?)

As the patch stands there's an extra startup packet, similar to
SSLRequest, in the connection handshake. But I think we should get rid
of that too, and just send an extra "replication=on" option along with
username and other options in the startup packet.

(as Fujii pointed out already, you can have a database called
"replication". But you need to quote it in pg_hba.conf, like you need to
quote "all" and "sameuser/group/role".)

--  Heikki Linnakangas EnterpriseDB   http://www.enterprisedb.com


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Pavel Stehule
Дата:
Сообщение: advantage of new vacuum
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: pg_migrator issues