I really want to know what your 'server' was and how it was running, was
being stopped and restarted. I think you may have given me enough clues...
>
> How I am Restart My Server?
> I am using Wrapper and Script to Restart the server.
> I will attach my scripts to your mailID.
From the files sent directly - I can now see you are using "Java Service
Wrapper" (JSW) to have your server running as a windows service or a
daemon process? The script passed is 'sh', so you are running under
cygwin or a unix environment?
I don't know if we need to know, but it might be useful to know your
operating system - my apologies if this turns out not to be the case!
>
> What ever your mentioning it might be the case in my application.In my
> case i am calling in different classes.Means in one component it
> called and at the same time it's calling from the other component also
> Rt?
Sorry I can't see what you are saying here.
I think your restart is failing because the Timer singleton that is
instanced out of the call to DefaultTimer.getTimer has had it's cancel
method called as part of the shutdown/stop, but it still exists as you
restart and thus issues the message you are seeing.
Perhaps we should be setting the reference to this Timer to be null at
shutdown and are not?
Perhaps you need to stop the whole service (and thus the JVM), rather
than just the server that is running inside the JVM that JSW provides?
This might be where your operating system matters...
... does your stop command stop the JVM, or just the Q2 server running
inside it?
On *windows*, doing a :-
net stop yourservicename
followed by
net start yourservicename
might work, as I would hope everything is closed and restarted.
I'm afraid my script reading and comprehension needs work; so cannot see
what is actually happening for you. Perhaps your JSW output combined
with your Q2 log might hold the clues?
--
Mark
> I ran the same script previously also.I didn't face any problems.But
> recently only i gave problem.Tried to reproduce the same in my Testing
> Environment.
I think that when this issue occurs, the components running within your
JVM have not stopped cleanly and thus the JVM may not have exited. If
this is the case, then the Timer object that is hanging around also
remains and causes the issue you are seeing at restart.
> My Production Environment is in Solaris.
Ok, and your test environment also Solaris?
> You are suggesting to do like as
> "'setting the reference to this Timer to be null at
> shutdown and are not?''
Can you first confirm that the JVM has cleanly exited after your stop
and *before* your start? The JSW website indicates that a restart
option is available; either way, can you confirm that you see:-
jvm n | stop(0)
in your JSW output?
If you could also check that every deployed jPos component also stops
cleanly?
If you can confirm that the JVM is not exiting completely or that a jPos
component is not stopping, then we should seek to address the reason for
this first; as it may be something specific to your application.
Can you post your JSW and Q2 logs please? If you can look keep the size
as small as possible?
Does this issue occur if you start, wait, restart?
Does your application need to be running and doing it's work for a while
for the issue to occur?
The information should be in your logs, we just need to find the detail
needed.
--
Mark