On 08/12/2013 10:00 AM, Yumin Qi wrote:
- What if it the SA also crashes, will it launch a third VM then a
fourth etc?
Definitely don't want to see this happened in a chain. The solution
may use a property such as
sun.jvm.hotspot.DumpLoadedClasses.dumpingInProcess=true to pass into
SA process, at launching call, check if the property set, if set, do
not fork. When SA process died, it will generate core file first, note
the target process still waiting for its exit, so when target exit,
the core file (if both use default core as name) will be override by
target. The SA process will only leave a hs_err_pid*.log file. (? read
such property in handler is possible?)
There is still the chance that the VM may have crashed before the
properties are initialized. Maybe use environment variables instead?
- Ioi