Find the damn outofmemoryerror.

Source: Internet
Author: User
Tags arrays

Seeing this pile of information, I think you should know what to do.

Main at
  java.lang.outofmemoryerror.<init> () V (
  at Java.util.Arrays.copyOfRange ([CII) [C ( at
  java.lang.string.<init> ([CII) V ( : 203) at
  java.lang.StringBuilder.toString () ljava/lang/string; (
  At Com.mkk.utils.GuidGeneratorTest.outOfMemory () V ( at
  Sun.reflect.NativeMethodAccessorImpl.invoke0 (Ljava/lang/reflect/method; Ljava/lang/object; [Ljava/lang/object;) Ljava/lang/object; (Native method)
  At Sun.reflect.NativeMethodAccessorImpl.invoke (ljava/lang/object;[ Ljava/lang/object;) Ljava/lang/object; (
  At Sun.reflect.DelegatingMethodAccessorImpl.invoke (ljava/lang/object;[ Ljava/lang/object;) Ljava/lang/object; (
  At Java.lang.reflect.Method.invoke (ljava/lang/object;[ Ljava/lang/object;) Ljava/lang/object; (

Increased memory, increased memory, memory overflow, so I set the


Reboot the server, not too long and outofmemoryerror

It's time to know the damn outofmemoryerror,

So, please add to java_opts


(Note: The red section is a path to the server, and when OutOfMemoryError is the JVM information is stored in the directory)

Restart the server again, look forward to the next OutOfMemoryError bar.

Yes, OutOfMemoryError again ...

Now, let's go to the/home/error catalogue. Is there a file generation similar to Java_pid6472.hprof, still large (good dozens of or hundreds of MB).

Now, it is recommended to download the mat (Memory Analyzer Tool) tool to see what stuff is running out of memory (and the Jvisualvm.exe tools that are available with JDK). Download Address:

Finally, find the source. To modify the code.

Related Article

E-Commerce Solutions

Leverage the same tools powering the Alibaba Ecosystem

Learn more >

Apsara Conference 2019

The Rise of Data Intelligence, September 25th - 27th, Hangzhou, China

Learn more >

Alibaba Cloud Free Trial

Learn and experience the power of Alibaba Cloud with a free trial worth $300-1200 USD

Learn more >

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.