Hi,
The get-view command I am using is intermittently throwing an exception. I suspect it happens when vm's are being vmotioned around but am not certain. Below is the command which I am running;
$vms_view = get-view -ViewType VirtualMachine -SearchRoot $clu_view.moref -Filter @{"Config.Template"="false"} -property name,config,summary
Unfortunately I cannot find anything relating to the error message it is outputting, below;
Get-View : 2/05/2015 3:51:18 AM Get-View There is an error in XML document (7, 223194). At C:\VMwareClusterReportv5.ps1:55 char:25
+ $vms_view = get-view <<<
+ CategoryInfo : NotSpecified: (:) [Get-View], VimException
+ FullyQualifiedErrorId : Core_BaseCmdlet_UnknownError,VMware.VimAutomation.ViCore.Cmdlets.Commands.DotNetInterop.GetVIView
I am going to see if I can use get-vm instead, which isn't preffered.
PS: Powershell v2 and PowerCLI 5.5 Release 1
From where are you running this ?
From the PowerCLI prompt, from PowerGUI... ?
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Hi LucD, this is run from the PowerCLI prompt. Regards,
Against which vSphere release ?
Can you upgrade to a more recent PowerCLI release ?
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
vSphere 5.0 Build 1300600 You mean try PowerCLI version 6? It's such a simple query I would of thought this would be possible from version 1.
Not necessarily 6, you could also go for 5.8, or even a reinstall of 5.5.
Another option is to try this from a different PC with a fresh PowerCLI installation.
This is such a strange error, I'm wondering if something might be wrong with that specific PowerCLI installation.
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
I have already tried a different machine and the new machine just had a fresh install of PowerCLI 5.5. I can try version 5.8 but I thought it would have come up in the Release notes as a fix...
It's just a wild guess from my side, I can't reproduce the error nor can I remember having seen a solution for it.
Worst case, you can open a SR with VMware for this, PowerCLi is supported.
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference