Hi all,
I'm getting the following error when trying to install VMware.PowerCLI on both Windows 2012 R2 and Windows 2016 using Install-Module (Powershell version 5.1):
PS C:\Windows\system32> Install-Module -Name VMware.PowerCLI
PackageManagement\Install-Package : Unable to find dependent module(s) (VMware.VimAutomation.Cis.Core)
At C:\Program Files\WindowsPowerShell\Modules\PowerShellGet\1.0.0.1\PSModule.psm1:1772 char:21
+ ... $null = PackageManagement\Install-Package @PSBoundParameters
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : ObjectNotFound: (VMware.VimAutomation.Cis.Core:String) [Install-Package], Exception
+ FullyQualifiedErrorId : UnableToFindDependencyPackage,Microsoft.PowerShell.PackageManagement.Cmdlets.InstallPack
age
I have tried installing VMware.VimAutomation.Cis.Core directly using Install-Module, and I can do that, but when I then try to install VMware.PowerCLI, I get the same error message. Importing Cis.Core doesn't help either: always the same error message above.
Here is a verbose run of the command:
PS C:\Windows\system32> Install-Module -Name VMware.PowerCLI -Verbose
VERBOSE: Using the provider 'PowerShellGet' for searching packages.
VERBOSE: The -Repository parameter was not specified. PowerShellGet will use all of the registered repositories.
VERBOSE: Getting the provider object for the PackageManagement Provider 'NuGet'.
VERBOSE: The specified Location is 'https://www.powershellgallery.com/api/v2' and PackageManagementProvider is 'NuGet'.
VERBOSE: Searching repository 'https://www.powershellgallery.com/api/v2/FindPackagesById()?id='VMware.PowerCLI'' for
''.
VERBOSE: Total package yield:'1' for the specified package 'VMware.PowerCLI'.
VERBOSE: Performing the operation "Install-Module" on target "Version '11.1.0.11289667' of module 'VMware.PowerCLI'".
Untrusted repository
You are installing the modules from an untrusted repository. If you trust this repository, change its
InstallationPolicy value by running the Set-PSRepository cmdlet. Are you sure you want to install the modules from
'PSGallery'?
[Y] Yes [A] Yes to All [N] No [L] No to All [S] Suspend [?] Help (default is "N"): Y
VERBOSE: The installation scope is specified to be 'AllUsers'.
VERBOSE: The specified module will be installed in 'C:\Program Files\WindowsPowerShell\Modules'.
VERBOSE: The specified Location is 'NuGet' and PackageManagementProvider is 'NuGet'.
VERBOSE: Downloading module 'VMware.PowerCLI' with version '11.1.0.11289667' from the repository
'https://www.powershellgallery.com/api/v2'.
VERBOSE: Searching repository 'https://www.powershellgallery.com/api/v2/FindPackagesById()?id='VMware.PowerCLI'' for
''.
VERBOSE: Package 'VMware.VimAutomation.Sdk' is already installed.
VERBOSE: Package 'VMware.VimAutomation.Common' is already installed.
VERBOSE: Package 'VMware.Vim' is already installed.
VERBOSE: Searching repository
'https://www.powershellgallery.com/api/v2/FindPackagesById()?id='VMware.VimAutomation.Core'' for ''.
VERBOSE: Searching repository
'https://www.powershellgallery.com/api/v2/FindPackagesById()?id='VMware.VimAutomation.Cis.Core'' for ''.
PackageManagement\Install-Package : Unable to find dependent module(s) (VMware.VimAutomation.Cis.Core)
At C:\Program Files\WindowsPowerShell\Modules\PowerShellGet\1.0.0.1\PSModule.psm1:1772 char:21
+ ... $null = PackageManagement\Install-Package @PSBoundParameters
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : ObjectNotFound: (VMware.VimAutomation.Cis.Core:String) [Install-Package], Exception
+ FullyQualifiedErrorId : UnableToFindDependencyPackage,Microsoft.PowerShell.PackageManagement.Cmdlets.InstallPackage
Anyone experience this? Any insight into this error?