M
mikesmith813
I have a Java server application that consistantly throws an "OutOfMemoryError: Requested array size exceeds VM limit" and crashes about every 70 hours.
I'm running on Java 1.7 release 45 with a beefy 18 CPU Linux Server with lots of memory. My max heap is set to 50GB and using the new G1GC collector.Profiling with JVisualVM shows that the app is not using more than half of the heap ever and PermSpace looks fine.
Clearly, something is trying to allocate an array of an incorrect huge sizebut I can't determine what. My code creates objects and sends across JMX but the objects are already allocated in memory and handed to JMX at Exception time. I'm wondering if this is a JMX bug but I cannot find anything online. Any thoughts/ideas are appreciated! Stack trace below:
Job_Executor6:class com.sun.jmx.remote.opt.util.JobExecutor java.lan.OutOfMemoryError: Requested array size exceeds VM limit
at java.util.Arrays.copyOf(Unknown Source)
at java.io.ByteArrayOutputStream.grow(Unknown Source)
at java.io.ByteArrayOutputStream.ensureCapacity(Unknown Source)
at java.io.ByteArrayOutputStream.write(Unknown Source)
at java.ibjectOutputStream$BlockDataOutputStream.drain(Unknown Source)
at java.ibjectOutputStream$BlockDataOutputStream.setBlockDataMode(Unknown Source)
at java.ibjectOutputStream.writeObject0(Unknown Source)
at java.ibjectOutputStream.writeObject(Unknown Source)
at com.sun.jmx.remote.generic.ObjectWrappingImpl.wrap(ObjectWrappingImpl.java:30)
at java.management.remote.generic.ServerIntermediary$RequestHandler.handleNotifyReqMessage(ServerIntermediary.java:683)
at java.management.remote.generic.ServerIntermediary$RequestHandler.execute(ServerIntermediary.java:626)
at java.management.remote.generic.ServerSynchroMessageConnectionImpl$RemoteJob.run(ServerSynchroMessageConnectionImpl.java:266)
at com.sun.jmx.remote.opt.util.ThreadService$ThreadServiceJob.run(ThreadService.java:208)
at com.sun.jmx.remote.opt.util.JobExecutor.run(JobExecutor.java:59)
I'm running on Java 1.7 release 45 with a beefy 18 CPU Linux Server with lots of memory. My max heap is set to 50GB and using the new G1GC collector.Profiling with JVisualVM shows that the app is not using more than half of the heap ever and PermSpace looks fine.
Clearly, something is trying to allocate an array of an incorrect huge sizebut I can't determine what. My code creates objects and sends across JMX but the objects are already allocated in memory and handed to JMX at Exception time. I'm wondering if this is a JMX bug but I cannot find anything online. Any thoughts/ideas are appreciated! Stack trace below:
Job_Executor6:class com.sun.jmx.remote.opt.util.JobExecutor java.lan.OutOfMemoryError: Requested array size exceeds VM limit
at java.util.Arrays.copyOf(Unknown Source)
at java.io.ByteArrayOutputStream.grow(Unknown Source)
at java.io.ByteArrayOutputStream.ensureCapacity(Unknown Source)
at java.io.ByteArrayOutputStream.write(Unknown Source)
at java.ibjectOutputStream$BlockDataOutputStream.drain(Unknown Source)
at java.ibjectOutputStream$BlockDataOutputStream.setBlockDataMode(Unknown Source)
at java.ibjectOutputStream.writeObject0(Unknown Source)
at java.ibjectOutputStream.writeObject(Unknown Source)
at com.sun.jmx.remote.generic.ObjectWrappingImpl.wrap(ObjectWrappingImpl.java:30)
at java.management.remote.generic.ServerIntermediary$RequestHandler.handleNotifyReqMessage(ServerIntermediary.java:683)
at java.management.remote.generic.ServerIntermediary$RequestHandler.execute(ServerIntermediary.java:626)
at java.management.remote.generic.ServerSynchroMessageConnectionImpl$RemoteJob.run(ServerSynchroMessageConnectionImpl.java:266)
at com.sun.jmx.remote.opt.util.ThreadService$ThreadServiceJob.run(ThreadService.java:208)
at com.sun.jmx.remote.opt.util.JobExecutor.run(JobExecutor.java:59)