【发布时间】:2014-01-28 10:25:52
【问题描述】:
我一直在用思考狮身人面像指标来应对奇怪的行为。目前的状态是没有进行索引。
我使用不同的命令得到不同的行为。 cap deploy 在rebuild sphinx 命令下停止。
invoke_command "cd #{release_path} && RAILS_ENV=#{rails_env} bundle exec rake ts:rebuild"
手动索引命令
$ bundle exec rake ts:index --trace
** Invoke ts:index (first_time)
** Invoke environment (first_time)
** Execute environment
rake aborted!
FATAL: sorry, too many clients already
/Users/me/app/shared/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/postgresql_adapter.rb:1216:in `initialize'
手动 bundle exec rake ts:rebuild 的行为是一个很长的停顿,我最终会中断。
试图停止引擎有不同的错误。有一个足够长的档位 Ctrl-C 并返回:
$ bundle exec rake ts:stop --trace
** Invoke ts:stop (first_time)
** Invoke environment (first_time)
** Execute environment
** Execute ts:stop
^Crake aborted!
/Users/me/app/shared/bundle/ruby/1.9.1/gems/thinking-sphinx-3.0.3/lib/thinking_sphinx/rake_interface.rb:56:in `sleep'
更新呜呜呜……我跑了
bundle exec rake ts:index --trace
直接在服务器的终端窗口中。索引开始写作。但最后得到了两个警告。
PID 82805 找不到进程
索引未旋转
这样画得更好吗?
** 更新 2 ** 数据
?? S 11:28AM 0:06.93 /usr/local/bin/searchd --pidfile --config /Users/me/app/releases/20140127084810/config/development.sphinx.conf
?? S 11:28AM 0:00.00 /usr/local/bin/searchd --pidfile --config /Users/me/app/releases/20140127084810/config/development.sphinx.conf
?? S 13Jan14 1:16.68 /usr/local/bin/searchd --pidfile --config /Users/me/rails/releases/20140113100039/config/development.sphinx.conf
s001 R+ 1:23PM 0:00.00 grep searchd
对于那些感兴趣的人,问题已通过两个讨论 one on settings 和另一个讨论 identifying the processes and acting upon them 得到解决
【问题讨论】:
标签: ruby-on-rails-3.2 thinking-sphinx postgresql-9.2