当节点联机时,Pacemaker Corosync VIP 进行切换

当节点联机时,Pacemaker Corosync VIP 进行切换

我有一个使用 pacemaker 和 corosync 的 3 个节点集群设置 [具有节点 A、B (VIP)、C]。当我B有意关闭其中一个节点(作为灾难恢复测试)时,该节点AC占用 VIP,但当我在一段时间后重新打开 B 时,VIP 会切换到,B但情况不应该如此。

我希望AC保留 VIP,以下是我的起搏器配置

configure
primitive baseos-ping-check ocf:pacemaker:ping params host_list="1.2.3.4" multiplier="1000" dampen="0" attempts="2" \
        op start interval="0s" timeout="60s" \
        op monitor interval="2s" timeout="60s" \
        op stop interval="0s" timeout="60s" on-fail="ignore"
primitive baseos-vip-master ocf:heartbeat:IPaddr2 \
        params ip="192.67.23.145" iflabel="MR" cidr_netmask="255.255.255.0" \
        op start interval="0s" \
        op monitor interval="10s" \
        op stop interval="0s"
clone cl_baseos-ping-check baseos-ping-check meta interleave="true"
location loc-vip-master vip-master \
        rule $id="loc-vip-master-rule" $role="master" 100: #uname eq ECS01 \
        rule $id="loc--vip-master-rule-0" $role="master" -inf: not_defined pingd or pingd lte 0
property expected-quorum-votes="1"
property stonith-enabled="false"
property maintenance-mode="false"
property cluster-recheck-interval="5min"
property default-action-timeout="60s"
property pe-error-series-max="500"
property pe-input-series-max="500"
property pe-warn-series-max="500"
property no-quorum-policy="ignore"
property dc-version="1.1.16-94ff4df"
property cluster-infrastructure="corosync"
rsc_defaults resource-stickiness="150"
rsc_defaults migration-threshold="3"
commit
quit

我的 corosync 配置如下:

totem {
    version: 2

    cluster_name: debian


    token: 3000


    token_retransmits_before_loss_const: 10


    clear_node_high_bit: yes

    crypto_cipher: none
    crypto_hash: none

    interface {

        ringnumber: 0
        bindnetaddr: 127.0.0.1
        mcastport: 5405
        ttl: 1
    }
}

logging {
    fileline: off
    to_stderr: no
    to_logfile: no
    to_syslog: yes
    syslog_facility: daemon
    debug: off
    timestamp: on
    logger_subsys {
        subsys: QUORUM
        debug: off
    }
}

quorum {
    provider: corosync_votequorum
    expected_votes: 2
}

有人可以指出我哪里错了吗?

相关内容