[Logo] Terracotta Discussion Forums (LEGACY READ-ONLY ARCHIVE)
  [Search] Search   [Recent Topics] Recent Topics   [Members]  Member Listing   [Groups] Back to home page 
[Register] Register / 
[Login] Login 
[Expert]
Can't allocate more than 183MB on IBM Java VM  XML
Forum Index -> BigMemory
Author Message
kborgul

neo

Joined: 09/25/2012 06:59:55
Messages: 2
Offline

I run my sample program using Bigmemory with parameter: -XX:MaxDirectMemorySize=512m, but I can't create OffHeapStore greater than 183 MB (otherwise I am receiving OOME). I am using IBM Java VM.

>java -version
java version "1.6.0"
Java(TM) SE Runtime Environment (build pwi3260_26sr1-20111114_01(SR1))
IBM J9 VM (build 2.6, JRE 1.6.0 Windows XP x86-32 20111113_94967 (JIT enabled, A
OT enabled)
J9VM - R26_Java626_SR1_20111113_1649_B94967
JIT - r11_20111028_21230
GC - R26_Java626_SR1_20111113_1649_B94967
J9CL - 20111113_94967)
JCL - 20111112_01
klalithr

consul

Joined: 01/23/2011 10:58:07
Messages: 489
Offline

Can you explain what you are trying to do. Are you using the new BigMemory Go project. Are you using the Server Array. Why are you only allocating 512MB of space - Why not use the heap instead ?

Karthik Lalithraj (Terracotta)
lorban

jedi

Joined: 01/08/2010 13:09:16
Messages: 101
Location: CET
Offline

According to the version info you posted, it looks like you're using a 32-bit JVM.

This would definitely explain why you can only allocate very little offheap as the virtual address space is limited to only 4GB. Check this link to know more about the limitations of Big Memory with 32-bit JVMs: http://ehcache.org/documentation/user-guide/bigmemory#using-offheapstore-with-32-bit-jvms

I'm highly recommending you to use a 64-bit JVM for Big Memory or you're going to be so constrained that it won't help much.

Ludovic Orban (Terracotta engineer)
kborgul

neo

Joined: 09/25/2012 06:59:55
Messages: 2
Offline

Yes, I think it is related to 32-bit VM and different behavior of IBM VM.
Oracle 32-bit VM has no problem with creating eg. 500MB offheap cache with MaxDirectMemorySize=1024m
lijie

journeyman

Joined: 09/04/2012 23:10:13
Messages: 19
Offline

And check this link for Allocating Direct Memory in the JVM: http://ehcache.org/documentation/configuration/bigmemory#configuration

NOTE: Direct Memory and Off-heap Memory Allocations

To accommodate server communications layer requirements, the value of maxDirectMemorySize must be greater than the value of maxBytesLocalOffHeap. The exact amount greater depends upon the size of maxBytesLocalOffHeap. The minimum is 256MB, but if you allocate 1GB more to the maxDirectMemorySize, it will certainly be sufficient. The server will only use what it needs and the rest will remain available.
 

 
Forum Index -> BigMemory
Go to:   
Powered by JForum 2.1.7 © JForum Team