Created
January 24, 2024 00:36
-
-
Save Nexarian/da324290dcff10a66129da374260c4e3 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
#!/usr/bin/env bash | |
function kill_all() { | |
process=$1 | |
for i in $(ps aux | grep $process | tr -s ' ' | cut -d" " -f 2) | |
do | |
sudo kill -9 $i | |
done | |
} | |
sudo -v | |
kill_all "xrdp" | |
kill_all "Xvnc" | |
kill_all "xorgxrdp_helper" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment