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

JVM monitoring tool

2025-03-13 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

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

1. Jconsole and jvisualVM:

Jconsole and jvisualVM can monitor the performance and resource consumption of java applications through the GUI interface. JvisualVM is more powerful than jconsole. They are located in the JDK_HOME/bin directory.

two。 Before using jconsole and jvisualVM, you need a simple configuration, as follows:

Modify the bin/catalina.sh file of the server tomcat by adding before Execute The Requested Command:

JAVA_OTPS= "- ip of server-Djava.rmi.server.hostname= virtual machine

-Dcom.sun.management.jmxremote.port=1234

-Dcom.sun.management.jmxremote.authenticate=false

-Dcom.sun.management.jmxremote.ssl=false "

Complete configuration and restart tomcat

3. Jconsole

After the jconsole has completed the above configuration, you can connect directly:

Start-run-jconsole, and select local:

Start-run-jconsole, select remote:

You can check the heap memory usage. If there is a memory leak, you can see it here.

Deadlocks can be detected.

4. JvisualVM

Jvisual has two connection methods. The connection mode configuration of JMX is the same as that of jconsole.

Start-run-jvisualVM, select local or remote

You can check the heap memory usage. If there is a memory leak, you can see it here.

Memory leak-generate heap Dump

Detect deadlock-generate thread Dump

The reason why it is powerful is because there are plug-ins

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

Internet Technology

Wechat

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

12
Report