Hi,
is it possible to make an automatic start of a VM when another VM goes off?
Example:
VM1 is on
VM2 is off
if VM1 go off automatically VM2 starts
if VM2 go off automatically VM1 starts
I use vSphere 6.7
No, this is not something that we have as a feature in vSphere. What would be the use case for this?
I'm curious as well as the reason, but you could make a powercli script that ran say every 5 mins and checked the powerstate of the vms and if one is off to and to start the other one if its off. Something like this, I haven't tested this but it should be pretty close to a simple version of what you would need. You would just run this from an external server at a regular interval your happy with.
$vm1=Get-VM vm1
$vm2=Get-VM vm2
if ($vm1.PowerState -eq "PoweredOff") {
Start-VM -VM $vm2
}
if ($vm1.PowerState -eq "PoweredOff") {
Start-VM -VM $vm1
}
or create an alarm definition that triggers a script to start the other vm
Hey, hope you are doing fine.
There is a feature that works similar to what you are asking
Check fault tolerance
What is Fault Tolerance and How it Works? | Vsphere | VMware | LATAM
Please note it only works with up to 8 vCPU in vSphere 6.7 according to licensing:
Do you have HA?
Do you have DRS?
Can you tell a little about the VMs?
Warm regards