1.垃圾收集器执行时间 看一段 GC 日志:耗时 29.47 秒
{Heap before GC invocations=132 (full 0):
par new generation total 2696384K, used 2696384K [0xfffffffc20010000, 0xfffffffce0010000, 0xfffffffce0010000)
eden space 2247040K, 100% used [0xfffffffc20010000, 0xfffffffca9270000, 0xfffffffca9270000)
from space 449344K, 100% used [0xfffffffca9270000, 0xfffffffcc4940000, 0xfffffffcc4940000)
to space 449344K, 0% used [0xfffffffcc4940000, 0xfffffffcc4940000, 0xfffffffce0010000)
concurrent mark-sweep generation total 9437184K, used 1860619K [0xfffffffce0010000, 0xffffffff20010000, 0xffffffff20010000)
concurrent-mark-sweep perm gen total 1310720K, used 511451K [0xffffffff20010000, 0xffffffff70010000, 0xffffffff70010000)
2013-07-17T03:58:06.601-0700: 51522.120: [GC Before GC: : 2696384K->449344K(2696384K), 29.4779282 secs] 4557003K->2326821K(12133568K) ,29.4795222 secs] [Times: user=915.56 sys=6.35, real=29.48 secs]
- 打印GC停顿时间
-XX:+PrintGCApplicationStoppedTime
2019-06-18T10:24:08.851+0800: 4.465: Total time for which application threads were stopped: 0.0016311 seconds, Stopping threads took: 0.0006654 seconds
3.es优化
discovery.zen.fd.ping_timeout: 1000s
discovery.zen.fd.ping_retries: 10
配置 描述
ping_interval 节点多久ping一次 默认1s
ping_timeout 等待响应时间 默认30s
ping_retries 失败或超时后重试的次数 默认3
4.查看索引占用内存情况
//查看 索引占用内存情况
/_cat/segments
查看所有支持的参数
curl -XGET ‘http://10.0.0.125:9200/_cat/segments’
curl ‘http://10.0.0.125:9200/_search?pretty’