Last active
January 30, 2020 00:27
-
-
Save omundy/8549b38367a0d207c64992dd9cda737b to your computer and use it in GitHub Desktop.
KILL_SOPHOS
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
#!/bin/bash | |
# orginal https://gist.github.com/lukebussey/70fe3b245c7b55fa41300670d2698e54 | |
# make file and run sudo chmod +x kill_sophos | |
# delete all files | |
sudo rm -R /Library/Sophos* | |
sudo rm -R /Library/Application\ Support/Sophos* | |
sudo rm -R /Library/Preferences/com.sophos.* | |
sudo rm /Library/LaunchDaemons/com.sophos.* | |
sudo rm /Library/LaunchAgents/com.sophos.* | |
sudo rm -R /Library/Extensions/Sophos* | |
sudo rm -R /Library/Caches/com.sophos.* | |
sudo rm -R /Library/Sophos\ Anti-Virus* | |
# added this later | |
kill $(ps aux | grep 'SophosAutoUpdate' | awk '{print $2}') | |
kill $(ps aux | grep 'Sophos' | awk '{print $2}') | |
kill $(ps aux | grep '.sophos' | awk '{print $2}') | |
# report all that are left | |
ps -ax | grep Sophos | |
# manual prompt for me to remember kill code | |
echo "..." | |
echo "Now manually kill all that are left with:" | |
echo " sudo kill -9 <PID>" | |
echo "..." | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment