Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

First what is the best way to install Sphinx on a centOs server

rpm -ivh http://sphinxsearch.com/downloads/accept.php?file=sphinx-2.0.6-1.rhel6.x86_64.rpm
yum install sphinx

didn't seem to work.

Also, my set up is one app server, and one database server. The app server runs Magento, where it has the new module the works with Sphinx but, it's unclear both on Sphinx docs as well as any google searches, which server Sphinx should be installed on for the best effect.

share|improve this question
    
Care to share the errors when running the install ? –  CloudWeavers Mar 17 '13 at 12:35
    
to be honest it's been a few days so I don't recall now. If I can get the where should it be done at, which server, I'll do it again and let you know. thanks –  jeremy.bass Mar 17 '13 at 17:01

2 Answers 2

up vote 3 down vote accepted
+50

First, you'll want to link to the file directly, not to a web form.

rpm -ivh http://sphinxsearch.com/files/sphinx-2.0.6-1.rhel6.x86_64.rpm

Most of the documentation I have read says that Sockets are going to be faster than TCP/IP for lookups, and considering that Sphinx will be obtaining/parsing the data from mysql, it being able to obtain that information as directly as possible would seem to be the most sensible thing.

The obvious gotcha here would be how much work will be done on each side, if your app server has a consistently lower load, the slight overhead of TCP/IP would probably be worth accepting to not slow down your SQL server any more.

share|improve this answer
    
so you believe if the app server is always under load, which if you know about magento at all you'll know it is like that, then I should put Sphinx on the db server and since I'm already dealing with the latency of any query now, that this approach is best? –  jeremy.bass Mar 20 '13 at 18:08
    
IMHO yes, especially if you're going to be using big data sets, better have sphinx obtain it locally, then send the processed data over the network to you. –  NickW Mar 21 '13 at 9:15
    
Super, I'll reset everything and doing it again this way. –  jeremy.bass Mar 21 '13 at 15:24
    
Best of luck!!! –  NickW Mar 21 '13 at 15:27
    
so there is one more considering fact in the choice of where sphinx is installed that was not accounted for. Does the app that uses the sphinx api, need to start, reindex etc which I guess needed the demon. If so then it needs to be on the same server. –  jeremy.bass Mar 23 '13 at 23:42

First, I don't feel comfortable directly installing packages via HTTP. I prefer to download the package with wget or something similar, verify any md5sums and make myself comfortable that I have an untampered package. If those pass then I install. Just something I do and something to consider in the future.

Second, I think it all depends on the current, and future, load of the app server. If you don't anticipate an overwhelming load to it, and the current webserver is standing firm, then I would install it on the app server. Not knowing exactly what the install's dependancies are, I think configuration would be easier this way especially if it requires apache. Installing sphinx on the DB server may also require apache there which would add to the load on that box.

Lastly, in regards to "best effect" I think you have to know what your expectations are for the application. If milliseconds matter to you, then you'll want to go with the fastest route to the data and build your architecture to support that. If they don't, then having the DB on a second server, which is probably within the same network anyway, and connecting via tcp/ip is going to be fine. But again it's all in what you expect.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.