Starting Solr with SSL system properties

In order to enable SSL, there are some system properties that you have to turn on. These properties can be found in SOLR_HOME/bin/solr.in.cmd in Windows and SOLR_HOME/bin/solr.in.sh in Unix-based systems.

When you open the file, you will see a set of properties intended for SSL, as highlighted here:

As highlighted, there is a section of properties that are related to SSL and they are commented.

Uncomment the lines:

set SOLR_SSL_ENABLED=true
set SOLR_SSL_KEY_STORE=E:/book/solr/solr-7.2.0/keys/mysolrkeystore.jks
set SOLR_SSL_KEY_STORE_PASSWORD=solrpass
set SOLR_SSL_KEY_STORE_TYPE=JKS
set SOLR_SSL_TRUST_STORE=E:/book/solr/solr-7.2.0/keys/mysolrkeystore.jks
set SOLR_SSL_TRUST_STORE_PASSWORD=solrpass
set SOLR_SSL_TRUST_STORE_TYPE=JKS
set SOLR_SSL_NEED_CLIENT_AUTH=false
set SOLR_SSL_WANT_CLIENT_AUTH=false

Make sure you have changed the keystore path and password as per your configuration.

Once you have done the preceding changes, start Solr using the following command:

solr -p 8984 -Dsolr.ssl.checkPeerName=false

Once the Solr server is up, navigate to the browser and run the following URL:

https://localhost:8984/solr/#/

Since it is a self-signed certificate, you may get a message to accept the certificate and continue. Once you continue, you will see the Solr home page:

Note that you still have a cross mark on https since it is a self-signed certificate; it will not have such errors if you are using a proper certificate from GoDaddy or Verisign.

In order to check whether the details of the certificate are the same as you created, click on F12 to open developer tools if you are using a Chrome browser:

As shown, click on the Security tab and then on the View Certificate option, which will open a dialog box. Navigate to the Details tab and you will see all the details of the certificate that you have created.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.224.62.6