Search code examples
crm

How to re-configure the vip_public in crm?


In the previous, I configured a wrong IP in the crm:

crm(live)configure# primitive vip_public ocf:heartbeat:IPaddr2 params ip="45.117.40.168.168" cidr_netmask="24" nic=eno50332184 op monitor interval="30s"
crm(live)configure# primitive vip_management ocf:heartbeat:IPaddr2 params ip="10.10.0.168" cidr_netmask="24" nic=eno33554960 op monitor interval="30s"
crm(live)configure# commit
crm(live)configure# cd ..
crm(live)# status
Last updated: Sun Jul 23 19:41:36 2017      Last change: Sun Jul 23 19:41:33 2017 by root via cibadmin on ha-node1
Stack: corosync
Current DC: ha-node3 (version 1.1.13-10.el7-44eb2dd) - partition with quorum
3 nodes and 2 resources configured

Online: [ ha-node1 ha-node2 ha-node3 ]

Full list of resources:

 vip_public (ocf::heartbeat:IPaddr2):   Stopped
 vip_management (ocf::heartbeat:IPaddr2):   Started ha-node2

Failed Actions:
* vip_public_start_0 on ha-node1 'not configured' (6): call=10, status=complete, exitreason='[findif] failed',
    last-rc-change='Sun Jul 23 19:41:34 2017', queued=0ms, exec=282ms

So I want to re-configure the vip_public in the crm:

crm(live)# configure
crm(live)configure# primitive vip_public ocf:heartbeat:IPaddr2 params ip="45.117.40.168" cidr_n

But I get the error:

ERROR: Cannot create primitive with ID 'vip_public': Found existing primitive with same ID.

How to resolve it?


Solution

  • In the end, I get the method:

    In the , I use show command to show the configuration file. and I can use edit to edit my configuration.

    enter image description here

    And at the end, use commit command to commit the configuration.