vmmap

windows server 2008 环境下,运行java程序,内存耗尽问题

独自空忆成欢 提交于 2021-02-13 20:49:15
经历的几天的分析,希望把自己学到的知识总结一下。 系统版本:Windows Server 2008 R2 Standard 系统类型:64bit 内存:32GB 程序:在系统上部署了solr,然后写5个线程不停的向solr查询。 问题现象:任务管理器中物理内存一直增长,最后到了99%。但是进程占用的内存加起来不到10G。 分析: 第一步:怀疑java程序内存溢出。 工具: jvisualvm与eclipse mat jvisualvm检测是否内存溢出,如果存在内存溢出,可以用用jmap导出dump文件,再用mat分析。mat可以分析到每个类占用的内存。网上有很多mat的使用资料,大家可以自己查询。 我使用了jdk自带的jvisualvm,在jdk bin目录下jvisualvm.exe检测内存。如下图: 通过上图,发现heap会收集的,所以不存在内存溢出。为了熟悉,jmap,mat工具,我自己导出dump文件,用mat也分析了一下。 第二步:进一步分析 如果程序没有内存溢出问题,那么内存被什么占用了呢? 分析工具: RamMap与VMMap RamMap 可以整体分析内存使用情况,VMMap可以精确到某个进程ID,他们都可以查看什么文件已经从磁盘映射到内存。 我用RAMMAP分析,发现大量的内存被Mapped File占用,点击Empty--Empty Working Sets

Is there any API for the command vmmap

≡放荡痞女 提交于 2019-12-11 00:32:06
问题 In the command line, i can use vmmap -v -purge 50554 to find the memory information of the process 50554, and get the output like below: VIRTUAL RESIDENT DIRTY SWAPPED VOLATILE NONVOL EMPTY REGION REGION TYPE SIZE SIZE SIZE SIZE SIZE SIZE SIZE COUNT (non-coalesced) =========== ======= ======== ===== ======= ======== ====== ===== ======= Accelerate.framework 256K 256K 256K 0K 0K 256K 0K 3 Activity Tracing 2048K 40K 40K 0K 0K 0K 0K 2 ...... VIRTUAL RESIDENT DIRTY SWAPPED ALLOCATION BYTES REGION

How do I get the information shown in vmmap programatically?

99封情书 提交于 2019-12-10 11:33:19
问题 As anyone who has watched the Mark Russovich talk "Mysteries of Memory Management Revealed" knows, the vmmap tool can show you things that count against your process limit (2GB on vanilla 32 bit windows) that few other tools seem to know about. I would like to be able to programmatically monitor my real total memory size (the one that's germane to the process limit) so I can at least log what's going on when I approach the process limit. Is there any information publicly available on how

How do I get the information shown in vmmap programatically?

二次信任 提交于 2019-12-06 09:01:52
As anyone who has watched the Mark Russovich talk "Mysteries of Memory Management Revealed" knows, the vmmap tool can show you things that count against your process limit (2GB on vanilla 32 bit windows) that few other tools seem to know about. I would like to be able to programmatically monitor my real total memory size (the one that's germane to the process limit) so I can at least log what's going on when I approach the process limit. Is there any information publicly available on how vmmap does this? ... Also, why is this information so darn hard to get?? Things I know about that (AFAIK)

What does “Private Data” define in VMMAP?

一曲冷凌霜 提交于 2019-12-05 22:11:48
问题 I am using VMMap to analyse Virtual/Process Address Space utilisation in my mixed mode (managed and unmanaged) application. I understand how the Windows VMM and the Virtual Memory API works, I understand how the Heap Memory API Works too. I have looked at the CRT implementation I am using (not in great detail) and (I think I - this could be my downfalling) understand how this uses the aforementioned Win32 APIs. I'm looking to understand what this "Private Data" stat is showing me. My