# Manual heap dump in elasticsearch not working

**URL:** <https://discuss.elastic.co/t/manual-heap-dump-in-elasticsearch-not-working/244299>\
**Category:** Elasticsearch\
**Created:** [August 9, 2020, 10:12am UTC](https://discuss.elastic.co/t/manual-heap-dump-in-elasticsearch-not-working/244299 "2020-08-09T10:12:08Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Prashanth\_123](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/prashanth_123/32/48423_2.png) [@Prashanth\_123](https://discuss.elastic.co/u/Prashanth_123)\
**Post date:** [August 9, 2020, 10:12am UTC](https://discuss.elastic.co/t/manual-heap-dump-in-elasticsearch-not-working/244299/1 "2020-08-09T10:12:09Z")

</div>

Over last few days noticed more GC in my es server and was trying to take  
a look at heap .. My ES is running on EC2 , with Amazon linux AMI OS.  
When i tried to take heap dump with  
"jmap -dump:format=b,file=/var/lib/elasticsearch/test.hprof 3529" getting  
..............  
3529: Unable to open socket file: target process not responding or HotSpot VM not loaded  
The -F option can be used when the target process is not responding  
..............

If tried with -F "jmap -F -dump:format=b,file=/var/lib/elasticsearch/test.hprof 3529" getting  
...............  
Attaching to process ID 3529, please wait...  
Error attaching to process: java.lang.RuntimeException: can't determine target's VM version : field "\_reserve\_for\_allocation\_prefetch" not found in type Abstract\_VM\_Version  
sun.jvm.hotspot.debugger.DebuggerException: java.lang.RuntimeException: can't determine target's VM version : field "\_reserve\_for\_allocation\_prefetch" not found in type Abstract\_VM\_Version  
at sun.jvm.hotspot.HotSpotAgent.setupVM(HotSpotAgent.java:435)  
at sun.jvm.hotspot.HotSpotAgent.go(HotSpotAgent.java:305)  
at sun.jvm.hotspot.HotSpotAgent.attach(HotSpotAgent.java:140)  
at sun.jvm.hotspot.tools.Tool.start(Tool.java:185)  
at sun.jvm.hotspot.tools.Tool.execute(Tool.java:118)  
..........................  
even tried by switching to elasticsearch user "sudo -su elasticsearch" no luck.  
Does any one have solution for it?.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [September 6, 2020, 10:12am UTC](https://discuss.elastic.co/t/manual-heap-dump-in-elasticsearch-not-working/244299/2 "2020-09-06T10:12:19Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
