Created
April 13, 2017 07:58
-
-
Save muhx/bbe5443b857348a51deba49f2791de82 to your computer and use it in GitHub Desktop.
Kill process contain defined string
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
for pid in $(ps -ef | awk '/some search/ {print $2}'); do kill -9 $pid; done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment