【发布时间】:2014-04-01 19:00:04
【问题描述】:
我是 ruby on rails 的新手,我正在玩弄 Sunspot_Rails Gem。
我的 gemfile 看起来像这样
gem "sunspot_rails"
group :development do
gem 'sqlite3', '1.3.8'
gem 'better_errors'
gem 'binding_of_caller'
gem 'sunspot_solr'
end
我按照 github 上的说明快速入门。我从 solr 开始
bundle exec rake sunspot:solr:start
然后我启动我的 Rails 服务器。
rails s
页面加载,但是当我尝试通过 localhost 添加一个类的实例时,我得到一个错误
RSolr::Error::Http at /dogs
RSolr::Error::Http - 500 Internal Server Error
Error: {'responseHeader'=>{'status'=>500,'QTime'=>3},'error'=>{'msg'=>'no segments* file found in NRTCachingDirectory(org.apache.lucene.store.NIOFSDirectory@/Users/ShiftedRec/whosthedee/solr/development/data/index lockFactory=org.apache.lucene.store.NativeFSLockFactory@170ad173; maxCacheMB=48.0 maxMergeSizeMB=4.0): files: [write.lock]','trace'=>'org.apache.lucene.index.IndexNotFoundException: no segments* file found in
我在互联网上看到的唯一与此相关的是
http://www.garysieling.com/blog/fixing-solr-error-no-segments-file-found-in-nrtcachingdirectory
我到底做错了什么?
谢谢...
【问题讨论】:
标签: ruby-on-rails ruby solr sunspot-rails