Foros de discusión

Classes doesn't gets unloaded why??

Azhar Mohammed, modificado hace 9 años.

Classes doesn't gets unloaded why??

Junior Member Mensajes: 59 Fecha de incorporación: 1/12/14 Mensajes recientes
Hi All,

I have a problem with the liferay server after successfully staring the server the server runs about 4 hrs and fails to respond,.
Before i had permgen space and heap issues i Solved it using VISUAL VM tool,..

I set value as -Xms1024M -Xmx1024M -XXemoticonermSize=512M -XX:MaxPermSize=512M(For heap and permgen)

But i dont know how to solve this class loading issue,.
In that tool it showing more 28,00 classes getting loaded (that's really huge),. I dont think this could be exact issue, If yes what should i do??.
I am seeking help from you Experts,.

Regards,
Azhar
thumbnail
Miroslav Ligas, modificado hace 9 años.

RE: Classes doesn't gets unloaded why??

Regular Member Mensajes: 152 Fecha de incorporación: 29/07/14 Mensajes recientes
Is this a prod or dev machine? Create few thread dumps of the JVM and compare them. Search for loon running threads. Also have a look at JVM GC how often is it running.
Other thing to considerer is to have a look at a monitoring tool something like http://newrelic.com/application-monitoring
Azhar Mohammed, modificado hace 9 años.

RE: Classes doesn't gets unloaded why??

Junior Member Mensajes: 59 Fecha de incorporación: 1/12/14 Mensajes recientes
Hi Miroslav Ligas,

Thanks for responding ,.

Is this a prod or dev machine? Create few thread dumps of the JVM and compare them. Search for loon running threads. Also have a look at JVM GC how often is it running.


Its Prodmachine,. Windows 2008 server,. Tomcat 7.0.57 liferay 6.2 ce ga2,. Ram 4 Gb,. Java 1.7.0_25 (I hear that there are some issues with 1.7 in liferay is that true?? or solved ??)
I have registered for that tool i will test it but could you suggest some other suggestion like java opts for optimizing -xmx ClassUnoladEnabled what this do??

Thanks,
Azhar
thumbnail
David H Nebinger, modificado hace 9 años.

RE: Classes doesn't gets unloaded why??

Liferay Legend Mensajes: 14919 Fecha de incorporación: 2/09/06 Mensajes recientes
Classes will not get unloaded automagically. Instances will get unloaded, but there is such a cost for class loading that they'll stick around longer than the individual instances.

No, there are no issues now w/ java 1.7.
Azhar Mohammed, modificado hace 9 años.

RE: Classes doesn't gets unloaded why??

Junior Member Mensajes: 59 Fecha de incorporación: 1/12/14 Mensajes recientes
Hi David,

Thanks again for responding,.
From your point of view what could be the problem,. and what will you give as suggestion,.

Waitng for your reply,
thumbnail
David H Nebinger, modificado hace 9 años.

RE: Classes doesn't gets unloaded why??

Liferay Legend Mensajes: 14919 Fecha de incorporación: 2/09/06 Mensajes recientes
Honestly it sounds more like you're suffering some sort of memory leak. Throwing more memory at it will extend things, but not solve your problem. Instead of looking at the count of loaded classes, try to get a handle on the objects that are loaded into memory, find out what is using it all.

Look for some obvious targets, i.e. big arrays or objects stored in a session variable, etc.
Azhar Mohammed, modificado hace 9 años.

RE: Classes doesn't gets unloaded why??

Junior Member Mensajes: 59 Fecha de incorporación: 1/12/14 Mensajes recientes
Thanks for the suggestion i will find out the culprits,.

Thanks David