Pages

04 January, 2022

Sitecore xDB Index Rebuild - Stuck at Finishing stage with 95% completion

In a Sitecore Managed Cloud instance, I started to rebuild the xDB Index. 

  • I opened Kudu console of xxx--xc-search App Service. 
  • Changed folder to "D:\home\site\wwwroot\App_Data\jobs\continuous\IndexWorker". 
  • Ran .\Sitecore.XConnectSearchIndexer.exe -rr (or .\Sitecore.XConnectSearchIndexer.exe -requestrebuild).
After waiting for a long time, I checked the status of the rebuild and it was stuck at the stage "Finishing" with 95% completed. I restarted the rebuild again and same results after several hours. In my local machine, it has completed without any problem. 

To check the status of the rebuild in Sitecore 10, you can run .\Sitecore.XConnectSearchIndexer.exe -rm (or .\Sitecore.XConnectSearchIndexer.exe -rebuildmonitor).

Downloaded the entire application content (D:\home\site\wwwroot\App_Data\jobs\continuous\IndexWorker) and compared it with local setup. I could see a different setting for Solr Writer - MaximumCommitMilliseconds in "IndexWorker\App_data\Config\Sitecore\SearchIndexer\sc.Xdb.Collection.IndexWriter.SOLR.xml". It was 600000 in Managed cloud setup. I changed it to 1000 and started the rebuild. After several hours, it completed successfully. 

If the Sitecore solution depends on Real Time xDB updates, then we should have default value which is 1000 or near to it. Our solution is not dependent on xDB real time updates but we kept it to default to make sure our rebuild process completes. This KB page explains the reason for updating the setting. 

Rebuild stages:

Default

No index rebuild is requested or running.

RebuildRequested

The index rebuild is requested but has not started yet.

Starting

The index rebuild is in the preparation stage.

RebuildingExistingData

The existing xDB collection data is being extracted and re-indexed.

RebuildingIncomingChanges

Data added during the previous stage is being indexed.

Finishing

The post-rebuild steps are being performed.

Finished

The index rebuild activities have finished.

07 December, 2021

Sitecore PowerShell - Get All Sitecore Users With Basic Properties

Saving the handy script to get all the Sitecore Users with basic properties like Is Admin, Is locked out, email address etc. 



07 October, 2021

Sitecore 9, 10 - Experience Editor Slow or Hang in general or for non-English languages?

As part of the Sitecore Upgrade to Sitecore 10.0.1, we faced an issue related to experience editor. When we try to edit the page in experience editor for non-english version of the item, the CM website hangs and then it will just block every other requests. Entire CM instance will be unavailable. 

Troubleshooting:

  1. Checked the Vanilla Sitecore 10.0.1 version and experience editor is working as expected. 
  2. Debugged the solution and found out that Dictionary API (Sitecore.Globalization.Translate.Text) is the root cause for the slowness. 
Solution:
Sitecore has reported a similar issue as a known issue for Sitecore 9.3 onwards and the fix was included in Sitecore 10.1.0. Sitecore article has a fix for version 9.3 in their page

Reached out to Sitecore to get the fix for Sitecore 10.0.1 version. For this version, the hotfix has a set of DLLs and a config file. They are not support DLLs. So we should include this as part of the CI/CD pipeline so that it does not get overwritten next time. 

After applying the fix, the experience editor started to respond for all the other languages as well. 

Reach out to Sitecore if your Sitecore version (9.3 to 10.0.1) has a similar issue on experience editor and they will be providing the hotfix for the particular version. 

blockquote { margin: 0; } blockquote p { padding: 15px; background: #eee; border-radius: 5px; } blockquote p::before { content: '\201C'; } blockquote p::after { content: '\201D'; }