[ClusterLabs] Pacemaker newbie needs advice for adding a new cluster node

Jan Pokorný jpokorny at redhat.com
Thu Aug 11 12:59:07 UTC 2016


On 11/08/16 13:20 +0200, thl at it-hluchnik.de wrote:
> maybe someone can help me adding a node in my test cluster.
> 
> I have a working three-node test Cluster in my VirtualBox, using
> OEL7.2 and now I try to add another node but I have no plan and I
> did some kind of try & error which does not work.
> 
> [...]
> 
> I setup another host with name knoten04-hb, pcsd is started by
> systemd. My first idea was modifying /etc/corosync/corosync.conf on
> all four hosts, adding the new host.

This "let's do it manually" is more often than not shortsighted, as
there is some expert knowledge wired into the high level management
tools like pcs that is hard to mimic in full scope and in such
a coordinated way if there's not enough experience.

Also note that the tools like pcs may not be bulletproof against
necessarily all modifications behind their backs, which is exactly
what you are doing with your procedure.  On the other hand, it
brings feedback on where they could get more robust in such
unfinished/temporary configuration stages.

> When done, without any stop/start action, pcs shows me this:
> 
> # pcs status
> 
> [...]
> 
> Online: [ knoten01-hb knoten02-hb knoten03-hb ]
> 
> [...]
> 
> PCSD Status shows the new node, everything else is unchanged. I
> guess the corosync part is OK.
> 
> Next step is getting pacemaker configured. I tried:
> 
> # cibadmin --query > add_knoten04-hb_cfg
> # vi add_knoten04-hb_cfg
> # cibadmin --replace --xml-file add_knoten04-hb_cfg
> 
> The only entry I changed was this:
> 
>     <nodes>
>       <node id="1" uname="knoten01-hb"/>
>       <node id="2" uname="knoten02-hb"/>
>       <node id="3" uname="knoten03-hb"/>
>       <node id="4" uname="knoten04-hb"/>        <==============
>     </nodes>
> 
> 
> Again, this looks good:
> 
> # pcs status
> 
> [...]
> 
> Online: [ knoten01-hb knoten02-hb knoten03-hb ]
> OFFLINE: [ knoten04-hb ]
> 
> [...]
> 
> 
> knoten04-hb is known but offline, for sure. OK, let's start it:
> 
> 
> # pcs cluster start knoten04-hb
> knoten04-hb: Starting Cluster...
> 
> The funny thing: pcs status on the old nodes tell me:
> 
> [root at knoten01 ~]# pcs status
> 
> [...]
> 
> Online: [ knoten01-hb knoten02-hb knoten03-hb ]
> OFFLINE: [ knoten04-hb ]
> 
> [...]
> 
> 
> And pcs on the new node tells me that:
> 
> [root at knoten04 ~]# pcs status
> 
> [...]
> 
> Online: [ knoten04-hb ]
> OFFLINE: [ knoten01-hb knoten02-hb knoten03-hb ]
>   pcsd: active/enabled
> 
> [...]
> 
> This is obviously no valid cluster. So what am I doing wrong? How to
> add the node, getting a working four-node cluster?

# pcs cluster node add --help

It should take care of everything you really need, incl. corosync
configuration reload, etc.

-- 
Jan (Poki)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.clusterlabs.org/pipermail/users/attachments/20160811/1b93052f/attachment-0002.sig>


More information about the Users mailing list