This article explains how to change the vSAN (cmmds) leader/master in a vSAN cluster on demand.
VMware vSAN 7.x
VMware vSAN 8.x
To change the vSAN (cmmds) leader in a vSAN cluster forcefully:
esxcli vsan cluster get on a host in the cluster and place it into maintenance mode.vsish -e set /vmkModules/cmmds/forceTransition abdicateMastervsish -e set /vmkModules/cmmds/forceTransition abdicateLeaderesxcli vsan cluster get on the host reveals that a new host is the vSAN leader.Note: This will make the backup node to take over and agent nodes will failover to backup/newLeader without transitioning to the discovery state, and the cluster should not fall apart. The previous master node will still transition to discovery state (because master to agent is not a valid state transition), this is why it should be in maintenance mode to avoid any disruption to any running VMs.