Solr Error - 'The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel.'

I recently had a frustrating problem during the setup of a local Sitecore site. My Solr indexes were all configured correctly, but I was not seeing them in the Sitecore Indexing manager. Checking the logs, I came across this message:
'SolrConnectionException', Message: 'The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel.'

The solution to my problem was that the Solr certificate was not added to my local "Trusted Root Certification Authorities".

Here's how I fixed it.

In the Solr root folder, navigate to "\server\etc". There, you should see a solr-ssl.keystore.p12 file. Double clicking on the file will open the Windows Certificate Import Wizard.

Windows Certificate Import Wizard screenshot

Select "Local Machine", click Next.
Make sure the File name is correct (it should be), click Next.
For password, if you followed the Solr instructions it will be "secret". Type that in. Leave the import options as-is and click Next.

Windows Certificate Import Wizard screenshot
Select "Place all certificates in the following store". In the dropdown, select "Trusted Root Certification Authorities" and click Next.
Click Finish.

Check Sitecore to see if you can see your Solr indexes. If not, recycle your Sitecore app in IIS and check again.

I hope that helps!

Add comment