zoukankan      html  css  js  c++  java
  • 使用MAT分析JVM内存溢出

    1、简介

    一键式分析JVM内存。

    帮助我们查找内存泄漏和减少内存消耗。使用内存分析工具从众多的对象中进行分析,快速的计算出在内存中对象的占用大小,看看是谁阻止了垃圾收集器的回收工作,并可以通过报表直观的查看到可能造成这种结果的对象。

    2、下载安装

    在eclipse商场里面查找mat(Memory Analyzer)或者下载完整版[https://eclipse.org/mat/downloads.php]

    3、获取dump

    tomcat 产生heapdump文件配置 - 备忘收集 - ITeye博客
    http://jiangsha.iteye.com/blog/1576355

    jvm-堆快照(获取hprof文件)jmap -dump:format=b,file=xxx.hprof  pid
    https://www.jianshu.com/p/6b70ecec2f56

    7 个抓取 Java Thread Dumps 的方式
    https://my.oschina.net/dabird/blog/691692

    4、导入使用

    分析java进程假死 - - ITeye博客
    http://bijian1013.iteye.com/blog/2271600

    使用 Eclipse Memory Analyzer 进行堆转储文件分析
    https://www.ibm.com/developerworks/cn/opensource/os-cn-ecl-ma/index.html

    5、分析

    官方:

    生成dump文件:

    Help - Eclipse Platform
    http://help.eclipse.org/kepler/index.jsp?topic=%2Forg.eclipse.mat.ui.help%2Ftasks%2Facquiringheapdump.html

    Help - Eclipse Platform
    http://help.eclipse.org/kepler/index.jsp?topic=%2Forg.eclipse.mat.ui.help%2Fgettingstarted%2Fbasictutorial.html

  • 相关阅读:
    docker nginx无法连通php
    docker查看ip
    使用docker-compose部署nginx
    docker启动服务---------------nginx+php
    docker下安装kafka和kafka-manager
    docker启动服务---------------kafka+zookeeper
    docker将镜像推送到阿里云
    Docker常用命令
    docker-compose编写示例
    docker启动服务
  • 原文地址:https://www.cnblogs.com/stevenlii/p/8716369.html
Copyright © 2011-2022 走看看