3
  1. Republish All Items (Completed with no errors)
  2. Rebuild Indexes Using Control Panel (Completed with no errors)
  3. Inspect Data/indexes directory. (Date modified is from over a month ago)
  4. Verified correct Data Folder.
  5. Cleaned out the History, PublishQueue and EventQueue tables.

Indexing is not working on my QA environment. It is using a backup from PROD which works fine.

We have 1 CM server and 2 CD servers. The indexes are working on the 1 CM server.

enter image description here

Here is the relevent XML from sitecore/contentSearch/configuration/indexes:

<index id="ac_products_master_index" type="Sitecore.ContentSearch.LuceneProvider.LuceneIndex, Sitecore.ContentSearch.LuceneProvider" patch:source="xActiveCommerce.ContentSearch.config">
        <param desc="name">$(id)</param>
        <param desc="folder">$(id)</param>
        <!-- This initializes index property store. Id has to be set to the index id -->
        <param desc="propertyStore" ref="contentSearch/indexConfigurations/databasePropertyStore" param1="$(id)" />
        <configuration ref="contentSearch/indexConfigurations/defaultLuceneIndexConfiguration" />
        <strategies hint="list:AddStrategy">
          <!-- NOTE: order of these is controls the execution order -->
          <strategy ref="contentSearch/indexConfigurations/indexUpdateStrategies/syncMaster" />
          <productCategoryStrategy type="ActiveCommerce.ContentSearch.Maintenance.Strategies.ProductCategorySynchronousStrategy, ActiveCommerce.ContentSearch">
            <param desc="contentDatabase">master</param>
            <listening hint="list:AddPublishDatabase">
              <web>web</web>
            </listening>
          </productCategoryStrategy>
          <variableProductStrategy type="ActiveCommerce.ContentSearch.Maintenance.Strategies.VariableProductSynchronousStrategy, ActiveCommerce.ContentSearch">
            <param desc="contentDatabase">master</param>
          </variableProductStrategy>
        </strategies>
        <commitPolicyExecutor type="Sitecore.ContentSearch.CommitPolicyExecutor, Sitecore.ContentSearch">
          <policies hint="list:AddCommitPolicy">
            <policy type="Sitecore.ContentSearch.TimeIntervalCommitPolicy, Sitecore.ContentSearch" />
          </policies>
        </commitPolicyExecutor>
        <locations hint="list:AddCrawler">
          <crawler type="ActiveCommerce.ContentSearch.Crawlers.ProductCrawler, ActiveCommerce.ContentSearch">
            <Database>master</Database>
            <Root>/sitecore/commerce/products</Root>
          </crawler>
        </locations>
      </index>
      <index id="ac_products_web_index" patch:source="xActiveCommerce.ContentSearch.config" type="Sitecore.ContentSearch.LuceneProvider.SwitchOnRebuildLuceneIndex,Sitecore.ContentSearch.LuceneProvider">
        <param desc="name">$(id)</param>
        <param desc="folder">$(id)</param>
        <!-- This initializes index property store. Id has to be set to the index id -->
        <param desc="propertyStore" ref="contentSearch/indexConfigurations/databasePropertyStore" param1="$(id)" />
        <configuration ref="contentSearch/indexConfigurations/defaultLuceneIndexConfiguration" />
        <strategies hint="list:AddStrategy">
          <!-- NOTE: order of these is controls the execution order -->
          <strategy ref="contentSearch/indexConfigurations/indexUpdateStrategies/onPublishEndAsync" />
          <prodCatOnPublishEndAsync type="ActiveCommerce.ContentSearch.Maintenance.Strategies.ProductCategoryOnPublishEndStrategy, ActiveCommerce.ContentSearch">
            <param desc="database">web</param>
          </prodCatOnPublishEndAsync>
          <variableProdOnPublishEndAsync type="ActiveCommerce.ContentSearch.Maintenance.Strategies.VariableProductOnPublishEndStrategy, ActiveCommerce.ContentSearch">
            <param desc="database">web</param>
          </variableProdOnPublishEndAsync>
        </strategies>
        <commitPolicyExecutor type="Sitecore.ContentSearch.CommitPolicyExecutor, Sitecore.ContentSearch">
          <policies hint="list:AddCommitPolicy">
            <policy type="Sitecore.ContentSearch.TimeIntervalCommitPolicy, Sitecore.ContentSearch" />
          </policies>
        </commitPolicyExecutor>
        <locations hint="list:AddCrawler">
          <crawler type="ActiveCommerce.ContentSearch.Crawlers.ProductCrawler, ActiveCommerce.ContentSearch">
            <Database>web</Database>
            <Root>/sitecore/commerce/products</Root>
          </crawler>
        </locations>
      </index>

Here is the remoteRebuild key:

<remoteRebuild type="Sitecore.ContentSearch.Maintenance.Strategies.RemoteRebuildStrategy, Sitecore.ContentSearch" />

EDIT:

After adding XML keys for a remoteRebuild strategy. It seems like CD2 is getting indexed, but CD1 is not. The following error is showing in the CD1 logs:

9796 2016:11:17 20:03:45 FATAL [Index=ac_products_web_index] RemoteRebuildStrategy skipped. Full Rebuild was not detected.

The next thing I tried was rebuilding the index from the developer tab. And, CD1 was successfully indexed. (http://www.bv02.com/rebuilding-the-search-index-on-remote-servers-with-sitecore-7/) It seems that a full rebuild is not initiated from the control panel, but it is initiated from the developer tab.

  • And how do you know it's not working? Checked with Luke? Used search? Have you checked last modified date of the files? – Marek Musielak Nov 17 '16 at 15:54
  • No products are showing up in the store. Everything works on PROD. This is my QA environment. – ADH Nov 17 '16 at 15:55
  • Also, indexes directory items have not been changed for over a month. – ADH Nov 17 '16 at 15:56
  • 1
    What is your strategy on the indexes? RemoteBuild? – Chris Auer Nov 17 '16 at 16:03
  • 3
    Guys - this is starting to get into a conversation about the problem, if you want to have a conversation to diagnose the problem, it's better to do that on Slack or the SSE chat room - once you have worked out the answer, someone can then post it here for everyones benefit. – Richard Seal Nov 17 '16 at 16:19
4

You need to use

<strategy ref="contentSearch/indexConfigurations/indexUpdateStrategies/remoteRebuild" />

strategy after your

<strategy ref="contentSearch/indexConfigurations/indexUpdateStrategies/onPublishEndAsync" />

It is needed if you have separated CM and CD servers. Because you do the pulbish on CM and it does not know about these by default. You need to also add this strategy to your CD servers.

  • What do I do after this change? For example, do I simply Rebuild the indexes? Maybe I have to republish all? – ADH Nov 17 '16 at 18:27
  • @ADH To rebuild the indexes should be enough. – Tamás Tárnok Nov 17 '16 at 18:29
  • Okay, I made this update on CM, CD1 and CD2 and then rebuilt the indexes. On CD1, there are no changes to the indexes folders. They still indicate 10/17/2016 for Date Modified. But, on CD2 the Date Modified changed to 11/10/2016. Also, on CD2 the indexes directory named "ac_products_web_index_sec", seems to have everything fixed. There are many new files all with Date Modified equal to 11/17/2016. – ADH Nov 17 '16 at 18:34
  • Check here the Sitecore documentation - doc.sitecore.net/sitecore_experience_platform/…. I would check the configs on CM1 again. – Tamás Tárnok Nov 17 '16 at 19:05
  • I double checked CD1 and CM using Sitecore ConfigBuilder, they are both correct. I also gave the Everyone account full rights to the Data directory. – ADH Nov 17 '16 at 19:24
1

You question is more focused on the indexing occurring rather than the strategy used. I believe this issue is best addressed by the configuration outlined in Content delivery setup - Lucene indexes.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.