In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-29 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/02 Report--
This article introduces you how to view jvm information in linux, the content is very detailed, interested friends can refer to, hope to be helpful to you.
1. Jmap
This command is used to view the heap dump of jvm processes on the current system, including the number of objects and the amount of memory occupied by objects.
How to use: first use jps to view the process id
Use jmap-dump:live,file=b.map 22467 to generate a java heap dump snapshot for the live process
Use jmap-heap PID to generate details of the java heap
Use jmap-histo PID to generate information about objects in the java heap, including the quantity and the amount of space occupied
2. Jstat
It is mainly used to monitor the garbage collection of heap size and jvm, especially the monitoring of gc. If full gc occurs in the old years, it is likely to cause memory leaks.
You can see the percentage of space usage on the new generation survivor S0, survivor S1 heap, the percentage of space usage of the new generation Eden in the heap, the percentage of the old Old space, the percentage of memory usage, the statistical times of the new generation Yong gc, the time spent by the new generation gc, the number of full gc, the time spent, the total gc time of the current process. It should be noted here that full gc is very representative. Full gc times and time indicators can very well show system performance problems, these two indicators are very large, to a large extent, it shows that there are problems in the program, garbage can not be recycled all the time
3. Jstack
First use top to view the processes in the system that consume more cpu, and then use top-p PID-H to view the threads in the current process that consume more cpu. Get the thread pid that consumes more cpu, convert it to hexadecimal first, and finally use jstack pid | grep hexadecimal thread id.
Jstack-pid can be used to analyze the process.
This is the end of the information on how to view jvm in linux. I hope the above content can be helpful to you and learn more knowledge. If you think the article is good, you can share it for more people to see.
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.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.