-2

アプリケーションで思考スフィンクスを実行したいと考えています。実行するとrake ts:start、このエラー
sphinx 2.0.7 think
sphinx 2.0.10
rails 3.2.11
ruby​​ 1.9.2p290
psql (9.1.9)が表示されます

/rails_projects/my_app$ rake ts:start RAILS_ENV=development --trace
** Invoke ts:start (first_time)
** Invoke thinking_sphinx:start (first_time)
** Invoke thinking_sphinx:app_env (first_time)
** Execute thinking_sphinx:app_env
** Execute thinking_sphinx:start
rake aborted!
searchd is already running.
/home/andrew/.rvm/gems/ruby-1.9.2-p290/gems/thinking-sphinx-2.0.10/lib/thinking_sphinx/tasks.rb:32:in `block (2 levels) in <top (required)>'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/task.rb:246:in `call'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/task.rb:246:in `block in execute'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/task.rb:241:in `each'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/task.rb:241:in `execute'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/task.rb:184:in `block in invoke_with_call_chain'
/home/andrew/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/task.rb:177:in `invoke_with_call_chain'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/task.rb:205:in `block in invoke_prerequisites'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/task.rb:203:in `each'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/task.rb:203:in `invoke_prerequisites'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/task.rb:183:in `block in invoke_with_call_chain'
/home/andrew/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/task.rb:177:in `invoke_with_call_chain'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/task.rb:170:in `invoke'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/application.rb:143:in `invoke_task'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/application.rb:101:in `block (2 levels) in top_level'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/application.rb:101:in `each'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/application.rb:101:in `block in top_level'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/application.rb:110:in `run_with_threads'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/application.rb:95:in `top_level'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/application.rb:73:in `block in run'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/application.rb:160:in `standard_exception_handling'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/lib/rake/application.rb:70:in `run'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/gems/rake-10.0.4/bin/rake:33:in `<top (required)>'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/bin/rake:19:in `load'
/home/andrew/.rvm/gems/ruby-1.9.2-p290@global/bin/rake:19:in `<main>'
/home/andrew/.rvm/gems/ruby-1.9.2-p290/bin/ruby_noexec_wrapper:14:in `eval'
/home/andrew/.rvm/gems/ruby-1.9.2-p290/bin/ruby_noexec_wrapper:14:in `<main>'
Tasks: TOP => ts:start => thinking_sphinx:start

/rails_projects/my_app $ searchd

Sphinx 2.0.7-release (r3759)
Copyright (c) 2001-2012, Andrew Aksyonoff
Copyright (c) 2008-2012, Sphinx Technologies Inc (http://sphinxsearch.com)

FATAL: no readable config file (looked in /usr/local/etc/sphinx.conf, ./sphinx.conf).

/usr/local/etc/ のみ example.sql sphinx.conf.dist sphinx-min.conf.dist

/rails_projects/my_app $ ps 補助 | grep 検索

user   23487  0.0  0.0  16392  1612 pts/0    S    15:39   0:01 searchd --pidfile --config /home/user/rails_projects/my_app/config/development.sphinx.conf
user   25808  0.0  0.0   5616   832 pts/0    S+   19:23   0:00 grep --colour=auto searchd
4

1 に答える 1

1

searchdは Sphinx 検索デーモンです。つまり、Sphinx が既に実行されているということです。実行するps aux | grep searchdと、プロセスを簡単に見つけることができます。再起動する必要がある場合はrake ts:restart、 、またはrake ts:stopを実行します rake ts:start

于 2013-04-14T15:09:11.327 に答える