VMware Cloud Community
erki72
Enthusiast
Enthusiast

After cold migration power on VM on a specified Host

Hi

I am currently moving many VMs from Intel to AMD Hardware. 
For this reason I made a script which shut down the VMs and moves them to an AMD host (defined host in script).
There are several AMD hosts in the cluster.
Now I would like to power on the VMs on the defined host which I used for the cold migration.

I am currently trying "start-vm" command. The VM is then started on any new host.

DRS is set on manual.
Deactivate DRS completely? If so, will my rules be retained?

Labels (2)
Tags (2)
Reply
0 Kudos
6 Replies
LucD
Leadership
Leadership

Are you saying that the new AMD ESXi node is in the same cluster as the old Intel ESXi nodes?


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

Reply
0 Kudos
erki72
Enthusiast
Enthusiast

That's right yes.
For this reason, the VM is shutdown and cold migrated to a specified host.
And that's exactly why the VM should be started on exactly the AMD host

Reply
0 Kudos
LucD
Leadership
Leadership

Can you start such a migrated VM on an AMD ESXi node via the Web Client?


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

Reply
0 Kudos
erki72
Enthusiast
Enthusiast

Yes, that is possible without any problems.
DRS asks me for the host and then I can specify the AMD host.

So it's not a problem, but unfortunately a manual process

Reply
0 Kudos
LucD
Leadership
Leadership

The Start-VM doesn't offer the option to specify the ESXi node, but the API method does.

You could try something like

$vmName = 'TestVM'
$esxName = 'MyEsx'

$vm = Get-VM -Name $vmName
$esx = Get-VMHost -Name $esxName

$vm.ExtensionData.PowerOnVM($esx.ExtensionData.MoRef)

 


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

Reply
0 Kudos
erki72
Enthusiast
Enthusiast

Thanks Luc


I will try and report that. Need another maintenance window for migrate further VMs 😉

Tags (1)
Reply
0 Kudos