Skip to main content

Sitecore Error 'The shard map manager has to be configured.'

Sitecore Error 'The shard map manager has to be configured.'

I installed Sitecore 10.2 XP and after that, I found that on the server CPU utilization was 100% and 
then I checked the logs and I found the below error:

Error:




Sitecore.Framework.Conditions.PostconditionException: Postcondition 'The shard map manager has to be configured.' failed.

   at Sitecore.Framework.Conditions.EnsuresValidator`1.ThrowExceptionCore(String condition, String additionalMessage, ConstraintViolationType type)

   at Sitecore.Framework.Conditions.Throw.ValueShouldBeTrue[T](ConditionValidator`1 validator, String conditionDescription)

   at Sitecore.Xdb.Collection.Data.SqlServer.Configuration.ElasticScaleConnectionManager.InitializeShardMapManager()

   at Sitecore.Xdb.Collection.Data.SqlServer.Configuration.ElasticScaleConnectionManager.get_ShardMapManager()

   at Sitecore.Xdb.Collection.Data.SqlServer.Configuration.ElasticScaleConnectionManager.GetRangeShardMap(String rangeShardMapName)

   at Sitecore.Xdb.Collection.Data.SqlServer.Configuration.ElasticScaleConnectionManager.<>c__DisplayClass33_0.<GetRangeMappings>b__0()

   at System.Lazy`1.CreateValue()

   at System.Lazy`1.LazyInitValue()

   at Sitecore.Xdb.Collection.Data.SqlServer.Configuration.MemoryCacheManager.AddOrGetExistingFromCache[T](String key, Func`1 valueFactory)

Solution

To solve this error I checked Xdb.Collection.ShardMapManager's SQL user and found that password was not correct so I did reset the password and then the error was gone.

Comments