1

I am running 5.4.3 version of elasticsearch and currently facing issues with poor performance of CMS. I would like to know if G1GC is supported on 5.4.3 version of elastic-search and if there is any precaution to take while using G1GC.

sumit jha
  • 91
  • 1
  • 10

2 Answers2

3

G1GC is only supported in the last release of elasticsearch (6.5.X). In previous versions, a bootstrap check will prevent your elasticsearch node to start in production mode.

The only way to start with it is to fork the elastic source code and remove the bootstrap check. But elastic.co will refuse to give you support on such a configuration.

More information here and here

Pierre Mallet
  • 7,053
  • 2
  • 19
  • 30
  • This is misleading: Elasticsearch only blocks G1GC before JDK 8u40, since there is a known index corruption bug. With JDK 8u40 and later G1GC is not officially supported for Elasticsearch before 6.5 and it's not recommended to use it, but it is possible. – xeraa Nov 23 '18 at 23:25
0

Switching garbage collector is not a magic sauce that you sprinkle on your infrastructure to make it work faster. Some things to consider:

  1. What is "poor performance"? Throughput, latency, GC times,...? Also what is your bottleneck?
  2. The tradeoff between CMS and G1GC are throughput for GC times. While GC times (stop the world) improve in G1GC it can have negative effects on the throughput. That's why it hasn't been recommended for a long time.
  3. If you are on JDK8, make sure you are on the latest version. There were some improvements over time.
  4. There is a good chance that a newer Elasticsearch version will improve performance more than switching garbage collector.
xeraa
  • 10,456
  • 3
  • 33
  • 66