LucD wrote:
I assume you are using PowerShell v2.
Which client platform are you using for testing ? 32- or 64-bit ?
I did all my tests on a 32-bit platform.
I'm using PowerShell 2.0:
[vSphere PowerCLI] C:\Scripts> $Host.Version
Major Minor Build Revision
----- ----- ----- --------
2 0 -1 -1
My client is Windows 2003 SP2 32-bit.
I'm having problems with Get-PowerCLIVersion, even though I've confirmed it's 4.1.1 in Windows' Add / Remove Programs (SS attached).
[vSphere PowerCLI] C:\Scripts> Get-PowerCLIVersion
Get-PowerCLIVersion : Object reference not set to an instance of an object.
At line:1 char:20
+ Get-PowerCLIVersion <<<<
+ CategoryInfo : NotSpecified: (:) [Get-PowerCLIVersion], NullRef
erenceException
+ FullyQualifiedErrorId : System.NullReferenceException,VMware.VimAutomati
on.ViCore.Cmdlets.Commands.GetViToolkitVersion
To resolve the above problem, I've tried repairing PowerCLI and uninstalling / installing it.
I'm assuming something is wrong with my client environment, but I'm not sure how to proceed. Do you mind sending me an executable that you've created in your environment for testing?