LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   killall sleep to kill both foreground and background sleep processes? (https://www.linuxquestions.org/questions/linux-newbie-8/killall-sleep-to-kill-both-foreground-and-background-sleep-processes-4175664322/)

mintner 11-15-2019 01:08 PM

killall sleep to kill both foreground and background sleep processes?
 
Can I use killall sleep to kill all the foreground and background sleep processes or do I need to follow individual steps like
#kill%
#kill%1

rtmistler 11-15-2019 02:03 PM

You should try each of various ways, the results will be very evident.

JeremyBoden 11-15-2019 06:17 PM

The killall command, despite its name, doesn't necessarily kill (terminate) anything. ;)

Code:

killall -s STOP command
will pause all your processes running 'command'
Code:

killall -s CONT command
will resume all your processes running 'command'
Code:

killall -l
Will give a list of possible killing actions...

berndbausch 11-15-2019 07:10 PM

Quote:

Originally Posted by mintner (Post 6058143)
Can I use killall sleep to kill all the foreground and background sleep processes

Yes if you are root. To be safe, use killall -9.


All times are GMT -5. The time now is 01:28 PM.