Connection refused using Sunspot and Solr in Rails
Turns out it was a bug in Sunspot. Here's a link to the issue I filed for a full description:
https://github.com/sunspot/sunspot/issues/262
My workaround was to edit the .yml file and change all ports (test, development, and production) to 8983.
Ruby on Rails - Solr/Sunspot: Connection refused - connect(2)
It turns out that in the end, after all the troubleshooting, the problem was just the port number in the config file (in some drawn out way) -- i.e. Sunspot.config.solr.url
.
rails RSolr::Error::ConnectionRefused: Connection refused error
I've forgot to run the command
rake sunspot:solr:run
Hope that helps someone new with sunspot/solr such as myself
Rails - Solr production server, connection refused
Most probably, your Solr is not set up to listen to the localhost interface and only listens to mydomain.com interface.
To verify this assumption, do curl localhost:8983/solr/solr_sunspot_example
and curl mydomain.com:8983/solr/solr_sunspot_example
from your instance. If the second command succeeds, while the first one does not that would be the case.
You would have 2 options to solve it: either point your configuration to query the mydomain.com interface, or change Solr configuration to listen on the localhost interface. The later will be controlled by the hostname setting in the sunspot.yml (see the github wiki page you're referencing above).
Related Topics
Ruby/Rails - Active Record Db Migration to MySQL - Timestamp Type
Differencebetween Def Func(Var) and Def Func=(Var)
How to Properly Install Bootsnap on Windows
Receving the Undefined Method 'Generators' Error
How to Write the JSON Schema If JSON Has Multiple Data Set
Ruby Instance Method & Conditional Local Variable Assignment with Same Name
Illegal Quoting in Line 1 Using Ruby CSV
Sending Form Data to Remote Rails Application Using Httparty
Ruby: Unexpected End-Of-Input, Expecting Keyword_End for If Statement
To_Model Delegated to Attachment, But Attachment Is Nil