- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Get-deployrule ; Get-deployruleset failing with error vimSessionKey parameter is missing
Hello,
I recently upgraded my vCenter to 7.0.3.00800.
PowerShell Version is 7.2.5
I haven't had to work with Autodeploy in a while, but since the upgrade I am getting the following error after running these commands:
Get-deployrule
Get-deployruleset
Get-DeployRuleSet : 2022-07-27 5:06:19 PM Get-DeployRuleSet vimSessionKey parameter is missing
At line:1 char:1
+ Get-DeployRuleSet
+ ~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Get-DeployRuleSet], VimException
+ FullyQualifiedErrorId : Core_BaseCmdlet_UnknownError,VMware.DeployAutomation.Commands.GetDeployRuleSet
Any ideas on what might be wrong?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I suggest opening an SR.
If GSS claims PowerCLI is not supported without a Developer Support contract, point them to Online Documentation - PowerCLI 12.3.0 User’s Guide - VMware {code}
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks LucD,
Looks like those commands cannot be run from within Powershell 7 Core. They're working in regular PowerShell.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
That's correct, I forgot.
But PS should tell you that this module is not supported.
Which PowerShell and PowerCLI version are you using?
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It turns out it wasn't a version issue after all, whatever the problem was I had to uninstall Powershell and reinstall it, after that I ran the following :
Install-Module -Name VMware.PowerCLI -Force -SkipPublisherCheck -AllowClobber
Only then it started working properly.
Side note: I'm trying to understand what the benefit of PowerShell 7 Core is. I was under the understanding that the whole point of using PowerShell 7 Core was the interoperability, any logic behind the fact that some of the VMware commands aren't supported?
PSVersion 5.1.22000.832
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Some PowerCLI modules are not written by the core PowerCLI Team but by the teams responsible for the product that the module covers. The AutoDeploy module is one of them.
Unfortunately, the AutoDeploy Team doesn't seem to consider PowerCLI a top priority.
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference