Hello Guys,
I am trying to load the VMware snapin, but it throwing an error, code is:
$SnapinLoaded = Get-PSSnapin | Where-Object {$_.name -like "*VMware*"}
If (!$SnapinLoaded) {
try {
Add-PSSnapin VMware.VimAutomation.Core
} catch {
$error = "ERROR: Failed to Add VMware.VimAutomation.Core Snapin! Check installation path!"
throw $error
}
}
Error message is:
19:04:42.953 INFO [Test] ### Command 'Test' in 'POWER_SHELL' ### 19:04:48.681 ERROR [Test] ERROR: Failed to Add VMware.VimAutomation.Core Snapin! Check installation path! 19:04:48.747 ERROR [Test] Failed executing command. Exception: The specified module 'VMware.VimAutomation.Cis.Core' was not loaded because no valid module file was found in any module directory.
PowerCLI version is:
VMware vSphere PowerCLI 6.3 Release 1 build 3737840
Any Help?
THanks,
Sheel