Skip to main content

Glassfisg JVM exits no jvm.log

13 replies [Last post]
najmi
Offline
Joined: 2003-06-17
Points: 0

Dear Colleagues,

I am seeing a strange new problem recently with GF 3.1. When I do a
certain client request to my web app deployed in GF the server JVM
process dies / crashes / exits for no apparent reason. To compound the
problem I see no jvm.log in the
~/glassfish-3.1/glassfish/domains/domain1/logs directory. I start GF
from within my NetBeans 7.0 maven project using its DEBUG action which
does an in-place deploy and starts GF.

Any idea why there is no jvm.log in the usual place (nor anywhere else
under my ~ directory) and why GF dies / crashes / exits with no trace?

--
Regards,
Farrukh Najmi

Web: http://www.wellfleetsoftware.com

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
tmueller
Offline
Joined: 2005-10-31
Points: 0

One possible reason for not getting a jvm.log file is that the default
JVM option that causes this to be created was removed in 3.1 because it
is incompatible with other JVMs. In GF 3.0, this option is as follows:

-XX:LogFile=${com.sun.aas.instanceRoot}/logs/jvm.log

To add it into a 3.1 install, run:

asadmin create-jvm-options
'-XX\:LogFile=${com.sun.aas.instanceRoot}/logs/jvm.log'

(note: the : has to be escaped with \)

Tom

najmi
Offline
Joined: 2003-06-17
Points: 0

On 12/15/2011 10:06 AM, Tom Mueller wrote:
> One possible reason for not getting a jvm.log file is that the default
> JVM option that causes this to be created was removed in 3.1 because
> it is incompatible with other JVMs. In GF 3.0, this option is as follows:
>
> -XX:LogFile=${com.sun.aas.instanceRoot}/logs/jvm.log
>
> To add it into a 3.1 install, run:
>
> asadmin create-jvm-options
> '-XX\:LogFile=${com.sun.aas.instanceRoot}/logs/jvm.log'
>
> (note: the : has to be escaped with \)
>
> Tom
>

Hi Tom,

Thank you for your help.

Above did not do seem to work (no jvm.log file produced). Note that I am
currently testing with GF 3.1.2 latest promoted build (Dec 13th).
What am I missing?

Below are all the jvm-options in my domain.xml file:

-client
-Djava.awt.headless=true
-Djavax.management.builder.initial=com.sun.enterprise.v3.admin.AppServerMBeanServerBuilder
-XX:+UnlockDiagnosticVMOptions
-Djava.endorsed.dirs=${com.sun.aas.installRoot}/modules/endorsed${path.separator}${com.sun.aas.installRoot}/lib/endorsed
-Djava.security.policy=${com.sun.aas.instanceRoot}/config/server.policy
-Djava.security.auth.login.config=${com.sun.aas.instanceRoot}/config/login.conf
-Dcom.sun.enterprise.security.httpsOutboundKeyAlias=s1as
-Djavax.net.ssl.keyStore=${com.sun.aas.instanceRoot}/config/keystore.jks
-Djavax.net.ssl.trustStore=${com.sun.aas.instanceRoot}/config/cacerts.jks
-Djava.ext.dirs=${com.sun.aas.javaRoot}/lib/ext${path.separator}${com.sun.aas.javaRoot}/jre/lib/ext${path.separator}${com.sun.aas.instanceRoot}/lib/ext
-Djdbc.drivers=org.apache.derby.jdbc.ClientDriver
-DANTLR_USE_DIRECT_CLASS_LOADING=true
-Dcom.sun.enterprise.config.config_environment_factory_class=com.sun.enterprise.config.serverbeans.AppserverConfigEnvironmentFactory
-Dosgi.shell.telnet.port=6666
-Dosgi.shell.telnet.maxconn=1
-Dosgi.shell.telnet.ip=127.0.0.1
-Dgosh.args=--nointeractive
-Dfelix.fileinstall.dir=${com.sun.aas.installRoot}/modules/autostart/
-Dfelix.fileinstall.poll=5000
-Dfelix.fileinstall.log.level=2
-Dfelix.fileinstall.bundles.new.start=true
-Dfelix.fileinstall.bundles.startTransient=true
-Dfelix.fileinstall.disableConfigSave=false
-XX:NewRatio=2
-XX:LogFile=${com.sun.aas.instanceRoot}/logs/jvm.log
-XX:PermSize=512m
-XX:MaxPermSize=1024m
-Xms200m
-Xmx1500m
-XX:+CMSClassUnloadingEnabled

--
Regards,
Farrukh Najmi

Web: http://www.wellfleetsoftware.com

Gustavo Henriqu...
Offline
Joined: 2011-10-27
Points: 0

I also have problems with Glassfish server JVM process dies / crashes /
exits for no apparent reason.

najmi
Offline
Joined: 2003-06-17
Points: 0

In my case I am now pretty certain that the problem is a classic
StackOverflowError due to recursion gone amuck. I wish I had the jvm log
so I would not have spent hours coming to this realization. So JVM crash
is expected behavior for my errant code but where in the world is the
jvm.log file?

On 12/15/2011 01:37 PM, Gustavo Henrique Orair wrote:
> I also have problems with Glassfish server JVM process dies / crashes
> / exits for no apparent reason.
>

678 Guest 1
Offline
Joined: 2012-03-21
Points: 0

After several months I am again seeing Glassfish 3.1.2 exit during heavy
transaction load leaving no jvm.log file anywhere that I can find.

In my domain.xml file I have the following:

-XX:LogFile=${com.sun.aas.instanceRoot}/logs/jvm.log

This is a serious reliability issue and I would be very grateful if someone
from the GF team could help. The scneario is reproducable on demand at
present and I would be glad to work with someone from teh GF dev team to
narrow this down. Thanks for your help.

 

--

[Message sent by forum member 'najmi']

View Post: http://forums.java.net/node/874299

najmi
Offline
Joined: 2003-06-17
Points: 0

After several months I am again seeing Glassfish 3.1.2 exit during heavy transaction load leaving no jvm.log file anywhere that I can find.

In my domain.xml file I have the following:

<jvm-options>-XX:LogFile=${com.sun.aas.instanceRoot}/logs/jvm.log</jvm-options>

This is a serious reliability issue and I would be very grateful if someone from the GF team could help. The scneario is reproducable on demand at present and I would be glad to work with someone from teh GF dev team to narrow this down. Thanks for your help.

ss141213
Offline
Joined: 2005-03-30
Points: 0

AFAIK, you also need

-XX:+LogVMOutput

as I wrote once here [1].

Sahoo

[1]
http://weblogs.java.net/blog/ss141213/archive/2012/02/23/getting-verbose...

On Wednesday 21 March 2012 11:49 PM, forums@java.net wrote:
> After several months I am again seeing Glassfish 3.1.2 exit during heavy
> transaction load leaving no jvm.log file anywhere that I can find.
>
> In my domain.xml file I have the following:
>
> -XX:LogFile=${com.sun.aas.instanceRoot}/logs/jvm.log
>
>
> This is a serious reliability issue and I would be very grateful if
> someone
> from the GF team could help. The scneario is reproducable on demand at
> present and I would be glad to work with someone from teh GF dev team to
> narrow this down. Thanks for your help.
>
>
>
>
> --
>
> [Message sent by forum member 'najmi']
>
> View Post: http://forums.java.net/node/874299
>
>

najmi
Offline
Joined: 2003-06-17
Points: 0

Thank you Sahoo! You are a life saver! That was it. I now have a jvm.log
file.

May I ask why these two options are not in the default domain.xml
generated during GF install?

-XX:LogFile=${com.sun.aas.instanceRoot}/logs/jvm.log
-XX:+LogVMOutput

Seems to me that would be the right thing to do.

On 03/21/2012 03:06 PM, Sahoo wrote:
> AFAIK, you also need
>
> -XX:+LogVMOutput
>
> as I wrote once here [1].
>
> Sahoo
>
> [1]
> http://weblogs.java.net/blog/ss141213/archive/2012/02/23/getting-verbose...
>
> On Wednesday 21 March 2012 11:49 PM, forums@java.net wrote:
>> After several months I am again seeing Glassfish 3.1.2 exit during heavy
>> transaction load leaving no jvm.log file anywhere that I can find.
>>
>> In my domain.xml file I have the following:
>>
>> -XX:LogFile=${com.sun.aas.instanceRoot}/logs/jvm.log
>>
>>
>> This is a serious reliability issue and I would be very grateful if
>> someone
>> from the GF team could help. The scneario is reproducable on demand at
>> present and I would be glad to work with someone from teh GF dev team to
>> narrow this down. Thanks for your help.

--
Regards,
Farrukh Najmi

Web: http://www.wellfleetsoftware.com

tmueller
Offline
Joined: 2005-10-31
Points: 0

Because these options cause the server to not be runnable with other
JVMs, specifically JRockit.

The following RFE was created to support JVM-specific options:
http://java.net/jira/browse/GLASSFISH-16247

A release for this hasn't been determined, but a vote for the RFE
couldn't hurt.

Tom

On 3/21/2012 2:29 PM, Farrukh Najmi wrote:
>
> Thank you Sahoo! You are a life saver! That was it. I now have a
> jvm.log file.
>
> May I ask why these two options are not in the default domain.xml
> generated during GF install?
>
> -XX:LogFile=${com.sun.aas.instanceRoot}/logs/jvm.log
>
> -XX:+LogVMOutput
>
> Seems to me that would be the right thing to do.
>
> On 03/21/2012 03:06 PM, Sahoo wrote:
>> AFAIK, you also need
>>
>> -XX:+LogVMOutput
>>
>> as I wrote once here [1].
>>
>> Sahoo
>>
>> [1]
>> http://weblogs.java.net/blog/ss141213/archive/2012/02/23/getting-verbose...
>>
>> On Wednesday 21 March 2012 11:49 PM, forums@java.net wrote:
>>> After several months I am again seeing Glassfish 3.1.2 exit during
>>> heavy
>>> transaction load leaving no jvm.log file anywhere that I can find.
>>>
>>> In my domain.xml file I have the following:
>>>
>>> -XX:LogFile=${com.sun.aas.instanceRoot}/logs/jvm.log
>>>
>>>
>>> This is a serious reliability issue and I would be very grateful if
>>> someone
>>> from the GF team could help. The scneario is reproducable on demand at
>>> present and I would be glad to work with someone from teh GF dev
>>> team to
>>> narrow this down. Thanks for your help.
>

najmi
Offline
Joined: 2003-06-17
Points: 0

Now that I have a JVM log I am still seeing GlassFish Server Open Source
Edition 3.1.2-b14
(build 14) jvm crash but there is no stack trace or error message in the
jvm log.

The problem occurs under heavy transaction load (SOAP and HTTP requests
to my webapp, database requests to my PostgresQL 9.x database server).

I realize the problem could be outside GF (e.g. in jdbc driver etc.).
Can any one suggest how to track this down?

On 03/21/2012 03:29 PM, Farrukh Najmi wrote:
>
> Thank you Sahoo! You are a life saver! That was it. I now have a
> jvm.log file.
>
> May I ask why these two options are not in the default domain.xml
> generated during GF install?
>
> -XX:LogFile=${com.sun.aas.instanceRoot}/logs/jvm.log
>
> -XX:+LogVMOutput
>
> Seems to me that would be the right thing to do.
>
> On 03/21/2012 03:06 PM, Sahoo wrote:
>> AFAIK, you also need
>>
>> -XX:+LogVMOutput
>>
>> as I wrote once here [1].
>>
>> Sahoo
>>
>> [1]
>> http://weblogs.java.net/blog/ss141213/archive/2012/02/23/getting-verbose...
>>
>> On Wednesday 21 March 2012 11:49 PM, forums@java.net wrote:
>>> After several months I am again seeing Glassfish 3.1.2 exit during
>>> heavy
>>> transaction load leaving no jvm.log file anywhere that I can find.
>>>
>>> In my domain.xml file I have the following:
>>>
>>> -XX:LogFile=${com.sun.aas.instanceRoot}/logs/jvm.log
>>>
>>>
>>> This is a serious reliability issue and I would be very grateful if
>>> someone
>>> from the GF team could help. The scneario is reproducable on demand at
>>> present and I would be glad to work with someone from teh GF dev
>>> team to
>>> narrow this down. Thanks for your help.
>

--
Regards,
Farrukh Najmi

Web: http://www.wellfleetsoftware.com

najmi
Offline
Joined: 2003-06-17
Points: 0

Experimenting some more I observe that no jvm log is ever created even when my webapp is dpeloyed in GlassFish Server Open Source Edition 3.1.2-b14 (build 14) and working fine. I have tried not setting the following in domain.xml:

<jvm-options>-XX:LogFile=${com.sun.aas.instanceRoot}/logs/jvm.log</jvm-options>

and instead setting it with asadmin create-jvm-options '-XX\:LogFile=/tmp/jvm.log'

Note I used /tmp for directory to avoid any problems with ${com.sun.aas.instanceRoot} variable resolution.

None of this seems to work and I do not get a jvm.log no matter what I do.

Can someone please tell me if they are seeing or not seeing this problem (no jvm.log file) with GF 3.1.2?

Is this a known issue? Shall I file a bug?

smithbr4
Offline
Joined: 2011-07-28
Points: 0

Najmi,
You have to have both of these JVM options for it to work, I have tested this on Glassfish 3.1.2 b23 and it works(as long as you are not running JRockit)

-XX:LogFile=${com.sun.aas.instanceRoot}/logs/jvm.log
-XX:+LogVMOutput

najmi
Offline
Joined: 2003-06-17
Points: 0

You are correct. Having both options fixes the problem when using sun JDKs. Thank you.