[ClusterLabs] Ubuntu 16.04 - 2 node setup

James Booth james.booth at primarytec.co.uk
Fri Apr 14 21:55:13 CEST 2017


James,

> Hey guys,
>
>
> Apologies for burdening you with my issue, but I'm at my wits' end!
>
>
> I'm trying to set up a 2-node cluster on two Ubuntu 16.04 VMs. I actually had this working earlier, but because I had tweaked a number of different settings (both corosync related and external settings), I reverted my VMs back to an earlier checkpoint to ensure I wasn't just running off a luck 'magic config' and I could replicate my setup... turns out, I can't!
>
>
> The config for nodes is as follows:
>
>
> ```
>
> totem {
>    version: 2
>    cluster_name: swarm
>    transport: udpu
>    interface {
>      ringnumber: 0
>      bindnetaddr: 10.172.0.0
>    }

^^^ Try completely remove interface section

> }
>
> nodelist {
>    node {
>      ring0_addr: 10.172.0.81
>      name: SWARM01

^^^ What name should do?

>      nodeid: 1
>    }
>    node {
>      ring0_addr: 10.172.0.82
>      name: SWARM02
>      nodeid: 2
>    }
> }
>
> quorum {
>    provider: corosync_votequorum
>    two_node: 1
> }
>
> logging {
>    to_logfile: yes
>    to_syslog: yes
>    logfile: /var/log/corosync/corosync.log
>    timestamp: on
> }
> ```
>
>
>
> This time around, when I first run corosync with `systemctl start corosync` it comes up using 127.0.0.1.
>
>
> Apr 12 20:28:37 SWARM01 corosync[6025]:   [TOTEM ] Initializing transmit/receive security (NSS
> Apr 12 20:28:37 SWARM01 corosync[6025]:   [TOTEM ] The network interface [127.0.0.1] is now up
> Apr 12 20:28:37 SWARM01 corosync[6025]:   [QB    ] server name: cmap
> Apr 12 20:28:37 SWARM01 corosync[6025]:   [QB    ] server name: cfg
> Apr 12 20:28:37 SWARM01 corosync[6025]:   [QB    ] server name: cpg
> Apr 12 20:28:37 SWARM01 corosync[6025]:   [QB    ] server name: votequorum
> Apr 12 20:28:37 SWARM01 corosync[6025]:   [QB    ] server name: quorum
> Apr 12 20:28:37 SWARM01 corosync[6025]:   [TOTEM ] A new membership (127.0.0.1:4) was formed.
>
> Results from `sudo corosync-quorumtool`
>
> Quorum information
> ------------------
> Date:             Wed Apr 12 20:31:12 2017
> Quorum provider:  corosync_votequorum
> Nodes:            1
> Node ID:          2130706433
> Ring ID:          4
> Quorate:          No
>
> Votequorum information
> ----------------------
> Expected votes:   2
> Highest expected: 2
> Total votes:      1
> Quorum:           2 Activity blocked
> Flags:
>
> Membership information
> ----------------------
>      Nodeid      Votes Name
> 2130706433          1 localhost (local)

This really shouldn't happen

>
> And results from `sudo corosync-cmapctl | grep members`
> runtime.totem.pg.mrp.srp.members.2130706433.config_version (u64) = 0
> runtime.totem.pg.mrp.srp.members.2130706433.ip (str) = r(0) ip(127.0.0.1)
> runtime.totem.pg.mrp.srp.members.2130706433.join_count (u32) = 1
> runtime.totem.pg.mrp.srp.members.2130706433.status (str) = joined
>
> It's also not using the correct node number (Should be 1 or 2 depending on which node I try it on). Then if I try to restart the service, it just fails and doesn't log anything in /var/log/corosync/corosync.log.

This means corosync.conf is probably ignored.

>
> Apr 12 20:52:01 SWARM01 systemd[1]: Starting Corosync Cluster Engine...
> Apr 12 20:52:01 SWARM01 systemd[1]: corosync.service: Main process exited, code=exited, status=8/n/a
> Apr 12 20:52:01 SWARM01 systemd[1]: Failed to start Corosync Cluster Engine.
> Apr 12 20:52:01 SWARM01 systemd[1]: corosync.service: Unit entered failed state.
> Apr 12 20:52:01 SWARM01 systemd[1]: corosync.service: Failed with result 'exit-code'.
>
> The only way I can get to test this again is by completely removing corosync (apt remove --purge corosync), reinstalling and trying again. I've tried disabling the firewall completely to see if that was interfering, but to me, it's as if corosync isn't respecting my config file this time around?

Yes it looks so.

>
> Any guidance at all would be greatly appreciated!

Can you please attach your config file? Is corosync from ubuntu package
or your own compiled one? can you please try to stop corosync service,
login as root, add "to_stderr: yes" into logging section of config file,
execute "corosync -f" and paste result?

Regards,
   Honza

>
>
>
>
> James Booth
> Senior ICT Technician
> Email: james.booth at primarytec.co.uk<http://lists.clusterlabs.org/mailman/listinfo/users>
> Mobile: +44 07725817464
>
> [http://www.primarytec.co.uk/wp-content/uploads/2016/11/signature.png]
>
> Registered in England. No 04760864. Registered office as above
>
> The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited.
> If you received this in error, please contact the sender and delete the material from any computer.
>
>
>
> _______________________________________________
> Users mailing list: Users at clusterlabs.org<http://lists.clusterlabs.org/mailman/listinfo/users>
> http://lists.clusterlabs.org/mailman/listinfo/users
>
> Project Home: http://www.clusterlabs.org<http://www.clusterlabs.org/>
> Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
> Bugs: http://bugs.clusterlabs.org<http://bugs.clusterlabs.org/>
>





Apologies, but it looks like my membership to the mailing list hasn't succeeded so I'm trying to manually reply by copying the message content from the archives - I hope it works!


The current Corosync version I'm using is '2.3.5' and it's the Ubuntu package. I've just rebuilt both these VMs (Ubuntu 16.04 again) and I'm getting the same issue. I've also tried compiling the latest version but I'm getting held up on the nss requirements.


What do you mean about the 'name'? I saw this on examples online, and my nodes are called `SWARM01` and `SWARM02`.


Nothing at all seems to work after the first corosync run, it's really odd. I've tried `corosync -f` while running as root and `to_stderr: yes` in the config shows nothing. If I `apt remove --purge` it, I might get another run out of it again, but it's baffling me why it only fires the first time, even if it is ignoring the config. I've tried removing the interface segment and running `corosync -t` after every change which shows no output.




Cheers!


James Booth
Senior ICT Technician
Email: james.booth at primarytec.co.uk
Mobile: +44 07725817464

[http://www.primarytec.co.uk/wp-content/uploads/2016/11/signature.png]

Registered in England. No 04760864. Registered office as above

The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited.
If you received this in error, please contact the sender and delete the material from any computer.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.clusterlabs.org/pipermail/users/attachments/20170414/f5cc7b9f/attachment.html>


More information about the Users mailing list