A blog for Linux Lovers.

Archive for the ‘Jboss’ Category

Posted by sibu on March 13, 2015

GC overhead limit exceeded ….!!!

java.lang.OutOfMemoryError: GC overhead limit exceeded

All Java applications include a built-in Garbage Collection (GC). In many other programming languages, the developers need to manually allocate and free memory regions so that the freed memory can be reused. Java applications on the other hand only need to allocate memory. Whenever a particular space in memory is no longer used a separate process called Garbage Collection clears the memory for you.

The “java.lang.OutOfMemoryError: GC overhead limit exceeded” error means that GC has been trying to free the memory but is pretty much unable to get any job done. By default it happens when the JVM is spending more than 98% of the total time in GC. In addition, after GC less than 2% of the heap is recovered.

So – the “java.lang.OutOfMemoryError: GC overhead limit exceeded” error will be displayed when your application has exhausted pretty much all the available memory and GC has repeatedly failed to clean it.
Cause of java.lang.OutOfMemoryError

When failing with the “java.lang.OutOfMemoryError: GC overhead limit exceeded” error, the JVM is signalling that your application is spending too much time in garbage collection with little to show for it. By default the JVM is configured to throw this error if you are spending more than 98% of the total time in GC and after the GC less than 2% of the heap is recovered.

What would happen if this GC overhead limit was not present?  Note that the “GC overhead limit exceeded” error is thrown only when 2% of the memory was freed after several GC cycles.

This means that the little amount GC was able to clean will be quickly filled again thus forcing GC to restart the cleaning process again.This forms a vicious cycle where the CPU is 100% busy with GC and no actual work can be done. End users of the application are facing extreme slowdowns – operations which used to be completed in milliseconds are now likely to take minutes to finish.

Posted by sibu on October 1, 2014

Diff between .java vs .class

.java file is Java source code, in a plain text that programmers edit.

java compiler converts your java code into byte-code (.class)

Example: javac

a new file filename.class is created by the Java compiler. This is a file containing Java bytecode, which is essentially a file that the Java interpreter can read. That’s what makes Java multi-platform. You can transport this .class file from Windows to Linux and run:

java filename

you will be getting the same result.

Posted by sibu on February 17, 2011

Jboss and its versions


JBoss Application Server (or JBoss AS) is a free software/open-source Java EE-based application server. Because it is Java-based, the JBoss application server operates cross-platform: usable on any operating system that Java supports. JBoss AS was developed by JBoss, now a division of Red Hat.


JBoss AS 4.0, a Java EE 1.4 application server, features an embedded Apache Tomcat 5.5 servlet container. It supports any Java Virtual Machine between versions 1.4 and 1.6.

JBoss AS 4.2 also functions as a Java EE 1.4 application server, but deploys Enterprise JavaBeans 3.0 by default. It requires the Java Development Kit version 5. Tomcat 5.5 comes bundled with it.

JBoss AS 5.1, released as of 2009, operates as a Java EE 5 application server. It is a minor update of the major release JBoss AS 5.0

Boss AS 6.0,[3] the current stable release and an unofficial implementation of Java EE 6, was released on December 28, 2010.