I recently installed Powershell Core om Ubuntu 18.04, and after installing the PowerCLI module. I ran into an error.
The error is not an uncommon one, but on Windows the error message makes a lot more sense, so I just wanted to let you know what this error actually means.
The error you might get when you try to connect to your vCenter server using the connect-viserver is the following:
Connect-VIServer : 9/27/18 10:41:37 AM Connect-VIServer The SSL connection could not be established, see inner exception. At line:1 char:1 + Connect-VIServer <servername> + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : NotSpecified: (:) [Connect-VIServer], ViError + FullyQualifiedErrorId : Client20_ConnectivityServiceImpl_Reconnect_SoapException,VMware.VimAutomation.ViCore.Cmdlets.Commands.ConnectVIServer
The only hint here is “The SSL connection could not be established…”
This actually means that you do not have a valid certificate. And if you want to connect to vCenter without a valid certificate, you have to allow this.
You can either change you vCenter certificate to a trusted one, which is the correct solutions or you can ignore invalid certificates, which circumvents all security, but makes it work right now.
Please comment if this was helpful.
3 thoughts on “VMware PowerCLI on Powershell Core”
Thanks, my company isn’t going to use valid certificates anytime soon.
Build an internal PKI infrastructure. It tightens security and is practically cost free.
sweet thanks. other help was saying it required FQDN with forward/reverse name resolution. So I almost gave up because that would have been a pain in my circumstances.