You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by mickhayes <mi...@gmail.com> on 2012/06/11 08:55:15 UTC

Re: JVM Heap full & ATMQ crashed

Can you share your broker start-up java options to being with? -Xmx?

60-70 messages per second, you say. What size each message?


There is very useful information on the management of memory resources of a
broker here: 
http://activemq.apache.org/javalangoutofmemory.html


-----
Michael Hayes B.Sc. (NUI), M.Sc. (DCU), SCSA SCNA 

--
View this message in context: http://activemq.2283324.n4.nabble.com/JVM-Heap-full-ATMQ-crashed-tp4653138p4653148.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: Re: JVM Heap full & ATMQ crashed

Posted by mickhayes <mi...@gmail.com>.
It's most likely that you need to have -d64 on the command line to get a
64-bit hotspot VM.

I still think you are using a 32-bit JVM. Maybe the version of the JRE is
1.6.0_27-b04?

About the options... from java -help:

     -d32          use a 32-bit data model if available

    -d64          use a 64-bit data model if available

3G Heapspace is more than you need for your messaging load.
I would change the -Xmx to 500M maximum.

Finally, I say, use the defaults unless you have reason to do otherwise.
For sure, you don't need to change from the default GC behaviour in 1.6.0
for this messaging case.







-----
Michael Hayes B.Sc. (NUI), M.Sc. (DCU), SCSA SCNA 

--
View this message in context: http://activemq.2283324.n4.nabble.com/JVM-Heap-full-ATMQ-crashed-tp4653138p4653191.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: Re: JVM Heap full & ATMQ crashed

Posted by mickhayes <mi...@gmail.com>.
I would add -d64 to make that explicit.

My comments on using Hotspot defaults for GC stand, unless you have good
motivation otherwise.
I note you trigger CMS very early, when 70% full rather than the default
92%... is there a reason for that?

If you are sending enormous messages, I suggest using JMS to send a pointer
to the file system from which  the messages can be retrieved.

Finally, I would ask what version of java? Newer is *much better* in the
area of GC.

-----
Michael Hayes B.Sc. (NUI), M.Sc. (DCU), SCSA SCNA 

--
View this message in context: http://activemq.2283324.n4.nabble.com/JVM-Heap-full-ATMQ-crashed-tp4653138p4653163.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: Re: JVM Heap full & ATMQ crashed

Posted by mickhayes <mi...@gmail.com>.
The -Xmx is large for a 32-bit JVM. Is it 32-bit?
Native + Heap + Non-heap must be less that 4G in that case, and 3G has
already been used for Heap.

To isolate the problem, I would be inclined to 

- leave the JVM GC behaviour at default unless otherwise needed, 
- set the maxheapspace to 2G or lower
- run in a 64-bit JVM if 3G heapspace is really needed.

What size is each message?


 



-----
Michael Hayes B.Sc. (NUI), M.Sc. (DCU), SCSA SCNA 

--
View this message in context: http://activemq.2283324.n4.nabble.com/JVM-Heap-full-ATMQ-crashed-tp4653138p4653156.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.