0

I am getting the stack overflow error. How to take heap dump and know the reason?

  • 3
    you are getting a `stack` overflow, and you want a `heap` dump? – Eugene Aug 17 '18 at 09:41
  • https://stackoverflow.com/questions/12018675/making-a-memory-dump-of-java-application – user202729 Aug 17 '18 at 09:42
  • Is this VM argument (-XX:+HeapDumpOnOutOfMemoryError) works in case of stack overflow error too? – Kishan Aduka Aug 17 '18 at 09:45
  • Yes @Eugene. For OutOfMemoryError we can use -XX:+HeapDumpOnOutOfMemoryError in VM argument but in case of stack overflow error how to take heap dump? – Kishan Aduka Aug 17 '18 at 09:52
  • 3
    A heapdump is not going to help you. What you want is a stacktrace, which you probably already have, unless there's some exception handling interfering. – OhleC Aug 17 '18 at 10:07

0 Answers0