You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Shawn Heisey <ap...@elyograg.org> on 2015/03/25 04:52:40 UTC

Re: Using G1 with Apache Solr

On 3/24/2015 3:48 PM, Kamran Khawaja wrote:
> I'm running Solr 4.7.2 with Java 7u75 with the following JVM params:
> 
>     -verbose:gc 
>     -XX:+PrintGCDateStamps 
>     -XX:+PrintGCDetails 
>     -XX:+PrintAdaptiveSizePolicy 
>     -XX:+PrintReferenceGC 
>     -Xmx3072m 
>     -Xms3072m 
>     -XX:+UseG1GC 
>     -XX:+UseLargePages 
>     -XX:+AggressiveOpts 
>     -XX:+ParallelRefProcEnabled 
>     -XX:G1HeapRegionSize=8m 
>     -XX:InitiatingHeapOccupancyPercent=35 
> 
> 
> What I'm currently seeing is that many of the gc pauses are under an
> acceptable 0.25 seconds but seeing way too many full GCs with an average
> stop time of 3.2 seconds.
> 
> You can find the gc logs
> here: https://www.dropbox.com/s/v04b336v2k5l05e/g1_gc_7u75.log.gz?dl=0
> 
> I initially tested without specifying the HeapRegionSize but that
> resulted in the "humongous" message in the gc logs and a ton of full gc
> pauses.

This is similar to the settings I've been working on that I've
documented on my wiki page, with better results than you are seeing, and
a larger heap than you have configured:

https://wiki.apache.org/solr/ShawnHeisey#G1_.28Garbage_First.29_Collector

You have one additional option that I don't --
InitiatingHeapOccupancyPercent.  I would suggest running without that
option to see how it affects your GC times.

I'm curious what OS you're running under, whether the OS and Java are
64-bit, and whether you have actually enabled huge pages in your
operating system.  If it's Linux and you have enabled huge pages, have
you turned off transparent huge pages as documented by Oracle:

https://blogs.oracle.com/linux/entry/performance_issues_with_transparent_huge

On my servers, I do *not* have huge pages configured in the operating
system, so the UseLargePages java option isn't doing anything.

One final thing ... Oracle developers have claimed that Java 8u40 has
some major improvements to the G1 collector, particularly for programs
that allocate very large objects.  Can you try 8u40?

Thanks,
Shawn


Re: Using G1 with Apache Solr

Posted by William Bell <bi...@gmail.com>.
The issue we had with Java 8 was with DIH handler. We were using Rhino and
with the new implementation in Java 8, we had several Regex expression
issues...

We are almost ready to go now, since we moved away from Rhino and now use
Java.

Bill

On Wed, Mar 25, 2015 at 2:14 AM, Daniel Collins <da...@gmail.com>
wrote:

> Interesting none the less Shawn :)
>
> We use G1GC on our servers, we were on Java 7 (64-bit, RHEL6), but are
> trying to migrate to Java 8 (which seems to cause more GC issues, so we
> clearly need to tweak our settings), will investigate 8u40 though.
>
> On 25 March 2015 at 04:23, Shawn Heisey <ap...@elyograg.org> wrote:
>
> > On 3/24/2015 9:52 PM, Shawn Heisey wrote:
> > > On 3/24/2015 3:48 PM, Kamran Khawaja wrote:
> > >> I'm running Solr 4.7.2 with Java 7u75 with the following JVM params:
> >
> > I really got my wires crossed.  Kamran sent his message to the
> > hostpot-gc-use mailing list, not the solr-user list!
> >
> > Thanks,
> > Shawn
> >
> >
>



-- 
Bill Bell
billnbell@gmail.com
cell 720-256-8076

Re: Using G1 with Apache Solr

Posted by Daniel Collins <da...@gmail.com>.
Interesting none the less Shawn :)

We use G1GC on our servers, we were on Java 7 (64-bit, RHEL6), but are
trying to migrate to Java 8 (which seems to cause more GC issues, so we
clearly need to tweak our settings), will investigate 8u40 though.

On 25 March 2015 at 04:23, Shawn Heisey <ap...@elyograg.org> wrote:

> On 3/24/2015 9:52 PM, Shawn Heisey wrote:
> > On 3/24/2015 3:48 PM, Kamran Khawaja wrote:
> >> I'm running Solr 4.7.2 with Java 7u75 with the following JVM params:
>
> I really got my wires crossed.  Kamran sent his message to the
> hostpot-gc-use mailing list, not the solr-user list!
>
> Thanks,
> Shawn
>
>

Re: Using G1 with Apache Solr

Posted by Shawn Heisey <ap...@elyograg.org>.
On 3/24/2015 9:52 PM, Shawn Heisey wrote:
> On 3/24/2015 3:48 PM, Kamran Khawaja wrote:
>> I'm running Solr 4.7.2 with Java 7u75 with the following JVM params:

I really got my wires crossed.  Kamran sent his message to the
hostpot-gc-use mailing list, not the solr-user list!

Thanks,
Shawn