we are experiencing the CPU Utilisation going to 100% after starting rebuilding the indexing in Sitecore
this is mainly on CM server and we have a different CM,CD and solr server
Loading
we are experiencing the CPU Utilisation going to 100% after starting rebuilding the indexing in Sitecore
this is mainly on CM server and we have a different CM,CD and solr server
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Tuhin PaulPosted Mar 11, 2024, 11:05 AM
C# code snippet that demonstrates how you can monitor CPU utilization using the
PerformanceCounterclass in .NETWe create a
PerformanceCounterobject to monitor CPU usage. We specify the category as "Processor" and the counter name as "% Processor Time" with an instance name of "_Total" to monitor the total CPU usage across all cores.We continuously read the CPU usage every second using the
NextValue()method and display it to the console.We check if the CPU utilization exceeds a certain threshold (e.g., 90% in this example). If it does, we print a message indicating high CPU utilization and suggest further investigation.
We sleep for 1 second before checking the CPU utilization again to avoid excessive CPU usage from the monitoring process itself.
Tuhin PaulPosted Mar 11, 2024, 11:02 AM
Check your Sitecore configuration (e.g., Sitecore.ContentSearch.config) for a setting named ContentSearch.ParallelIndexing.Enabled. Setting it to false can reduce CPU usage but might extend the rebuild time.
example of how you can set
ContentSearch.ParallelIndexing.Enabledtofalsein a Sitecore configuration fileTuhin PaulPosted Mar 11, 2024, 11:01 AM
Sitecore by default attempts to rebuild all configured indexes simultaneously. This can be resource-intensive, especially for large deployments. code snippet (Sitecore.ContentSearch.config) demonstrating the setting that controls this behavior
Rajkiran SwainPosted Mar 31, 2023, 9:03 AM
Check server resources: Ensure that the server has enough resources (CPU, RAM, Disk Space) to handle the reindexing process. If the server is low on resources, consider upgrading the hardware or scaling out.
Check the indexing strategy: Review the indexing strategy and ensure that it is optimized for your Sitecore instance. If you have a large amount of data to index, consider breaking the indexing process into smaller chunks.
Check the Solr configuration: Check the Solr configuration to ensure that it is optimized for your Sitecore instance. Make sure that you have allocated enough memory to Solr and that the JVM settings are configured correctly.
Optimize indexing pipelines: Ensure that your indexing pipelines are optimized for performance. Review the code and try to eliminate any inefficiencies. You can also consider disabling any unnecessary indexing pipelines.
Monitor the process: Monitor the reindexing process and log files for any errors or warnings. You can use Sitecore's built-in logging tools to help diagnose any issues.
If these steps do not resolve the issue, you may need to consider engaging with Sitecore support for further assistance.
Abhishek ChadhaPosted Mar 31, 2023, 8:42 AM
Hi Rajkiran thanks for sharing the insights but the problem is that there is an outage on the server and after that, we are experiencing the HIGH cpu almost 100% on reindexing, and reindexing process time goes down extremely and we can't do anything on the CM in that process so just want to know what needs to be done to go back to the stable state
Rajkiran SwainPosted Mar 31, 2023, 8:27 AM
It is not uncommon for the CPU utilization to go up after starting rebuilding the indexing in Sitecore. This is because the process of rebuilding the index is resource-intensive and requires a lot of processing power. However, if the CPU utilization remains at 100% for an extended period of time, it could indicate that there is an issue with the server or the indexing process.
To troubleshoot this issue, you can start by checking the server logs and monitoring the resource usage (CPU, memory, disk) during the indexing process. You may also want to check if there are any other processes running on the server that could be causing the high CPU utilization.
If the issue persists, you may need to consider scaling up the server or optimizing the indexing process to reduce the resource usage.