An LRU cache will always fill up the old generation. Old objects are ejected, and those are usually in the old generation.
Increasing the heap size will not eliminate this. It will make major, stop the world collections longer. Increase the new generation size until the rate of old gen increase slows down. Then choose a total heap size to control the frequency (and duration) of major collections. We run with the new generation at about 25% of the heap, so 8GB total and a 2GB newgen. A 512 entry cache is very small for query results or docs. We run with 10K or more entries for those. The filter cache size depends on your usage. We have only a handful of different filter queries, so a tiny cache is fine. What is your hit rate on the caches? wunder On Mar 2, 2014, at 7:42 PM, KNitin <nitin.t...@gmail.com> wrote: > Hi > > I have very large index for a few collections and when they are being > queried, i see the Old gen space close to 100% Usage all the time. The > system becomes extremely slow due to GC activity right after that and it > gets into this cycle very often > > I have given solr close to 30G of heap in a 65 GB ram machine and rest is > given to RAm. I have a lot of hits in filter,query result and document > caches and the size of all the caches is around 512 entries per > collection.Are all the caches used by solr on or off heap ? > > > Given this scenario where GC is the primary bottleneck what is a good > recommended memory settings for solr? Should i increase the heap memory > (that will only postpone the problem before the heap becomes full again > after a while) ? Will memory maps help at all in this scenario? > > > Kindly advise on the best practices > Thanks > Nitin