Morning all,
Am trying to script some vMotions for lots of our VMs that we are moving to a new vSAN cluster. VMs in the same vCenter are fine and complete without any issues. VMs in the other vCenter (same SSO domain behind LB PSC) fail though with the following error:
Move-VM : 01/04/2017 08:52:41 Move-VM The operation for the entity "TSTLDNVET1" failed with the following message: "A general system error occurred: Host not found (authoritative)"
At line:29 char:1
+ Move-VM -vm $drvm -Destination $destcluster -VMotionPriority High -Da ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Move-VM], SystemError
+ FullyQualifiedErrorId : Client20_TaskServiceImpl_CheckServerSideTaskUpdates_OperationFailed,VMware.VimAutomation.ViCore.Cmdlets.Commands.MoveVM
The command I am running (as part of a bigger script block):
elseif($vm.ParentHost -like "drldne*")
{
$drvm = Get-VM $vm.name -Server $SourceVCConn
$targetPort = Get-VDPortGroup -VDSwitch $switch -Name $vm.DestinationPortGroup -Server $TarVCConn
Move-VM -vm $drvm -Destination $destcluster -VMotionPriority High -Datastore $destinationDatastore -PortGroup $targetPort
}
This vmotion works though through the Web Client. Anyone seen this error before? I cannot seem to see anything else in teh detail of it that can tell me why it is breaking.
EDIT: So I purchased "VMware vSphere PowerCLI Reference" second edition and found a script in there for cross vcenter vmotion. Alas I get the same error trying to migrate a vm that migrates fine in the web client.