Auto change protocol to C and allow-two-primary for vm-migrate
This commit is contained in:
parent
128f8dc9a6
commit
d2bcb7c337
|
@ -17,8 +17,10 @@ slaveKVMIP="${slaveKVMIP:-}"
|
|||
|
||||
ssh "${slaveKVMIP}" virsh exit || error "Cannot connect to libvirt on ${slaveKVMIP} !"
|
||||
|
||||
drbdadm net-options --protocol=C --allow-two-primaries "${vmname}"
|
||||
ssh "${slaveKVMIP}" drbdadm primary "${vmname}"
|
||||
virsh migrate --live --unsafe --verbose "${vmname}" "qemu+ssh://${slaveKVMIP}/system" "tcp://${slaveKVMIP}/"
|
||||
virsh dumpxml "${vmname}" | ssh "${slaveKVMIP}" virsh define /dev/stdin
|
||||
virsh undefine "${vmname}"
|
||||
drbdadm secondary "${vmname}"
|
||||
drbdadm adjust "${vmname}"
|
||||
|
|
Loading…
Reference in New Issue