Menu

Virtual Geek

Tales from real IT system administrators world and non-production environment

PowerCLI The SSL connection could not be established see inner exception

Recently while working with Vmware PowerCLI on one of my new laptop, when connecting to esxi server and vCenter server with Connect-VIserver command, I was receiving below error.

Connect-VIServer $esxiserver -User $user -Password $password
Connect-VIServer The SSL connection could not be established, see inner exception. 

VMware vSphere vCenter Esxi Connect-viserver powercli ssl connection could not be established powershell inner exception.png

This error is occuring due to vCenter or Esxi isn't configured with valid certificate and has self-signed certificate. To ignore the non-trusted certification error run below command to i.

Set-PowerCLIConfiguration -InvalidCertificateAction:Ignore

Perform operation?
Performing operation 'Update VMware.PowerCLI configuration.'?
[Y] Yes [A] Yes to All [N] No [L] No to All [S] Suspend [?] Help (default is "Y"): Y

Scope     ProxyPolicy     DefaultVIServerMode     InvalidCertificateAction  DisplayDeprecationWarnings  WebOperationTimeout
                                                                                                        Seconds
-----     ----------      -------------------     ------------------------  --------------------------  --------------------
Session   UseSystemProxy  Multiple                Ignore                    Trye                        300
User
AllUsers

VMware vSphere vCenter Esxi Connect-viserver powercli ssl connection could not be established powershell inner exception set-powercliconfiguration invalidcertificateaction.png

After the SSL certificate configuration in PowerCLI is connected to server successfully.

Microsoft Powershell VMware Azure powercli set-powercliconfiguration connect-viserver invalidcertificateaction ignore use systemproxy.png

Useful Articles
How to import default vCenter server appliance VMCA root certificate and refresh CA certificate on ESXi
How to replace default vCenter VMCA certificate with Microsoft CA signed certificate
Managing ESXi SSL certificate properties from vCenter server
Forward vCenter Server Appliance logs to syslog server
VMware vCenter Server 7 Profiles with PowerShell
Configure vCenter 7 Profile from PowerShell GUI

Go Back

Comment

Blog Search

Page Views

8547490

Follow me on Blogarama