Page 1 of 1

Sphinx 2.0.1 PHP API library updated

Posted: 04 Aug 2011, 22:38
by meyercr
On Linux, I setup Sphinx searching, from source using

./configure --prefix=/usr/local/sphinx
make
make install

If you are using Sphinx 2.0.1-beta
You will need to update the TTRSS version of lib/sphinxapi.php to what is included in their distribution -- sphinx-2.0.1-beta/api/sphinxapi.php

When using the TTRSS sphinx.conf file you will need to update a few paths which paths relative to /usr/local/sphinx
  • path = /usr/local/sphinx/var/data/ttrss
  • log = /usr/local/sphinx/var/log/searchd.log
  • query_log = /usr/local/sphinx/var/log/query.log
  • pid_file = /usr/local/sphinx/var/run/searchd.pid

Set permission correctly for /usr/local/sphinx/var/* (So the daemon has write priv)
Update config.php to turn on SPHINX_ENABLED
Make sure you start the sphinx search daemon /usr/local/sphinx/bin/searchd

With this the search runs smoothly, Very nice :)

Note: I am not sure if I should check-in this new version to GitHub? It should be backward compatible?

Re: Sphinx 2.0.1 PHP API library updated

Posted: 04 Aug 2011, 23:58
by fox
Merged that. I hope it works with older Sphinx though. Also, not sure what sphinxapi.php.08_04_11_183927 was doing in there. :)

Re: Sphinx 2.0.1 PHP API library updated

Posted: 05 Aug 2011, 19:34
by meyercr
I was feeling paranoid, and used my time-stamp backup sh script :)

I will download the earlier Sphinx release 0.9.9 (Dec 2009) and see what changes, if any show up in the php api code.

-Craig