|
From: Richard E. <rem...@ed...> - 2004-03-08 15:30:41
|
Leif, Thank you for the explanation; the message: "JVM did not exit on request, terminated " refers to the fact that a previous request to stop the process failed and now it will be shutdown with a SIGKILL. We run load tests every night a multiple machine types. Every couple of days on one of our Linux boxes after running for a couple of hours we get the twin messages: JVM appears hung: Timed out waiting for signal from JVM. JVM did not exit on request, terminated one right after the other within milliseconds. The problem that arises after sending a SIGKILL to the process controlled by the wrapper is that that primary process has spawned secondary processes (not child processes) so that killing the primary with at SIGKILL does not kill the secondary process - shutdown hooks are registered but java will not execute them when a SIGKILL is received. In the file wrapper_unix.c in the function wrapperKillProcess() how about first signaling with at SIGTERM, wait a while and then a SIGKILL. That way the primary process' shutdown hook might run? Richard Leif Mortenson wrote: > Richard, > When are you seeing this message? Does it happen shortly after your > application > was launched (within 30 seconds) or after your app has been running for > a while? > > The first message "JVM appears hung: Timed out waiting for signal > from JVM." > is displayed when the Wrapper process first decides that there is a > problem with the > JVM. It then attempts to ask the JVM to shut itself down cleanly by > sending it a > stop command. This gives the JVM a chance to do any cleanup and shut > itself > down cleanly. > > If the JVM fails to shutdown on its own then the Wrapper will give up > and > forcibly kill it with a "kill -9". That is the message that you are > seeing: > "JVM did not exit on request, terminated " It is printed right after > the kill > command because at that point, the JVM has failed to exit. The kill > command > will always work because it is killing a child process. > > I assume that you digging into the code because you are having a > problem. > could you describe it? > > Cheers, > Leif > > Richard Emberson wrote: > >> I get the following in wrapper logs on linux (not windows or solaris): >> >> JVM appears hung: Timed out waiting for signal from JVM. >> JVM did not exit on request, terminated >> >> Looking through the code in wrapper_unix.c I see the following in the >> function wrapperKillProcess() : >> >> kill(jvmPid, SIGKILL); >> log_printf(WRAPPER_SOURCE_WRAPPER, LEVEL_ERROR, "JVM did not >> exit on request, terminated"); >> >> What does the message "JVM did not exit on request, terminated" mean? >> There is no test after the kill function is called to tell whether or >> not the JVM exited or not so how can one say that the JVM did not exit? >> >> Thanks. >> Richard > > > > > > ------------------------------------------------------- > This SF.Net email is sponsored by: IBM Linux Tutorials > Free Linux tutorial presented by Daniel Robbins, President and CEO of > GenToo technologies. Learn everything from fundamentals to system > administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click > _______________________________________________ > Wrapper-user mailing list > Wra...@li... > https://lists.sourceforge.net/lists/listinfo/wrapper-user > |