thinking sphinx error when rake thinking_sphinx:start

筅森魡賤 提交于 2019-12-23 04:17:15

问题


I am using gem 'thinking-sphinx', '2.0.10' for search functionality.I am following http://railscasts.com/episodes/120-thinking-sphinx tutorial for this.

script/plugin install git://github.com/freelancing-god/thinking-sphinx.git
rake thinking_sphinx:index

These 2 steps executed without any problem,but when i did rake thinking_sphinx:start it was giving following error :

Failed to start searchd daemon. Check /home/user/newsvn/alumnicell/log/searchd.log.
Failed to start searchd daemon. Check /home/user/newsvn/alumnicell/log/searchd.log

I searched on net about this but even trying many solutions i am not able to solve this error.Also while checking on net i came to know that there should be sphinx.yml file in config which is not present in my project.

How to solve this error?


回答1:


solved it... i just added sphinx.yml file inside config and specified port number for each environment as follows:

development:
  port: 9310
  morphology: stem_en

test:
  port: 9310
  morphology: stem_en

production:
  port: 9310
  morphology: stem_en

then changed listen address in development.sphinx.conf for searchd as follows:

searchd
{
  listen = 127.0.0.1:9310
}

then on console ran command:

rake thinking_sphinx:rebuild



回答2:


May be /home/user/newsvn/alumnicell/log/searchd.log has solution for the problem.

Just post it!



来源:https://stackoverflow.com/questions/10782140/thinking-sphinx-error-when-rake-thinking-sphinxstart

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!