Install a search provider in a scaled solution

Version: 10.5

Sitecore Experience Platform supports Solr as the search provider for both content search and analytics search.

  • In PaaS solutions, you can use Solr, or SolrCloud in Azure.
  • In on-prem solutions, you can use Solr or SolrCloud. In on-premise solutions, the Sitecore Installation Framework requires Solr to deploy.
Note

Support for Lucene was removed in Sitecore Experience Platform 9.3.0.

Support for Azure Search was removed in Sitecore Experience Platform 10.2.0.

For local testing and development, you can set up a self-signed certificate. For more information about creating a self-signed certificate, see the Apache Solr Reference guide.

Install the Solr Certificate

You must install the Solr certificate on the servers that perform the following roles:

  • Content Management

  • xConnect Collection Search

  • xConnect Indexer service – if you install it on a separate server.

    For more information about the xConnect Indexer service role, see the Sitecore documentation.

Note

The new Dedicated Dispatch Server (DDS) role that was introduced in Sitecore Experience Platform 9.0. Update 1 can only be configured on a CM server and therefore requires the Solr certificate.

For more information about configuring a Dedicated Dispatch Server, see the EXM documentation.

Deploy the collections and solution

The SolrCloud deployment configuration templates for SIF deploy the required ConfigSets and collections to remote Zookeeper and SolrCloud installations.

Prerequisites

Before you deploy the ConfigSets and collections to SolrCloud, you must:

  • Locate the Sitecore 10.X.X rev. XXXXXX (WDP XP1 packages).zip package and in the XP1 Configuration files 10.X.X rev. XXXXXX.zip file extract the following configuration files:
    • SolrCloud-SitecoreConfigSets.json 
    • SolrCloud-Sitecore-Collections.json 
    • SolrCloud-XConnect-Collections.json 
    • Solr-SingleDeveloper.json

Install the SolrCloud

To deploy SolrCloud:

  1. In a Powershell command line, go to the folder where you saved the installation configuration files and run the following cmdlet with the appropriate parameters: 

    
    Install-SitecoreConfiguration `
       -Path .\Solr-SingleDeveloper.json `
       -SolrInstallRoot <path to solr binaries, default C:\> `
       -SolrDomain <Solr domain name, default: localhost> `
       -SolrPort <Solr port, default: 8983> `
       -SolrAdminUserName <username for solr admin, default: admin> `
       -SolrAdminPassword <password for solr admin, optional. Random password is generated if left empty> `
    

   -SolrCloud true ```

  1. Password of the admin user will be displayed in log.
  2. Verify that the SolrCloud is deployed with basic authentication enabled.

Install the Sitecore content and the xDB ConfigSets

To deploy the Sitecore content and the xDB ConfigSets to SolrCloud:

  1. In a PowerShell command line, go to the folder where you saved the installation configuration files and run the following cmdlet with the appropriate parameters:

    
    Install-SitecoreConfiguration `
       -Path .\SolrCloud-SitecoreConfigSets.json `
       -SolrInstallRoot <path to solr binaries from step 1, default: c:\> `
       -SolrDomain <zookeeper domain name, default: localhost> `
       -ZookeeperPort <zookeeper port, default: 9983>  `
       -CorePrefix <prefix for configSet names, default: sitecore> `
       -DefaultConfigSetName <config set to use as base, default: _default>
    
  2. Verify that the ConfigSets are deployed to Zookeeper.

Deploy the SolrCloud content collections

To deploy the SolrCloud content collections:

  1. In a PowerShell command line, go to the folder where you saved the installation configuration files and run the following cmdlet with the appropriate parameters:

    
    Install-SitecoreConfiguration `
       -Path .\SolrCloud-Sitecore-Collections.json `
       -SolrDomain <solrcloud domain name, default: localhost> `
       -SolrPort <solrcloud port, default: 8983> `
       -SolrAdminUserName <admin’s username, default: admin> `    
       -SolrAdminPassword <admin’s password, required to be provided, can be taken from installation above> `
       -SolrConnectionUserName <user name used in connection string, default to corePrefix if not provided> `  
       -SolrConnectionPassword <user password used in connection string, default to random generated password if not provided> `   
       -CorePrefix <prefix for collection name, default: sitecore> `
       -NumShards <number of shards for the collection, default: 1> `
       -ReplicationFactor <number of replicas for each shard, default: 1> `
       -AutoCreateFields <automatically add new fields to schema, default: false>
    
    Note

    SolrConnectionUserName and SolrConnectionPassword should be noted to be used in subsequent role’s deployment.

  2. Verify that the following CMS collections are deployed to SolrCloud:

    • <prefix>_core_index 
    • <prefix>_master_index 
    • <prefix>_web_index 
    • <prefix>_marketingdefinitions_master 
    • <prefix>_marketingdefinitions_web 
    • <prefix>_marketing_asset_index_master 
    • <prefix>_marketing_asset_index_web 
    • <prefix>_testing_index 
    • <prefix>_suggested_test_index 
    • <prefix>_fxm_master_index 
    • <prefix>_fxm_web_index 
    • <prefix>_personalization_index 

Deploy the SolrCloud collections for xDB

To deploy the SolrCloud Collections for xDB:

  1. In a PowerShell command line, run the following cmdlet with the appropriate parameters:

    
    Install-SitecoreConfiguration `
       -Path .\SolrCloud-XConnect-Collections.json `
       -SolrDomain <solrcloud domain name, default: localhost> `
       -SolrPort <solrcloud port, default: 8983> `
       -SolrAdminUserName <admin’s username, default: admin> `  
       -SolrAdminPassword <admin’s password, required to be provided, can be taken from installation above> `  
       -SolrConnectionUserName <user name used in connection string, default to corePrefix if not provided> `  
       -SolrConnectionPassword <user password used in connection string, default to random generated password if not provided> ` 
       -CorePrefix <prefix for collection name, default: sitecore> `
       -NumShards <number of shards for the collection, default: 1> `
       -ReplicationFactor <number of replicas for each shard, default: 1> `
       -AutoCreateFields <automatically add new fields to schema, default: false>
    
  2. Verify that the following xDB collections are deployed to SolrCloud:

    • <prefix>_xdb_internal 
    • <prefix>_xdb_rebuild_internal 
  3. Verify that the following xDB aliases are deployed to SolrCloud:

    • <prefix>_xdb 
    • <prefix>_xdb_rebuild 

Deploy Sitecore with SolrCloud

After you have configured SolrCloud, before you install Sitecore XP, you must ensure that the SolrCloud parameter is configured correctly in the connection string.

To install the Sitecore platform with a connection to the newly configured SolrCloud instance, in the SIF deployment script, in the SolrUrl parameter, add the ;solrCloud=true setting.

If you are going to deploy the server roles separately, update the SolrUrl parameter and provide SolrConnectionUserName, SolrConnectionPassword in the following deployment configuration files:

  • xconnect-xp1-collectionsearch.json 
  • sitecore-XP1-cd.json 
  • sitecore-XP1-cm.json 
Note

When you use SolrCloud, you do not need to deploy the sitecore-solr.json and xconnect-solr.json templates.

If you have suggestions for improving this article, let us know!