Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

RSolr::Error::InvalidRubyResponse - 200 OK

I am getting following error even after starting forreman and starting sunspot:solr :

RSolr::Error::InvalidRubyResponse - 200 OK
Error: <result status="1">java.lang.NullPointerException
    at org.apache.solr.handler.XmlUpdateRequestHandler.doLegacyUpdate(XmlUpdateRequestHandler.java:129)
    at org.apache.solr.servlet.SolrUpdateServlet.doPost(SolrUpdateServlet.java:87)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
    at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1221)
    at org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:297)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)
    at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:399)
    at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)

Request Data: "<?xml version=\"1.0\" encoding=\"UTF-8\"?><add><doc><field name=\"id\">User 1</field><field name=\"type\">User</field><field name=\"type\">ActiveRecord::Base</field><field name=\"class_name\">User</field><field name=\"name_s\">K12 Administrator</field><field name=\"username_s\">admin</field><field name=\"id_i\">1</field><field name=\"role_s\">admin</field><field boost=\"1.5\" name=\"name_text\">K12 Administrator</field><field name=\"username_text_text\">admin</field></doc></add>"

Does anyone know why am I getting this this error? Please help me.

Thank you

like image 693
Dhara Joshi Avatar asked May 20 '13 14:05

Dhara Joshi


1 Answers

I was getting this as well. My background was that I installed Solr locally and ignored everything in the solr subdirectories. So the contents of solr/pids where ignored but the file structure of solr/pids remained.

I deployed this to our dev server and encountered the above errors.

The solution turned out to be simple. The solr directory needs to be created fresh in a new environment.

  1. rake sunspot:solr:stop
  2. Delete your /solr directory.
  3. rake sunspot:solr:start
  4. rake sunspot:solr:reindex

courtesy of Can't reindex Sunspot SOLR - Error - RSolr::Error::Http - 500 Internal Server Error

like image 200
Travis Avatar answered Oct 21 '22 06:10

Travis