当前位置:网站首页>JVM memory configuration parameter GC log
JVM memory configuration parameter GC log
2022-08-04 22:19:00 【Learning Micro Station】
GC log:
For JVM memory configuration parameters:
-Xmx10240m -Xms10240m -Xmn5120m -XXSurvivorRatio=3
-Xmx10240m: represents the maximum heap
-Xms10240m: represents the minimum heap, initial allocation
-Xmn5120m: represents the new generation
-XXSurvivorRatio=3: represents Eden:Survivor = 3 According to the Generation-Collection algorithm (the algorithm used by most JVMs at present), the heap memory is generally divided into several different areas according to the life cycle of the object.Divided into Eden, two Survivors; Calculate the size of Survivor, Eden: Survivor = 3, the total size is 5120, 3x+x+x=5120 x=1024
Most of the new generation needs to be recycled, using the Copying algorithm, fast!
Most of the old age do not need to be recycled, and the Mark-Compact algorithm is used
You can use this command to set the java running memory when running the jar program:
java -Xms2048m -Xmx2048m -Xmn512m -jar XXXX.jar
https://blog.csdn.net/m0_47914176/article/details/123706946
-Xss1m: The stack size in the HotSpot version is fixed and does not support expansion.java.lang.StackOverflowError
The general method call is difficult to appear, if it appears, it may be infinite recursion
-XX:MetaspaceSize=256M: The initialization threshold for triggering FullGC when Metaspace is expanded, which is also the minimum threshold
-XX:MetaspaceSize: Set the size of the metaspace
-XX:MaxMetaspaceSize: Set the maximum size of the metaspace
-XX:+UseParNewGC: will be automatically activated with concurrent lifetime generation garbage collection
-XX:+UseConcMarkSweepGC: concurrent mark sweep, i.e. use CMS collector
-XX:+PrintGCDetails: print gc details
-Xloggc:gc.log: Output the GC log to the gc.log file
The -XX:+HeapDumpOnOutOfMemoryError parameter indicates that when the JVM occurs OOM, the DUMP file is automatically generated
When using -XX:HeapDumpPath configuration, you need to ensure that the folders of the directory exist, because it will not help you to create non-existing directories when dumping files everywhere.
边栏推荐
- 力扣24-两两交换链表中的节点——链表
- UDP communication
- Oracle使用expdp和impdp导出导入数据
- ANT1.7 download and configuration method
- OC-归档(序列化)(了解的不多 没细看)
- 【线性代数02】AX=b的2种解释和矩阵乘法的5种视角
- [Linear Algebra 02] 2 interpretations of AX=b and 5 perspectives of matrix multiplication
- ES6高级-async的用法
- Rt-thread [三] link.lds链接脚本详解
- Leaflets of three bouquet of roses
猜你喜欢
随机推荐
年薪40W测试工程师成长之路,你在哪个阶段?
UDP communication
Detailed usage of LocalDateTime
Lecture 2 Software Life Cycle
七夕特制:《牛郎会织女》
Hardware factors such as CPU, memory, and graphics card also affect the performance of your deep learning model
Deep Learning RNN Architecture Analysis
ES6高级-Promise的用法
[larave]关于laravel使用form submit()不能获取值问题
rk3399 驱动屏参的几种方式
rk3399-9.0 first-level and second-level dormancy
MQTT[一]基础知识介绍
Open source summer | Cloud server ECS installs Mysql, JDK, RocketMQ
Analysis and treatment of Ramnit infectious virus
打卡第 1 天:正则表达式学习总结
Flutter 实现背景图片毛玻璃效果
BUG | 接口返回异常数据
Unknown point cloud structure file conversion requirements
论文解读(PPNP)《Predict then Propagate: Graph Neural Networks meet Personalized PageRank》
【社媒营销】WhatsApp Business API:您需要知道的一切









