[Rails] Re: Ruby on Rails - Setting up a Solr server with Sunspot for production
After talking more with Hassan and long sessions of Troubleshooting -
I managed to fix the issue.
I firstly deleted the sunspot.yml file in the config folder of my
rails application and replaced it with an initializer (sunspot.rb) in
my config/initalizers directory which specified the sunspot path:
Sunspot.config.solr.url = 'http://localhost:8983/solr'
After doing this I stopped getting the errors while in development,
although a reindex was required. When trying to reindex I then
encountered the error: "Solr Response: Internal Server Error"
At this stage I tried a variety of things to get it working - some/all
of these may or may not have had a bearing on the getting it to work.
I changed the file permissions (chmod, chown) of the files in my rails
application to make sure they were all fully accessible and writable
to by apache and solr, changed Java versions from OpenJDK to Oracle/
Sun JDK (sudo update-alternatives --config java) - I think this was
the main fix to this problem, closed down another server that was
running on the same port (plus closed down tomcat since it turns out
it wasn't being used).
After this - everything reindexed fine and it worked a treat!
Closing the other server that was running on the same port also fixed
an issue in which I got the "Connection refused - connect(2) " when
running is production mode despite it working in development.
Hope this helps other people that may be experiencing the same or
similar problems!
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home