Thank you Pat! 

On Tuesday, March 18, 2014 9:11:41 AM UTC+3, Pat Allan wrote:
>
> Hi Joram
>
> Answers in context below.
>
> On 18 Mar 2014, at 4:48 pm, Joram Okwaro <[email protected] <javascript:>> 
> wrote:
>
> Hi Pat,
>
> I've experienced a considerable amount of difficulty finding documentation 
> on this.. even on how it would work conceptually. I'm glad I found this 
> thread. I have a couple of questions following your reply that I hope you 
> can help me with. 
>
> 1. I have tried setting up my first implementation of Thinking Sphinx with 
> a remote Sphinx server with Thinking Sphinx 3.1.0. Do the instructions 
> above apply for this new version too? I know there was a massive code 
> rewrite with version 3. 
>
>
> The information about setting the Sphinx version is no longer relevant, 
> and the remote_sphinx setting no longer exists (as you’ve noticed). The 
> rest is pretty accurate.
>
> 2. I can't seem to find ThinkingSphinx.remote_server in the documentation, 
> which brings me back to point 1 I guess :)
>
>
> Yup, there’s nothing in the TS v3 code that requires the distinguishing 
> between remote and local.
>
> 3. With all the scattered documentation I found, I just found out that I 
> need to set up my app on the server where the Sphinx server is set up in 
> order to have the rake tasks run there :D (shame on me, how else would the 
> indexer work). Please clarify though if anything has changed in Thinking 
> Sphinx 3.1.0 or if there's some additional info or caveats.
>
>
> You do still need your web app on the server as well, so the rake tasks 
> can refer to your indices and models and such.
>
>
> If you’ve any further questions about this, do let me know.
>
> Cheers
>
> — 
> Pat
>
>
> I hope you can help. Thanks. 
>
> On Friday, June 15, 2012 1:05:21 AM UTC+3, Pat Allan wrote:
>>
>> Hi Mike
>>
>> I'm going to start with the basics here - apologies if I'm repeating 
>> things you already know.
>>
>> Firstly, you can certainly have Sphinx running on one machine and have 
>> your web app on another machine. In this case, you would want 
>> ThinkingSphinx.remote_sphinx set to true, and you should have the 
>> appropriate Sphinx version in your sphinx.yml for the given environment 
>> (simply as "version: 0.9.8.1" should do the trick). And you'll definitely 
>> need to set the address (and port, if it's something other than 9312) so 
>> the Ruby code can make the connection to the Sphinx daemon (via a TCP 
>> socket).
>>
>> You will need to be running the rake tasks on the machine that Sphinx is 
>> located on - they do not work on remote installations (as really it's just 
>> calling indexer, and indexer requires local file system access to store 
>> Sphinx's data). So it's probably worth having a copy of your web app on the 
>> Sphinx machine, even through it does not function as a web host.
>>
>> If from the browser's perspective, you are running search on a separate 
>> (sub)domain, then you'll need the app on that domain, but Sphinx can be 
>> anywhere you like. If the same machine, then address/version may not be 
>> necessary, provided searchd and indexer are in the system's PATH. If 
>> they're not, that's where the bin_path setting comes into play. If on 
>> separate machines, then the previously mentioned approach is what you want.
>>
>> Surendra, there's the ThinkingSphinx.remote_sphinx= setter method, and 
>> then the boolean getter available at ThinkingSphinx.remote_sphinx?.
>>
>> I hope this clarifies things. Let me know if you have further questions!
>>
>> Cheers
>>
>> -- 
>> Pat
>>
>> On 13/06/2012, at 2:55 PM, Mike wrote:
>>
>> > Hello,
>> > 
>> > I've used Sphinx in the past and run/indexed/searched all in one
>> > enviro with no problem. Now I've decided to get fancy and stick sphinx
>> > on it's own url (http://search.domain.domain.com) and I jut can't seem
>> > to get it to connect.
>> > 
>> > All the posts, docs, and examples I've found on the web imply that
>> > this can be done but, no matter what I do, I keep getting the same
>> > generic message when I try to test (by running a simple rake:ts):
>> > *****
>> > Sphinx cannot be found on your system. You may need to configure the
>> > following
>> > settings in your config/sphinx.yml file:
>> >  * bin_path
>> >  * searchd_binary_name
>> >  * indexer_binary_name
>> > 
>> > 
>> > For more information, read the documentation:
>> > http://freelancing-god.github.com/ts/en/advanced_config.html
>> > 
>> > Generating Configuration to /home/foundit_prod/local/etc/sphinx.conf
>> > rake aborted!
>> > Input/output error - /home/foundit_prod/local/etc/sphinx.conf
>> > ****
>> > Also keep in mind there's no special setup on the remote domain (like
>> > a proxy, etc.) so, even when I do connect, how am I supposed to
>> > interact with Sphinx? For instance, I know I could tunnel into the
>> > machine and query Sphinx directly, but that seems to defeat the
>> > purpose of using Thinking Sphinx. Does that 9312 port handle that
>> > transaction?
>> > 
>> > Can anyone provide a solution?
>> > 
>> > Here's my enviro details:
>> > 
>> > Sphinx: v 0.9.8.1
>> > Thikning Sphinx: v 2.0.12 8100a4a)
>> > 
>> > #sphinx.yml
>> > 
>> > development:
>> >  listen: subdomain.domain.com
>> >  port: 9312
>> >  mem_limit: 64M
>> >  enable_star: true
>> >  bin_path: /home/[user]/local/bin
>> >  searchd_file_path: /home/[user]/local/bin
>> >  #searchd_log_file: /var/log/searchd/logs/searchd.log
>> >  #query_log_file: /var/log/searchd/logs/searchd.query.log
>> >  #pid_file: /var/run/searchd.pid
>> >  #morphology: stem_en
>> >  config_file: /home/[user]local/etc/sphinx.conf
>> > 
>> > #development.sphinx.conf
>> > 
>> > 
>> > indexer
>> > {
>> >  #mem_limit = 128M
>> > }
>> > 
>> > searchd
>> > {
>> >  #address = http://search.foundit-here.com
>> >  #port = 9312
>> >  listen = search.foundit-here.com:9312
>> >  #log = /Applications/rubystack-3/projects/fih_3/log/searchd.log
>> >  #query_log = /Applications/rubystack-3/projects/fih_3/log/
>> > searchd.query.log
>> >  #pid_file = /Applications/rubystack-3/projects/fih_3/log/
>> > searchd.development.pid
>> > }
>> > 
>> > 
>> > #environments/development.rb
>> > ...
>> > 
>> > ThinkingSphinx.remote_sphinx = true
>> > 
>> > -- 
>> > You received this message because you are subscribed to the Google 
>> Groups "Thinking Sphinx" group.
>> > To post to this group, send email to [email protected].
>> > To unsubscribe from this group, send email to 
>> [email protected].
>> > For more options, visit this group at 
>> http://groups.google.com/group/thinking-sphinx?hl=en.
>> > 
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Thinking Sphinx" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected] <javascript:>.
> To post to this group, send email to [email protected]<javascript:>
> .
> Visit this group at http://groups.google.com/group/thinking-sphinx.
> For more options, visit https://groups.google.com/d/optout.
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Thinking Sphinx" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/thinking-sphinx.
For more options, visit https://groups.google.com/d/optout.

Reply via email to