In our load testing, the limit for utilizing all of the processor time
on a box was locking (synchronize, mutex, monitor, pick one). There were
a couple of locking points that we saw.

1. Lucene's locking on the index for simultaneous read/write protection.
2. Solr's locking on the LRUCaches for update protection.

If you've gotten Solr configured to the point where *most* of your work
is done in memory, then multiple instances of Solr would essentially
distribute this locking and create less contention enabling you to
utilize more of the CPU. This assumes that the creation of another JVM
won't hinder your in memory caching.

Please note, this was only for *our* Solr configuration. It doesn't
necessarily reflect anyone else's configuration. It does, however,
provide at least one scenario where multiple instances could increase
performance.

-Todd



-----Original Message-----
From: Phillip Farber [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, October 14, 2008 12:44 PM
To: solr-user@lucene.apache.org
Subject: Re: Practical number of Solr instances per machine

Otis, you have a good memory :-)  I guess the main thing that prompted 
my question me was Mike Klass' statement that he runs 2 instance per 
machine to "squeeze" performance out of the box.  That raised the 
question in my mind as to just how this could benefit performance over a

single instance in one box.

Phil



Otis Gospodnetic wrote:
> Hi,
> 
> Did you not ask this question a while back?  I may be mixing things...
(hah, no, just checked)
> In short, it depends on a number of factors, such as index sizes,
query rates, complexity of queries, amount of RAM, your target query
latency, etc. etc.  So there is no super clear cut answer.  If you have
some concrete numbers, that will be easier to answer :)
> 
> 
> Otis
> --
> Sematext -- http://sematext.com/ -- Lucene - Solr - Nutch
> 
> 
> 
> ----- Original Message ----
>> From: Phillip Farber <[EMAIL PROTECTED]>
>> To: solr-user@lucene.apache.org
>> Sent: Wednesday, October 8, 2008 5:34:58 PM
>> Subject: Practical number of Solr instances per machine
>>
>>
>> Hello everyone,
>>
>> What is the generally accepted number of solr instances it makes
sense 
>> to run on a single machine given solr/lucene threading? Servers now 
>> commonly have 4 or 8 cpus.  Obviously the more instances you run the 
>> bigger your JVM heap needs to be and that takes away from OS cache.
Is 
>> the  sweet spot just one instance per machine?  What is the right way
to 
>> think about this issue?
>>
>> Thanks,
>>
>> Phil
> 

Reply via email to