Showing posts with label Thinking Sphinx. Show all posts
Showing posts with label Thinking Sphinx. Show all posts

Sunday, July 24, 2011

Getting error "ThinkingSphinx::SphinxError (unknown local index '' in search request):"


We define index for Sphinx in model in blocks as such:
define_index do
      indexes :name, :sortable => true
      indexes description
...
...
    end

Whenever we do some changes in such type of index and start ThinkingSphinx it gives us error as :
ThinkingSphinx::SphinxError (unknown local index '<delta_name>' in search request):

To solve such type of issues, run
rake ts:rebuild
It will first do changes in config file and then will do indexing as per the changes done, then you will be able to run Thinking Sphinx.

Wednesday, July 6, 2011

searchd giving error "dyld: Library not loaded: libmysqlclient.18.dylib" on Mac

On Mac system, in one of my application using Thinking Sphinx. After installation while running searchd, it gives following errors:

$ searchd
dyld: Library not loaded: libmysqlclient.18.dylib
  Referenced from: /usr/local/bin/searchd
  Reason: image not found
Trace/BPT trap
-:sphinx-0.9.8 ror$ cd ..
-:Downloads ror$ l
-bash: l: command not found

Solution:
It's because unable to find the libmysqlclient library. Add the following to to your ~/.profile:

export DYLD_LIBRARY_PATH=/usr/local/mysql/lib/
and it will work fine