Skip to Main Content

Java APIs

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Is it possible to destroy process tree in Java?

843810Oct 28 2004 — edited Oct 28 2004
I am creating a process using Runtime.exec(). Newly created process spawns another process and that may spawn other processes. I want to kill all these child processes when my application exits.
Process.destroy() only kills the immediate child.
Is it possible in Java to kill process tree? or is there any other way of achieving it?

Thanks
Sudhan.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 25 2004
Added on Oct 28 2004
1 comment
592 views