• Uncategorized

About linux : Is-there-a-simple-method-to-kill-a-process-and-all-subprocess-in-linux-system

Question Detail

When I want to kill a process using the pid in linux, its subprocess still existes. I hope to kill all process using one command.

Question Answer

Suggesting command pkill -p PID pattern .

See more documentation here.

Check out process groups:

Assuming you want to do this from a shell?
If you do a kill and make the top process negative it does a killpg under the covers and sends the signal to all the processes in the group.

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.