错误::Http - 500内部服务器错误

时间:2021-04-20 00:19:51

I am upgrading solr 5.3.1, I am getting following error when I run specs on semaphoreci

我正在升级solr5.3.1,当我在semaphoreci上运行spec时,我得到了以下错误

RSolr::Error::Http: RSolr::Error::Http - 500 Internal Server Error Error: {msg=SolrCore 'default' is not available due to init failure: Error opening new searcher,trace=org.apache.solr.common.SolrException: SolrCore 'default' is not available due to init failure: Error opening new searcher at org.apache.solr.core.CoreContainer.getCore(CoreContainer.java:974) at org.apache.solr.servlet.HttpSolrCall.init(HttpSolrCall.java:250) at org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:417) at org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:214) at org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:179) at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1652) at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:585) at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143) at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:577) at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:223)

RSolr::错误:Http: RSolr::错误::Http: 500内部服务器错误:{msg=SolrCore 'default'由于init失败而不可用:打开新搜索器错误,trace=org.apache.solr.common.SolrException: SolrCore 'default'由于init失败而不可用:在org.apache.solr. corecontainer . getservter . servr .java: CoreContainer.java:974在org.apache.solr. solr. solr. servr . filter (httpsolr . filter在org. eclipsee .jetty.server.handler. handle(scopedhandler.143) . eclipse.jetty.securityhandler .handle(securityhandler . handshandler.shandler.577)。

   URI: http://localhost:8981/solr/default/update?wt=json
   Request Headers: {"Content-Type"=>"application/json"}
   Request Data: "[{\"id\":\"Contact 1\",\"type\":[\"Contact\",\"ActiveRecord::Base\"],\"class_name\":\"Contact\",\"first_name_text\":\"Danial\",\"last_name_text\":\"Ullrich\"}]"

   Backtrace: /home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/rsolr-2.0.2/lib/rsolr/client.rb:195:in

rescue in execute' /home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/rsolr-2.0.2/lib/rsolr/client.rb:185:in execute' /home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/rsolr-2.0.2/lib/rsolr/client.rb:180:in send_and_receive' /home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/sunspot_rails-2.2.7/lib/sunspot/rails/solr_instrumentation.rb:16:in block in send_and_receive_with_as_instrumentation' /home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/activesupport-4.2.7.1/lib/active_support/notifications.rb:164:in block in instrument' /home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/activesupport-4.2.7.1/lib/active_support/notifications/instrumenter.rb:20:in instrument' /home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/activesupport-4.2.7.1/lib/active_support/notifications.rb:164:in instrument' /home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/sunspot_rails-2.2.7/lib/sunspot/rails/solr_instrumentation.rb:15:in send_and_receive_with_as_instrumentation' (eval):2:in post' /home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/rsolr-2.0.2/lib/rsolr/client.rb:83:in update' /home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/rsolr-2.0.2/lib/rsolr/client.rb:102:in add' # (eval):2:inpost' # ./spec/controllers/contacts_controller_spec.rb:319:in block (3 levels) in <top (required)>' # ------------------ # --- Caused by: --- # Faraday::ClientError: # the server responded with status 500 # (eval):2:inpost'

在执行救援/home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/rsolr-2.0.2 / lib / rsolr /客户。rb:185:在执行“/home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/rsolr-2.0.2 / lib / rsolr /客户。rb:180:在send_and_receive /home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/sunspot_rails-2.2.7 / lib /太阳黑子/铁路/ solr_instrumentation。rb:16:在send_and_receive_with_as_instrumentation' /home/runner/.rbenv/versions/2.3.1/ lib/ruby/2.3.0 /gems/activesupport-4.2.7.1/lib/active_support/notifications。rb:164:in block in instrument' / home/runnerv /.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/ gems/2.3.0/ activesupport-4.2.7.1/lib/active_support/notifications/ instruments / instruments。rb:20:仪器的/home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/activesupport-4.2.7.1 / lib / active_support /通知。rb:164:仪器的/home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/sunspot_rails-2.2.7 / lib /太阳黑子/铁路/ solr_instrumentation。rb:15:在send_and_receive_with_as_instrumentation (eval):2:在post' /home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/rsolr-2.0.2/lib/rsolr/客户端。rb:83:更新的/home/runner/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/rsolr-2.0.2 / lib / rsolr /客户。在add' # (eval):2:inpost' # ./spec/controllers/contacts_controller_spec。rb:319:在 <顶部(required)> ' # ------------------ ------------------ ------------------ -------------

Solr Logs

Solr日志

1152 ERROR (coreLoadExecutor-6-thread-2) [   x:development] o.a.s.c.CoreContainer Error creating core [development]: Index locked for write for core 'development'. Solr now longer supports forceful unlocking via 'unlockOnStartup'. Please verify locks manually!
org.apache.solr.common.SolrException: Index locked for write for core 'development'. Solr now longer supports forceful unlocking via 'unlockOnStartup'. Please verify locks manually!
  at org.apache.solr.core.SolrCore.<init>(SolrCore.java:820)
  at org.apache.solr.core.SolrCore.<init>(SolrCore.java:659)
  at org.apache.solr.core.CoreContainer.create(CoreContainer.java:723)
  at org.apache.solr.core.CoreContainer$1.call(CoreContainer.java:443)
  at org.apache.solr.core.CoreContainer$1.call(CoreContainer.java:434)
  at java.util.concurrent.FutureTask.run(FutureTask.java:266)
  at org.apache.solr.common.util.ExecutorUtil$MDCAwareThreadPoolExecutor$1.run(ExecutorUtil.java:210)
  at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
  at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
  at java.lang.Thread.run(Thread.java:748)
Caused by: org.apache.lucene.store.LockObtainFailedException: Index locked for write for core 'development'. Solr now longer supports forceful unlocking via 'unlockOnStartup'. Please verify locks manually!
  at org.apache.solr.core.SolrCore.initIndex(SolrCore.java:528)
  at org.apache.solr.core.SolrCore.<init>(SolrCore.java:761)

Any help would be much appreciated.

如有任何帮助,我们将不胜感激。

1 个解决方案

#1


3  

write.lock file might be present under solr/{environment}/data/index directory due to unclean shutdown. Removing write.lock file will fix the issue.

写。在solr/{environment}/data/index目录下,由于不干净关闭,可能存在锁文件。删除写。锁定文件将解决这个问题。

#1


3  

write.lock file might be present under solr/{environment}/data/index directory due to unclean shutdown. Removing write.lock file will fix the issue.

写。在solr/{environment}/data/index目录下,由于不干净关闭,可能存在锁文件。删除写。锁定文件将解决这个问题。

相关文章