On Fri, 2015-01-23 at 07:34 +0100, deniz wrote:
> Would it boost any performance in case the index has been switched from
> RAMDirectoryFactory to use tmpfs?

RAMDirectoryFactory does not perform well for non-small indexes, so ...
probable yes.

> Or it would simply do the same thing like MMap? 

A fully cached MMap of files on permanent storage should perform the
same as a MMap of files in tmpfs. The primary selling point for tmpfs in
this context is that you force the data to always be in RAM (remember to
turn off or severely limit the swap system).

This makes sense in a mixed environment; for example with two Solr
collections, one small which should always respond as fast as possible,
another large which has lower real-time requirements. Putting the index
of the smaller one on tmpfs should ensure this.

> And in case it would be better to use tmpfs rather than RAMDirectory or
> MMap, which directory factory would be the most feasible one for this
> purpose?

MMap with tmpfs would be my guess, as it should avoid copying of the
data from one memory area to another when accessing files. But it is not
something I have experience with.

If you have a single index on a box with enough memory to fully cache
the index data, I would recommend just using MMapDirectory without
involving tmpfs.

- Toke Eskildsen, State and University Library, Denmark


Reply via email to