I am getting this error when trying to rebuild my master index in Solr:

Job started: Index_Update_IndexName=sitecore_master_index_solr|#Exception: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.IO.IOException: Unable to write data to the transport connection: An established connection was aborted by the software in your host machine. ---> System.Net.Sockets.SocketException: An established connection was aborted by the software in your host machine
at System.Net.Sockets.NetworkStream.Write(Byte[] buffer, Int32 offset, Int32 size)
--- End of inner exception stack trace ---
at System.Net.Sockets.NetworkStream.Write(Byte[] buffer, Int32 offset, Int32 size)
at System.Net.ConnectStream.InternalWrite(Boolean async, Byte[] buffer, Int32 offset, Int32 size, AsyncCallback callback, Object state)
at System.Net.ConnectStream.Write(Byte[] buffer, Int32 offset, Int32 size)
at SolrNet.Impl.SolrConnection.CopyTo(Stream input, Stream output)
at SolrNet.Impl.SolrConnection.PostStream(String relativeUrl, String contentType, Stream content, IEnumerable`1 parameters)
at SolrNet.Impl.SolrConnection.Post(String relativeUrl, String s)
at SolrNet.Impl.SolrBasicServer`1.SendAndParseHeader(ISolrCommand cmd)
at Sitecore.ContentSearch.SolrProvider.SolrBatchUpdateContext.AddRange(IEnumerable`1 group, Int32 groupSize)
at Sitecore.ContentSearch.SolrProvider.SolrBatchUpdateContext.Commit()
at Sitecore.ContentSearch.SolrProvider.SolrSearchIndex.PerformRebuild(Boolean resetIndex, Boolean optimizeOnComplete, IndexingOptions indexingOptions, CancellationToken cancellationToken)
at Sitecore.ContentSearch.SolrProvider.SolrSearchIndex.Rebuild(Boolean resetIndex, Boolean optimizeOnComplete)
--- End of inner exception stack trace ---
at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters)
at (Object , Object[] )
at Sitecore.Pipelines.CorePipeline.Run(PipelineArgs args)
at Sitecore.Jobs.Job.ThreadEntry(Object state)

The Solr logs are showing this error:

org.apache.solr.common.SolrException: ERROR: [doc=sitecore://master/{bfde3d21-3a67-4938-aa90-33da9caf7bf5}?lang=cs-cz&ver=1] unknown field '__display_name_t_cs' 
  • 1
    This looks like the schema.xml doesn't have all of the fields defined. the SOLR log error says that a field isn't defined. I would make sure your your schema.xml is correct. – Pete Navarra Nov 1 '16 at 0:16
  • 1
    After you update your schema.xml in solr, ensure you restart the solr instance, to have the effect of inserted dynamicField. – Sivalingaamorthy Mar 21 '17 at 11:35
up vote 5 down vote accepted

Sitecore stores language-specific text fields in Solr by adding a suffix that corresponds to the locale name. The field for the cs-cz locale is missing in the index schema, so you'll need to add it.

In the schema.xml of every Solr index, insert the following node under <fields>:

<dynamicField name="*_t_cs" type="text_general" indexed="true" stored="true" />

If you have any other languages defined in Sitecore, check that their corresponding locale-specific fields are also mapped as dynamic fields.

For more information on setting up Solr with Sitecore, check this tutorial:

https://sitecore-community.github.io/docs/search/solr/Configuring-Solr-for-use-with-Sitecore-8/#optional-development-step

This is a misconfiguration of the Solr schema.xml like Pete said above and the type and language mapping of Sitecore ContentSearch.

you need check the type matches in either for the master index or probably the defaultSolrIndexConfiguration and the schema for having the extensions for your language (cs-cz mapped to prefix _cs in Solr)

Your Answer

 

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

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