You might consider looking at your internal Solr cache configuration (solrconfig.xml). These caches occupy heap space, and from my understanding do not overflow to disk. So if there is not enough heap memory to support the caches an OOM error will be thrown.
I also believe these caches live in Old Gen. So you might consider decreasing your CMSInitiatingOccupancyFraction to trigger a GC sooner. Based on your description below every 20,000 documents your caches will be invalidated and rebuilt as part of a commit. So a GC that occurs sooner may help free the memory of the old caches. Matt -----Original Message----- From: Ameya Aware [mailto:ameya.aw...@gmail.com] Sent: Friday, July 25, 2014 9:22 AM To: solr-user@lucene.apache.org Subject: java.lang.OutOfMemoryError: Requested array size exceeds VM limit Hi, I am in process of indexing lot of documents but after around 90000 documents i am getting below error: java.lang.OutOfMemoryError: Requested array size exceeds VM limit I am passing below parameters with Solr : java -Xms6144m -Xmx6144m -XX:MaxPermSize=512m -Dcom.sun.management.jmxremote -XX:+UseParNewGC -XX:+UseCompressedOops -XX:+UseConcMarkSweepGC -XX:+CMSIncrementalMode -XX:+CMSParallelRemarkEnabled -XX:+UseCMSInitiatingOccupancyOnly -XX:CMSInitiatingOccupancyFraction=70 -XX:ConcGCThreads=6 -XX:ParallelGCThreads=6 -jar start.jar Also, i am Auto-committing after 20000 documents. I searched on google for this but could not get any specific answer. Can anybody help with this? Thanks, Ameya