command:
PowerCLI F:\scripts\PowerCLI\vBlock-XIO> New-VM -Name vCenter.fqdn.org-cloned
-VM vCenter.fqdn.org-cloned -VMhost host.fqdn.org -datastore DS_Main_Shared_01 -DiskStorageFormat Thin -Notes "weekly clone-copy-backup of vCenter"
error message:
New-VM : 14/11/2016 11:23:43 New-VM One or more objects are specified by name. There is no server list explicitly specified, so an attempt was made
to determine a single server by the managed objects passed to the cmdlet as arguments. However the arguments come from more than one server which makes it im
possible to unambiguously select single server.
At line:1 char:7
+ New-VM <<<< -Name vCenter.fqdn.org-cloned -VM vCenter.fqdn.org -VMhost host.fqdn.apmn.org -datastore DS_Main_Shared_01 -DiskStorageFormat Thin -Notes "weekly clone-copy-backup of vCenter"
+ CategoryInfo : InvalidResult: (System.Collecti...1.VIConnection ]:List`1) [New-VM], ViServerConnectionException + FullyQualifiedErrorId : Core_ObnSelector_GetClientListFromCmdletParameters_AmbiguousServer,VMware.VimAutomation.ViCore.Cmdlets.Commands.NewVM
New-VM : 14/11/2016 11:23:44 New-VM One or more objects are specified
by name. There is no server list explicitly specified, so an attempt was made
to determine a single server by the managed objects passed to the cmdlet as ar
guments. However the arguments come from more than one server which makes it im
possible to unambiguously select single server.
At line:1 char:7
+ New-VM <<<< -Name -VM vCenter.fqdn.org -VMhost host.fqdn.org -datastore DS_Main_Shared_01 -DiskStorageFormat Thin -Notes "weekly clone-copy-backup of vCenter"
+ CategoryInfo : InvalidResult: (System.Collecti...1.VIConnection
]:List`1) [New-VM], ViServerConnectionException
+ FullyQualifiedErrorId : Core_ObnSelector_GetClientListFromCmdletParamete
rs_AmbiguousServer,VMware.VimAutomation.ViCore.Cmdlets.Commands.NewVM
New-VM : 14/11/2016 11:23:45 New-VM StorageResource parameter: Could
not find any of the objects specified by name.
At line:1 char:7
blah blah
Notes "weekly clone-copy-backup of vCenter"
+ CategoryInfo : ObjectNotFound: (VMware.VimAutom...ource Datasto
re:RuntimePropertyInfo) [New-VM], ObnRecordProcessingFailedException
+ FullyQualifiedErrorId : Core_ObnSelector_SetNewParameterValue_ObjectNotF
oundCritical,VMware.VimAutomation.ViCore.Cmdlets.Commands.NewVM
I disconnected all VIServer sessions, then did a fresh reconnect before running this command.
Can you please help? points thankfully provided for any help.
cheers
KC
Did you check the contents of $global:defaultviservers after the Disconnect?
Did you try stopping/starting your PowerShell/PowerCLI prompt?
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Did you check the contents of $global:defaultviservers after the Disconnect?
Did you try stopping/starting your PowerShell/PowerCLI prompt?
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Thanks LucD. I knew you'd be the one to sort me out. closed the PowerCLI session and opened a new one and it's working now. Never would have guessed it from the error message. cheers again. You, sir, rock!