Re: repmgr problem with registering standby - Mailing list pgsql-general

From Jaime Casanova
Subject Re: repmgr problem with registering standby
Date
Msg-id CAJKUy5iCVwM4YBL1vYq1NFh8fugGmkh3ZZKmFxEE-6ysi3_qCg@mail.gmail.com
Whole thread Raw
In response to Re: repmgr problem with registering standby  (Toby Corkindale <toby.corkindale@strategicdata.com.au>)
Responses Re: repmgr problem with registering standby
List pgsql-general
On Wed, Jul 27, 2011 at 7:24 PM, Toby Corkindale
<toby.corkindale@strategicdata.com.au> wrote:
> On 28/07/11 03:47, Jaime Casanova wrote:
>>
>> On Wed, Jul 27, 2011 at 4:36 AM, Toby Corkindale
>> <toby.corkindale@strategicdata.com.au>  wrote:
>>>
>>> So that looks good, but then I try this on the slave:
>>> # repmgr -f /etc/repmgr/validator/repmgr.conf \
>>>  --verbose standby register
>>>
>> can you show the content of /etc/repmgr/validator/repmgr.conf?
>
> cluster=validator
> node=mel-db06
> conninfo='host=10.133.54.1 port=5432 user=repmgr dbname=repmgr'
>

sorry for the delay on this... do you still have this problem?

the node parameter should be an integer value, i don't think that
string should work for you

>>> I can query the database like so though, and it seems like it's all good:
>>> repmgr=# select * from repmgr_validator.repl_nodes;
>>>  id |  cluster  |                       conninfo
>>> ----+-----------+------------------------------------------------------
>>>  0 | validator | host=10.133.54.2 port=5432 user=repmgr dbname=repmgr
>>> (1 row)
>>

if in the standby that string you're using as node value ends up as a
0 then it never asks for the node 0 (it couldn't be the master because
you're just registering as a standby)

so i bet that's the problem, use numbers in the node parameter and
everything will be ok

i will have to add a check against this case in repmgr, though

--
Jaime Casanova         www.2ndQuadrant.com
Professional PostgreSQL: Soporte 24x7 y capacitación

pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: [ADMIN] number of rows in analyze
Next
From: Paul Tilles
Date:
Subject: possible ecpg compatibility problem