|
From: art a <art...@ya...> - 2005-04-20 05:54:22
|
any comment on my question? Thank you. --- art a <art...@ya...> wrote: > Hello. > > I am trying to use the Wrapper to run my AdventNet > WebNMS application as service on Windows machines. I > am using integration method 2 for this. > > Starting and stopping the service from a batch file > or > from Windows Services manager works correctly but I > am > having problem stopping the service when the machine > is shutdown. > > Advennet is using > com.adventnet.nms.startnms.NmsMainBE > class to start the server and > com.adventnet.nms.util.StandAloneShutDown to stop. > > It looks like that these two classes are merely > invoking other components of the WebNMS server and > when the machine is shutdown the class > StandAloneShutDown returns immediately without > waiting > for the invoked processes to completely terminate. > > Are there any configuration properties to set to > tell > the wrapper to sleep for a few seconds while waiting > for other processes to stop to avoid windows from > rebooting right away? > > Also when starting the server, the service is > already > marked "Started" eventhough the server is not yet > ready to take client connections. Is there a way to > make wrapper wait a little longer, until the all > server components are properly initialized, before > reporting the STARTED status? > > Can this be resolved if i implement integration > method > 3 and use a classloader to manually load NmsMainBE > and > StandAloneShutDown classes? > > Below is the log data when machine is shutdown; > > =================== > DEBUG | wrapperp | 2005/04/14 18:08:38 | send a > packet PING : ping > INFO | jvm 1 | 2005/04/14 18:08:39 | Received a > packet PING : ping > INFO | jvm 1 | 2005/04/14 18:08:39 | Send a > packet PING : ok > DEBUG | wrapperp | 2005/04/14 18:08:39 | read a > packet PING : ok > DEBUG | wrapper | 2005/04/14 18:08:39 | Got ping > response from JVM > INFO | wrapper | 2005/04/14 18:08:39 | User > logged > out. Ignored. > INFO | jvm 1 | 2005/04/14 18:08:39 | Got > Control > Signal 5->202 > INFO | jvm 1 | 2005/04/14 18:08:39 | Handled > signal > INFO | jvm 1 | 2005/04/14 18:08:39 | Processing > control event(WRAPPER_CTRL_LOGOFF_EVENT) > DEBUG | wrapperp | 2005/04/14 18:08:43 | send a > packet PING : ping > INFO | jvm 1 | 2005/04/14 18:08:43 | Received a > packet PING : ping > INFO | jvm 1 | 2005/04/14 18:08:43 | Send a > packet PING : ok > DEBUG | wrapperp | 2005/04/14 18:08:43 | read a > packet PING : ok > DEBUG | wrapper | 2005/04/14 18:08:43 | Got ping > response from JVM > INFO | wrapper | 2005/04/14 18:08:44 | User > logged > out. Ignored. > INFO | jvm 1 | 2005/04/14 18:08:44 | Got > Control > Signal 5->202 > INFO | jvm 1 | 2005/04/14 18:08:44 | Handled > signal > INFO | jvm 1 | 2005/04/14 18:08:44 | Processing > control event(WRAPPER_CTRL_LOGOFF_EVENT) > STATUS | wrapper | 2005/04/14 18:08:46 | Machine is > shutting down. > DEBUG | wrapper | 2005/04/14 18:08:46 | > wrapperStopProcess(0) called. > INFO | jvm 1 | 2005/04/14 18:08:46 | Got > Control > Signal 6->203 > INFO | jvm 1 | 2005/04/14 18:08:46 | Handled > signal > INFO | jvm 1 | 2005/04/14 18:08:46 | Processing > control event(WRAPPER_CTRL_SHUTDOWN_EVENT) > INFO | jvm 1 | 2005/04/14 18:08:46 | > WrapperManager.stop(0) called by thread: > Wrapper-Control-Event-Monitor > INFO | jvm 1 | 2005/04/14 18:08:46 | Send a > packet STOP : 0 > DEBUG | wrapperp | 2005/04/14 18:08:46 | read a > packet STOP : 0 > DEBUG | wrapper | 2005/04/14 18:08:46 | JVM > requested a shutdown. (0) > DEBUG | wrapper | 2005/04/14 18:08:46 | > wrapperStopProcess(0) called. (IGNORED) > DEBUG | wrapper | 2005/04/14 18:08:46 | Sending > stop > signal to JVM > DEBUG | wrapperp | 2005/04/14 18:08:46 | send a > packet STOP : NULL > INFO | jvm 1 | 2005/04/14 18:08:47 | Received a > packet STOP : > INFO | jvm 1 | 2005/04/14 18:08:47 | Thread, > Wrapper-Control-Event-Monitor, handling the shutdown > process. > INFO | jvm 1 | 2005/04/14 18:08:47 | calling > listener.stop() > INFO | jvm 1 | 2005/04/14 18:08:48 | > INFO | jvm 1 | 2005/04/14 18:08:48 | > INFO | jvm 1 | 2005/04/14 18:08:48 | Trying to > shut down KM-NET VIEWER Web Edition Server > ================================ > > At this point other processes didn't get a chance to > stop their tasks gracefully. > > This is how a successful shutdown looks like: > > ================================ > INFO | jvm 1 | 2005/04/14 18:01:08 | Received a > packet PING : ping > INFO | jvm 1 | 2005/04/14 18:01:08 | Send a > packet PING : ok > DEBUG | wrapperp | 2005/04/14 18:01:08 | read a > packet PING : ok > DEBUG | wrapper | 2005/04/14 18:01:08 | Got ping > response from JVM > DEBUG | wrapper | 2005/04/14 18:01:09 | Working > directory set to: ../ > STATUS | wrapper | 2005/04/14 18:01:09 | Stopping > the > KM-NET VIEWER Web Edition 2 service... > DEBUG | wrapper | 2005/04/14 18:01:09 | > ServiceControlHandler(1) > DEBUG | wrapper | 2005/04/14 18:01:09 | > SERVICE_CONTROL_STOP > DEBUG | wrapper | 2005/04/14 18:01:09 | > wrapperStopProcess(0) called. > DEBUG | wrapper | 2005/04/14 18:01:09 | Sending > stop > signal to JVM > DEBUG | wrapperp | 2005/04/14 18:01:09 | send a > packet STOP : NULL > INFO | jvm 1 | 2005/04/14 18:01:09 | Received a > packet STOP : > INFO | jvm 1 | 2005/04/14 18:01:09 | Thread, > Wrapper-Connection, handling the shutdown process. > INFO | jvm 1 | 2005/04/14 18:01:09 | calling > listener.stop() > INFO | jvm 1 | 2005/04/14 18:01:09 | > INFO | jvm 1 | 2005/04/14 18:01:09 | > INFO | jvm 1 | 2005/04/14 18:01:09 | Trying to > shut down KM-NET VIEWER Web Edition Server > INFO | wrapper | 2005/04/14 18:01:14 | Waiting to > stop... > INFO | wrapper | 2005/04/14 18:01:19 | Waiting to > stop... > INFO | wrapper | 2005/04/14 18:01:24 | Waiting to > stop... > INFO | jvm 1 | 2005/04/14 18:01:24 | > INFO | jvm 1 | 2005/04/14 18:01:24 | Schedulers > Stopped successfully > INFO | jvm 1 | 2005/04/14 18:01:24 | > INFO | jvm 1 | 2005/04/14 18:01:24 | All Shut > Down Observers Notified > INFO | jvm 1 | 2005/04/14 18:01:24 | > INFO | jvm 1 | 2005/04/14 18:01:24 | Process : > NmsSAServerFE [ Stopped ] > INFO | jvm 1 | 2005/04/14 18:01:24 | Process : > ExampleFE [ Stopped ] > INFO | jvm 1 | 2005/04/14 18:01:24 | Process : > UserConfigProcessFE [ Stopped ] > INFO | jvm 1 | 2005/04/14 18:01:24 | Process : > PolicyFE [ Stopped ] > INFO | jvm 1 | 2005/04/14 18:01:24 | Process : > ConfigFE [ Stopped ] > INFO | jvm 1 | 2005/04/14 18:01:24 | Process : > TopoFE [ Stopped ] > INFO | jvm 1 | 2005/04/14 18:01:24 | Process : > PollFE [ Stopped ] > INFO | jvm 1 | 2005/04/14 18:01:24 | Process : > AlertFE > INFO | jvm 1 | 2005/04/14 18:01:24 | > > [ Stopped ] > INFO | jvm 1 | 2005/04/14 18:01:24 | Process : > === message truncated === __________________________________ Do you Yahoo!? Make Yahoo! your home page http://www.yahoo.com/r/hs |