Join Bridgewater State University for a Website Search Webinar on Dec. 10 | REGISTER NOW

February 16, 2021

Dipsy Kapoor

|

2 min. read

While reviewing tuning suggestions for a customer using cluster Solr 8.1.1 deployments with Sitecore 9.3, we found evidence of a Solr bug that is causing intermittent 401 errors when Basic Authentication is enabled. If you are experiencing this issue, we are recommending an upgrade to Solr 8.2.

What’s the Issue with Intermittent 401 Errors?

Cluster Solr 8.1.1 deployments with Basic Authentication enabled may have intermittent failures during inter-node communication during indexing. The result is that the requests fail with 401 errors.

This issue has been previously reported as SOLR-13510 on the Apache Solr Issues webpage.

If your Solr deployment is facing this issue, you will see errors messages similar to the one shown below:

2019-06-04 07:31:00.227 ERROR (qtp67730604-24) [c:gettingstarted s:shard1 r:core_node3 x:gettingstarted_shard1_replica_n1] o.a.s.h.RequestHandlerBase org.apache.solr.client. solrj.impl.BaseHttpSolrClient$RemoteSolrException: Error from server at null: Expected mime type application/octet-stream but got text/html.

				
					<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8"/>
<title>Error 401 require authentication</title>
</head>
<body><h2>HTTP ERROR 401</h2>
<p>Problem accessing /solr/gettingstarted_shard3_replica_n4/select. Reason:
<pre> require authentication</pre></p>
<script>var rocket_beacon_data = {"ajax_url":"https:\/\/www.searchstax.com\/wp-admin\/admin-ajax.php","nonce":"541a8d6319","url":"https:\/\/www.searchstax.com\/blog\/intermittent-401-errors-with-solr-8-1-1-and-sitecore-9-3","is_mobile":false,"width_threshold":1600,"height_threshold":700,"delay":500,"debug":null,"status":{"atf":true,"lrc":true},"elements":"img, video, picture, p, main, div, li, svg, section, header, span","lrc_threshold":1800}</script><script data-name="wpr-wpr-beacon" src='https://www.searchstax.com/wp-content/plugins/wp-rocket/assets/js/wpr-beacon.min.js' async></script></body>
</html>
				
			
				
					at org.apache.solr.client.solrj.impl.Http2SolrClient.processErrorsAndResponse (Http2SolrClient.java:681) at org.apache.solr.client.solrj.impl.Http2SolrClient.request(Http2SolrClient.java:400) at org.apache.solr.client.solrj.impl.Http2SolrClient.request(Http2SolrClient.java:739) at org.apache.solr.client.solrj.SolrClient.request(SolrClient.java:1274) at org.apache.solr.handler.component.HttpShardHandler.request(HttpShardHandler.java:227) at org.apache.solr.handler.component.HttpShardHandler.lambda$submit$0 (HttpShardHandler.java:188) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) at com.codahale.metrics.InstrumentedExecutorService$InstrumentedRunnable.run (InstrumentedExecutorService.java:181) at org.apache.solr.common.util.ExecutorUtil$MDCAwareThreadPoolExecutor.lambda$execute$0 (ExecutorUtil.java:209) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1128) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:628) at java.base/java.lang.Thread.run(Thread.java:834)
				
			

We Recommend an Upgrade to Solr 8.2 for Sitecore 9.3

If you are receiving intermittent 401 errors in Solr 8.1.1 deployments with Sitecore 9.3 and have implemented Basic Authentication, we recommend an upgrade to Solr 8.2. While Solr 8.1.1 is the currently recommended version for Sitecore 9.3, our team is working with Sitecore on this issue to establish broader support for Sitecore 9.3 and Solr 8.2.

Please submit a Support Ticket through the Managed Solr Dashboard if you have any additional questions. If you are experiencing any other Solr performances issues on Sitecore, check out our blog post with 5 ways to Optimize Solr Search Performance.

By Dipsy Kapoor

VP, Engineering

"...If you’ve taken the time to build extensive customer journey maps, your team will get to know your customers on a deeper level and be able to personalize the journey...."

You might also like: