You can change the Cluster Volume Manager (CVM) master manually from one node in the cluster to another node, while the cluster is online. CVM migrates the master node, and reconfigures the cluster.
Symantec recommends that you switch the master when the cluster is not handling Veritas Volume Manager (VxVM) configuration changes or cluster reconfiguration operations. In most cases, CVM aborts the operation to change the master, if CVM detects that any configuration changes are occurring in the VxVM or the cluster. After the master change operation starts reconfiguring the cluster, other commands that require configuration changes will fail until the master switch completes.
See Errors during CVM master switching.
To change the master online, the cluster must be cluster protocol version 100 or greater.
To change the CVM master manually
# vxclustadm nidmap Name CVM Nid CM Nid State sys1 0 0 Joined: Slave sys2 1 1 Joined: Master
# vxdctl -c mode mode: enabled: cluster active - MASTER master: sys2
In this example, the CVM master is sys2.
# vxclustadm setmaster nodename
where nodename specifies the name of the new CVM master.
The following example shows changing the master on a cluster from sys2 to sys1:
# vxclustadm setmaster sys1
# vxclustadm -v nodestate state: cluster member nodeId=0 masterId=0 neighborId=1 members[0]=0xf joiners[0]=0x0 leavers[0]=0x0 members[1]=0x0 joiners[1]=0x0 leavers[1]=0x0 reconfig_seqnum=0x9f9767 vxfen=off state: master switching in progress reconfig: vxconfigd in join
In this example, the state indicates that the master is being changed.
# vxclustadm nidmap Name CVM Nid CM Nid State sys1 0 0 Joined: Master sys2 1 1 Joined: Slave
# vxdctl -c mode mode: enabled: cluster active - MASTER master: sys1
Symantec recommends that you switch the master when the cluster is not handling Veritas Volume Manager (VxVM) or cluster configuration changes.
In most cases, Cluster Volume Manager (CVM) aborts the operation to change the master, if CVM detects any configuration changes in progress. CVM logs the reason for the failure into the system logs. In some cases, the failure is displayed in the vxclustadm setmaster output as follows:
# vxclustadm setmaster sys1 VxVM vxclustadm ERROR V-5-1-15837 Master switching, a reconfiguration or a transaction is in progress. Try again
In some cases, if the master switching operation is interrupted with another reconfiguration operation, the master change fails. In this case, the existing master remains the master of the cluster. After the reconfiguration is complete, reissue the vxclustadm setmaster command to change the master.
If the master switching operation has started the reconfiguration, any command that initiates a configuration change fails with the following error:
Node processing a master-switch request. Retry operation.
If you see this message, retry the command after the master switching has completed.