当前位置:网站首页>Record a garbage collection and analysis of gceasy
Record a garbage collection and analysis of gceasy
2022-07-24 11:34:00 【Blizzard 2008】
background
Recently, the system always appears younggc Too many times , The time point is not unified , Take it GC Frequent GC journal , use GCeasy Look at the .
GCEasy brief introduction
gceasy It's a very good GClog Analysis tools , It's online , Free analysis , You can upload related gc Log for online analysis :https://gceasy.io/gc-index.jsp#banner
GCEasy Practical analysis
- GC Memory analysis :

Here is JVM Memory allocation , It means that the younger generation has been allocated 2.41gb Peak time allocation 2.4gb
Old age Already allocated 3.8gb Peak value 751.6mb, Total memory size
2. Key performance indicators 
Mainly throughput ( The proportion of normal business execution time , In fact, roughly speaking , Namely 1- subtract GC Of time )、 Delay time (GC Pause time ) form , The exhibition shows an average 、 Maximum delay time and at GC During logging , Proportion of different pause time .
In general , We GC The purpose of tuning , Is to improve throughput , Reduce GC Average pause time ( Reduce the maximum , Reduce the number of times ).
- GC Interactive view
This is this time period GC Comprehensive analysis curve of , Respectively GC The next pile 、GC Previous heap ,GC Time for 、 Number of bytes recycled 、 The younger generation 、 Old age 、 Distribution vs. promotion 、 Object tenure summary .
The first two are no longer expanded , Namely GC The size of the front and back stacks .
Let's take a look at GC Duration:GC Duration of , This is more interesting ( Select a part to zoom in ), The points in this figure actually cover the parallel time gc Time and stop the world Time for , It's total gc Time .
GC Number of bytes reclaimed :
The selected part can still be enlarged , And a dot represents one gc Size of recycled bytes , It can be seen that 10:22-10:24gc Quite frequently , But the recovery efficiency is also low , It will be found later that the reason is this moment , The allocation space of the young generation is very small .
Young generation size :
Allocated space and gc The size of the front and back , It can be seen that the allocated space is 22-23 The score is very small , And all GC The front is covered with ,GC Later, it was recycled .
Old generation size :
ditto , Illustrates the 22-23 Of the young generation are assigned to the era , Nearly 3.8g, But the old generation does not occupy much , Need to observe the reason .
Distribution and promotion
According to the figure below , Promotion has not been very high .
Expected survivor zone size And Actual survivor area size :
This is actually related to a parameter we configured ::-XX:TargetSurvivorRatio ( Set up survivor The target usage of the zone )
desired survivor size = (survivor Area capacity * TargetSurvivorRatio)/100( In fact, that is survivor Multiply the capacity by this targetSurvivorRatio The ratio of the ) If you are interested, you can continue to see , Here I will not introduce more .

4.GC Statistics

I won't explain it one by one here :
The three pictures above : Number of bytes reclaimed 、GC Time for 、GC The average time , It can be seen that there is no fullgc( This heel G1 The characteristics of garbage collector ).
The following is GC The statistics of : The total GC frequency 、 Total bytes reclaimed 、 The total GC Time 、gc average time ...
5.GC Statistics of pause information 
6. Object statistics
The total size of the created object 、 Total promotion size 、 The rate of both .
It can be seen that the creation rate of this object is still quite high , Need to optimize .
7. Memory leak 、fullgc、 Long pause 
8. Safe point duration :
The safety point here actually refers to stop the world The timing of the , The time here actually refers to stop the world The total time of .
9.GC cause 
10. Object tenure summary 
summary
It's on it GCEasy The general analysis report , From this report , In fact, some problems have been found , For example, the rate of memory allocation 、 The total number of bytes allocated in memory is very high , It indicates that you need to optimize the number of objects created or the size of objects .
At a special point in time , I found that the young generation suddenly became very small , This time period will cause frequent younggc, It needs to be carefully analyzed further according to the business scenario , Why at that time GC The older generation allocates a lot of memory .
I hope this article can help you , I also hope to have a discussion with you .
边栏推荐
- 运算放大器 —— 快速复苏笔记[壹](参数篇)
- Leetcode 112. 路径总和
- 《Nature》论文插图复刻第3期—面积图(Part2-100)
- 【C】 Understanding C language variable scope and life cycle from memory
- Shell script
- 【反序列化漏洞-01】序列化与反序列化简介
- 07 [use of path and files classes]
- Text message verification of web crawler
- RetinaNet:Focal Loss for Dense Object Detection
- 【反序列化漏洞-02】PHP反序列化漏洞原理测试及魔术方法总结
猜你喜欢

Text message verification of web crawler

JMeter if controller
![MOS管 —— 快速复苏应用笔记(壹)[原理篇]](/img/a1/8427c9b1d0ea0cecce820816510045.png)
MOS管 —— 快速复苏应用笔记(壹)[原理篇]

Paging query of employee information of black maredge takeout

Ctfshow ThinkPHP topic 1
![Operational amplifier - Notes on rapid recovery [II] (application)](/img/fd/e12f43e23e6ec76c2b44ce7813e204.png)
Operational amplifier - Notes on rapid recovery [II] (application)

What is the charm of CSDN members? What's the use of him?
什么是云原生,云原生技术为什么这么火?

字符串——344.反转字符串

Idea runs the wordcount program (detailed steps)
随机推荐
IT圈中的Bug的类型与历史
离散分布常用公式及应用场景
Video playback | how to become an excellent reviewer of international journals in the field of Geoscience and ecology?
《Nature》论文插图复刻第3期—面积图(Part2-100)
SSH跨平台终端工具tabby推荐
What is cloud native? Why is cloud native technology so popular?
Grep actually uses ps/netstat/sort
生信周刊第37期
什么是云原生,云原生技术为什么这么火?
Fiddler packet capture tool summary
2 万字详解,吃透 ES!
Detailed explanation of stat function
[TA frost wolf umay - "hundred people plan] Figure 3.3 surface subdivision and geometric shader large-scale grass rendering
Blue Bridge Cup provincial match training camp - Calculation of date
运算放大器 —— 快速复苏笔记[壹](参数篇)
Shell script
【10】团队协作和跨团队协作
【10】 Teamwork and cross team collaboration
The difference between YPbPr and YCbCr
Directional crawling Taobao product name and price (teacher Songtian)