A summary of dual heartbeat multi-resource group configuration under Corosync cluster

Source: Internet
Author: User

In our daily Corosync configuration, it is only necessary to configure the heartbeat IP in the bindnetaddr in the corosync.conf in the installation of the related packages and add

Service {Name:pacemakerver:0use_mgmtd:1}

You can enable pacemaker and then configure the resource.


1, encountered the first problem, if there is more than one network card used to do heartbeat?

The configuration of the heartbeat IP in corosync.conf totem the interface subkey under the configuration item. Multiple heartbeat network adapter configuration multiple interface, and put Ringnumber plus 1 (the first is 0), but pay attention to totem configuration add rrp_mode:active or passive or start Orosync will error. Acitve Lower latency, but poor performance, passive said not to see the English explanation ... By default, the single heartbeat Rrp_mode is none.

TIPS:RRP is the routing redundancy protocol, we are exposed to more than the keepalived inside the VRRP.


2, a place needs, a VIP, multiple array sharing disk, two independent database instances, start and stop to each other, but all rely on the VIP and array disk.

By default, we use a group to group resources, and start the resource in the order from the top down, and if the intermediate resource stops unexpectedly, the cluster shuts down the following resources and starts from the middle, because a resource cannot exist in multiple resource groups, which of course does not meet the requirements.

WORKAROUND: When the Configure is configured, group the VIP and array into a resource group, using the Order command to define the boot order, namely:

Order Database1-after-group mandatory:group1 database1 order database2-after-group mandatory:group1 Database2

Annotations:

Order: Commands for sequential constraints

database1-after-group# constraint ID

Mandatory: #指定级别 (There are three levels: mandatory: Mandatory, Optional: Optional, Serialize: serialized)

Group1 Database1 #资源名, the order of the writing here is very important.


But this will have a problem, when the standby machine restart Corosync, there will be the situation of looting resources, and then colocation binding constraints on the play.

CRM (Live) configure# colocation database-and-group inf:group1 database1 database2

Annotations:

Colocation: Arrange constraint commands

Database-and-group: #约束名 (ID)

inf:# (possibility, INF means permanent together, can also be numeric)

Group1 database1 Database2 #资源名称


3, the resource default does not start the problem

Configure under direct edite, add after meta under resource configuration

Meta target-role= "Started"


Reference: http://www.it165.net/admin/html/201404/2869.html

This article is from the "Danielqu" blog, make sure to keep this source http://qujunorz.blog.51cto.com/6378776/1733789

A summary of dual heartbeat multi-resource group configuration under Corosync cluster

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.