0

I got this error on trying to get the Java search process UP(start a java process). I am setting the address space using the RLIMIT_AS.

Please help me to get past this error.

I have doubts about the VM Arguements. (See below). Is there any way to get past this issue without changing the configurations. (VM Arguements)

A fatal error has been detected by the Java Runtime Environment:

java.lang.OutOfMemoryError: requested 16 bytes for CHeapObj-new. Out of swap space?

Internal Error (allocation.inline.hpp:39), pid=16994, tid=1097390400 Error: CHeapObj-new

JRE version: 6.0_21-b06 Java VM: Java HotSpot(TM) 64-Bit Server VM (17.0-b16 mixed mode linux-amd64 ) If you would like to submit a bug report, please visit: http://java.sun.com/webapps/bugreport/crash.jsp


--------------- T H R E A D ---------------

Current thread (0x00000000489a7800): JavaThread "main" [_thread_in_vm, id=17043, stack(0x000000004158d000,0x000000004168e000)]

Stack: [0x000000004158d000,0x000000004168e000], sp=0x00000000416897f0, free space=3f10000000000000018k

VM state:not at safepoint (normal execution)

VM Mutex/Monitor currently owned by a thread: None

Heap PSYoungGen total 38208K, used 24989K [0x00002aaae8f80000, 0x00002aaaeba20000, 0x00002aab03a20000) eden space 32768K, 76% used [0x00002aaae8f80000,0x00002aaaea7e7518,0x00002aaaeaf80000) from space 5440K, 0% used [0x00002aaaeb4d0000,0x00002aaaeb4d0000,0x00002aaaeba20000) to space 5440K, 0% used [0x00002aaaeaf80000,0x00002aaaeaf80000,0x00002aaaeb4d0000) PSOldGen total 87424K, used 0K [0x00002aaab3a20000, 0x00002aaab8f80000, 0x00002aaae8f80000) object space 87424K, 0% used [0x00002aaab3a20000,0x00002aaab3a20000,0x00002aaab8f80000) PSPermGen total 21248K, used 10141K [0x00002aaaae620000, 0x00002aaaafae0000, 0x00002aaab3a20000) object space 21248K, 47% used [0x00002aaaae620000,0x00002aaaaf007410,0x00002aaaafae0000)

VM Arguments: jvm_args: -Xms128M -Xmx1280M -D.config=path -D.home=path1 -D .logfile=path2 java_command: com. .base.Server Launcher Type: SUN_STANDARD

OS:CentOS release 5.5 (Final)

uname:Linux 2.6.18-194.el5 #1 SMP Fri Apr 2 14:58:14 EDT 2010 x86_64 libc:glibc 2.5 NPTL 2.5 rlimit: STACK 10240k, CORE 1000001k, NPROC 24576, NOFILE 4096, AS 1835008k load average:1.87 0.45 0.22

CPU:total 2 (1 cores per cpu, 1 threads per core) family 6 model 46 stepping 6, cmov, cx8, fxsr, mmx, sse, sse2, sse3, ssse3, sse4.1, sse4.2, popcnt

Memory: 4k page, physical 2959608k(2057540k free), swap 4096532k(4096532k free)

vm_info: Java HotSpot(TM) 64-Bit Server VM (17.0-b16) for linux-amd64 JRE (1.6.0_21-b06), built on Jun 22 2010 01:10:00 by "java_re" with gcc 3.2.2 (SuSE Linux)

time: Tue Mar 22 03:08:27 2011 elapsed time: 5 seconds

Kara
  • 6,115
  • 16
  • 50
  • 57
Rajath
  • 215
  • 5
  • 13
  • Are you intentionally setting -Xmx to 1280 meg? Does you machine have this much RAM - if it doesn't, is the amount of physical RAM plus swap space greater than 1280 Meg? – DaveH Mar 22 '11 at 11:49
  • I don’t even own a machine with less RAM than that anymore. – Bombe Mar 22 '11 at 11:51
  • The memory details are: Memory: 4k page, physical 2959608k(2057540k free), swap 4096532k(4096532k free) – Rajath Mar 22 '11 at 15:09
  • Actually what I get is an intermittent error. Sometimes the java process gets started correctly and some times it will display the above error. My RAM size if 3GB and swap size is 4GB. I am trying to do rlimit_as with the softlimit as 1.75GB. Despite this the java process gives the above error.(intermittent) – Rajath Mar 22 '11 at 15:23

1 Answers1

1

What I did was google the Internal Error (allocation.inline.hpp:39) mesage and found this page http://forums.oracle.com/forums/thread.jspa?messageID=5203404 suggesting the swap space limit was causing the problem (even it shouldn't do so) after removing the limit, the problem went away.

Peter Lawrey
  • 525,659
  • 79
  • 751
  • 1,130
  • Actually what I get is an intermittent error. Sometimes the java process gets started correctly and some times it will display the above error. My RAM size if 3GB and swap size is 4GB. I am trying to do rlimit_as with the softlimit as 1.75GB. Despite this the java process gives the above error.(intermittent) I have to use the limits just to give the process boundary for the processes. – Rajath Mar 22 '11 at 15:22
  • If your soft limit is 1.75 GB, you might want to limit your heap to 1 GB or less as the JVM needs more than just heap memory to run. Additionally you might get greater memory efficiency from using a 32-bit JVM or `-XX:+UseCompressedOops` on a 64-bit JVM. – Peter Lawrey Mar 22 '11 at 16:11
  • Another option might be to buy more memory as 8 GB doesn't cost as much as it used to. ;) – Peter Lawrey Mar 22 '11 at 16:12