VMware Cloud Community
AdamUK
Enthusiast
Enthusiast
Jump to solution

Move-VM - could not find VIContainer error

Hi

Our setup is one vCenter instance with four clusters underneath it

I am trying to use the Move-VM command to automate the vMotion of multiple VMs off an ESX server I want to take down for maintenance but when I run the Move-VM command  below to move the VM "TEST-VM" onto an ESX host called "ESXHOST02":

Move-VM "TEST-VM" -Destination ESXHOST02

I get the following error message:

"Could not find VIContainer with name 'ESXHOST02'

I am already connected to vCenter via the Connect-VIServer command

Any advice please?

Reply
0 Kudos
1 Solution

Accepted Solutions
LucD
Leadership
Leadership
Jump to solution

It looks as if the ESXi node ESXHOST02 can not be found.

Does this return anything?

Get-VMHost -Name ESXHOST02


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

View solution in original post

Reply
0 Kudos
2 Replies
LucD
Leadership
Leadership
Jump to solution

It looks as if the ESXi node ESXHOST02 can not be found.

Does this return anything?

Get-VMHost -Name ESXHOST02


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

Reply
0 Kudos
AdamUK
Enthusiast
Enthusiast
Jump to solution

You pointed me in the right direction, thanks.  The output of "Get-VMHost" showed that the ESX servers name have the DNS FQDN attached so I had to address the ESX server as ESXHOST02.domain.local for example.

Thanks

Reply
0 Kudos