Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Memory parameter description and configuration of jvm

2025-02-28 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/03 Report--

This article mainly introduces "the description and configuration of memory parameters of jvm". In daily operation, I believe many people have doubts about the description and configuration of memory parameters of jvm. The editor consulted all kinds of materials and sorted out simple and easy-to-use methods of operation. I hope it will be helpful to answer the doubts of "description and configuration of memory parameters of jvm". Next, please follow the editor to study!

Description of memory parameters of 1.jvm:

-the initial heap value requested when Xms:jvm starts, defaults to 1x64 but less than 1G of the operating system's physical memory; (128m for machines with 8G memory); by default, when the memory of the free heap is greater than 70%, the JVM will be reduced to the size set by-Xms

The maximum heap value that can be applied for by-Xmx:JVM defaults to 1G of powerless memory but less than 1G; (1G for machines with 8G memory); by default, JVM increases Heap to the size specified by-Xmx when the free heap memory is less than 40%.

-XX:MinHeapFreeRation: specifies the scaling ratio of heap memory

-Xmn: configuring the size of the younger generation will have a greater impact on system performance; the value of-Xmx minus its value in the older generation; (large objects and large array objects will be allocated directly in the old age)

-XX:PretenureSizeThreshold=? Used to configure the definition of large objects, the default is zero; more than its value is considered to be large objects

-Xss: java the Stack size of each thread; after jdk5, the stack size of each thread is 1m; decreasing this value can generate more threads under the same powerless memory; OS has a limit on the field within a process, which is about 3000 to 5000.

-initialization size of the XX:PermSize persistent generation

-maximum memory size of the XX:MaxPermSize persistence generation:

-XX+UseSerialGc: the default GC mode of jvm, which is more efficient, but may bring a standstill to the application.

-XX:+UseParallelGC: parallel GC with high efficiency, complex algorithm and high consumption

-XX:parallelGCThreads: the number of threads in the parallel collector

-XX:+UseCMSCompactAtFullCollection: defragment the memory after full gc

-XX:CMSFullGCsBeforeCompaction=?: used to control how many times defragmentation occurs after FullGC

Parameter classification:

-Standard parameter;-X: non-standard parameter;-XX: non-Stable parameter

At this point, the study of "memory parameter description and configuration of jvm" is over. I hope to be able to solve your doubts. The collocation of theory and practice can better help you learn, go and try it! If you want to continue to learn more related knowledge, please continue to follow the website, the editor will continue to work hard to bring you more practical articles!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report