On 1/5/2018 2:35 PM, Satyaprashant Bezwada wrote: > Thanks a lot. It helped, I noticed the error in the solr console log. <snip> > # java.lang.OutOfMemoryError: Metaspace > # -XX:OnOutOfMemoryError="/usr/local/solr/bin/oom_solr.sh 8983 /var/solr/logs" > # Executing /bin/sh -c "/usr/local/solr/bin/oom_solr.sh 8983 > /var/solr/logs"... > Running OOM killer script for process 24431 for Solr on port 8983 > Killed process 24431 > > Wasn’t sure if it would help, but I increased the max memory allocated for > Metaspace size from 64 to 128. Would continue to monitor and see if it works. > Is there any ideal memory space that is suggested? > > SOLR_OPTS="$SOLR_OPTS -XX:MaxMetaspaceSize=128m"
The information I've found says Java 8 doesn't set a limit on metaspace unless you specify that startup option. It can use as much native memory as the machine has. Since Solr 6.x requires Java 8, I don't think you're running an older Java version. I do not see the -XX:MaxMetaSpaceSize option in the standard scripts when I look in the master branch, or in the 6.5.1 version you are running, so unless your startup script was edited to include that option, metaspace would not be limited to 64 megabytes. That particular OOME exception should not be possible with the standard script unless the amount of memory in the machine is limited. If you *did* find that option in your script set to 64m, then somebody at your location added it. Unless you have a really good reason for having the option, I would recommend removing it, so there is no artificial limit. This is the first time I've seen a metaspace OOME related to Solr, so although it is *possible* that there's a metaspace/permgen memory leak, it is unlikely. If there were a bug like that in Solr, I would expect to see that error from more than one person. Thanks, Shawn