Scaling Out Coveo for Sitecore with CES Mirrors
Scaling Out Coveo for Sitecore with CES Mirrors
On-Premises only
As your number of search queries goes up, you may want to use mirrors to replicate the content of your Coveo Index and reduce the load on your Coveo Enterprise Search server. A typical use case would be to use the CES Master server specifically for content management while using one or more CES mirror server to answer the front-end content delivery servers.
Step 1: Set Up Your Sitecore and Coveo Infrastructure
To set the mirrors correctly, you need to have set up the following:
-
Note
See the Sitecore documentation on scaling if you want to have more than one CD or CM.
-
The CES Master server (see Setting Up Coveo for Sitecore in a Remote Server Configuration).
Step 2: Set Up the CES Mirrors
Now that you set up the basic infrastructure, you can set up the CES mirrors.
-
Run the same
CES 7.0.XXXXinstaller on your mirror server as you used for the master (see Installing CES Mirror Components). -
Configure the Master Server to synchronize with the mirrors (see Adding a Mirror Server).
Step 3: Install the Search API on the Mirrors
-
If you have not already done it as part of the CES set up, run the Coveo Search API installation package on each CES server (see Installing the Coveo Search API).
Don’t forget to select the This installation is part of a Sitecore Integration option.
Note the random Application Secret Token as you’ll need to use the same token on each mirror.
-
Copy the CES Master Certificates on the mirrors:
-
On your CES Master server, go to
<MASTER_INDEX_DRIVE>:\CES7\Config\Certificates, and copy both thecert-iis.p12and thecert-ca.pemcertificates. -
For each mirror, go to
<MIRROR_INDEX_DRIVE>:\CES7\Config\Certificates, and both certificates in the folder.
-
-
On each CES server, go to
\Program Files\Coveo Search API 8, and openconfig.ymlin a text editor:-
In the
servernode:-
Set the
serverCertificatePathto point to thecert-ca-.pemlocation on your mirror server. -
Set the
clientCertificatePathto point to thecert-iss.p12location on your mirror server.server: uri: https://localhost:52810 serverCertificatePath: <MIRROR_INDEX_DRIVE>:\CES7\Config\cert-ca.pem clientCertificatePath: <MIRROR_INDEX_DRIVE>:\CES7\Config\cert-iis.p12
-
-
In the
applicationnode:-
Change the
secretfor the one you generated when you installed the Search API on the Master. -
Make sure
allowImpersonateistrue.applications: - name: Sample Application secret: [Random Application Secret Token] allowImpersonate: True
-
-
-
On each CES server, open the Windows Services manager and restart the Search API service.
Set Up A Network Load Balancer (Optional)
If you have more than one mirror, you need to add a network load balancer between your Content Delivery servers and the mirrors (see Configuring Coveo Servers in a Network Load-Balancing Cluster). If you only have one mirror to answer the Content Delivery servers, skip this step.
|
|
For load balancing Sitecore servers, see section Horizontal Scaling in Scalability Options. |
Step 4: Modify the Search API Endpoint in Coveo.SearchProvider.Rest.Custom.config
|
|
Note
You have to make sure the following ports are open between your front-end servers and the CES servers:
|
Now that you have set up the whole infrastructure, you need to change the REST Search API endpoints in the configuration file so the search components on your website can communicate with the required resources:
-
On the CD server, in the
App_Config\Include\Coveofolder, open theCoveo.SearchProvider.Rest.Custom.configfile in a text editor:-
In the
coveonode:-
Locate the
<searchApiUri>parameter and replace the line with the following:To set up a direct connection with the CES Mirror<searchApiUri>http://<CES_MIRROR_HOST_NAME>:8080</searchApiUri>OR
-
-
<searchApiUri>http://<LOAD_BALANCER_ADDRESS>:8080</searchApiUri>
-
While you’re in the
coveonode, check if the<applicationSecret>is correctly set.-
Save and close the
Coveo.SearchProvider.Rest.Custom.configfile.-
Repeat the procedure for each CD your infrastructure includes.
-
-