Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Uninstalling via remove --cask --force obs then autoremove and cleanup still leave leftovers /obs-studio/ and crap in /SystemExtensions/ #170602

Closed
6 tasks done
alemens opened this issue Apr 4, 2024 · 3 comments
Labels

Comments

@alemens
Copy link

alemens commented Apr 4, 2024

Verification

Description of issue

brew remove --cask --force obs then brew autoremove then brew cleanup still leave leftovers so rm -rf ~/Library/Application\ Support/obs-studio/ after all still have crap in /Library/SystemExtensions/E0244F9B-9E54-406A-B59C-116650454FBB/com.obsproject.obs-studio.mac-camera-extension.systemextension and /System/Volumes/Data/Library/SystemExtensions/E0244F9B-9E54-406A-B59C-116650454FBB/com.obsproject.obs-studio.mac-camera-extension.systemextension can’t be deleted

Command that failed

sudo rm -f /Library/SystemExtensions/E0244F9B-9E54-406A-B59C-116650454FBB/com.obsproject.obs-studio.mac-camera-extension.systemextension/Contents/Info.plist

Output of command with --verbose --debug

rm: /Library/SystemExtensions/E0244F9B-9E54-406A-B59C-116650454FBB/com.obsproject.obs-studio.mac-camera-extension.systemextension/Contents/Info.plist: Operation not permitted

Output of brew doctor and brew config

`brew doctor`
Your system is ready to brew.

`brew config`
HOMEBREW_VERSION: 4.2.16-69-gfcc190b
ORIGIN: https://github.com/Homebrew/brew
HEAD: fcc190b5c659d9c74454011f094de568789ef8fd
Last commit: 8 hours ago
Core tap HEAD: bfe8e71e3328538b3ff2f55182b6fb75fe3a7513
Core tap last commit: 19 minutes ago
Core tap JSON: 04 Apr 02:47 UTC
Core cask tap HEAD: 1d92b1d863df35b1d72e246c5cbc188dfb261b61
Core cask tap last commit: 65 minutes ago
Core cask tap JSON: 04 Apr 02:47 UTC
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CASK_OPTS: []
HOMEBREW_DISPLAY: /private/tmp/com.apple.launchd.lyXPfsMiKa/org.xquartz:0
HOMEBREW_MAKE_JOBS: 8
HOMEBREW_SORBET_RUNTIME: set
Homebrew Ruby: 3.1.4 => /usr/local/Homebrew/Library/Homebrew/vendor/portable-ruby/3.1.4/bin/ruby
CPU: octa-core 64-bit kabylake
Clang: 15.0.0 build 1500
Git: 2.44.0 => /usr/local/bin/git
Curl: 8.4.0 => /usr/bin/curl
macOS: 14.4.1-x86_64
CLT: 15.3.0.0.1.1708646388
Xcode: N/A

Output of brew tap

/
@bevanjkay
Copy link
Member

To remove all the files associated with a cask, you need to pass the --zap flag to brew uninstall.
e.g. brew uninstall --zap obs

Regarding the system extension, as far as I know this is a MacOS system-level limitation, and this would be the same case were you to remove the application the usual way (it is not a Homebrew-specific limitation).

@alemens alemens closed this as completed Apr 4, 2024
@alemens
Copy link
Author

alemens commented Apr 4, 2024

Bypassing MacOS system-level limitation with Disabling and Enabling System Integrity Protection then solved with

  • run csrutil disable in a Recovery mode terminal
  • restart normal and deleting unwanted folders inside /SystemExtensions/
  • run csrutil enable again in a Recovery mode terminal then restart normal

thanks to @bevanjkay for the e.g. brew uninstall --zap obs and clear explanation

@bevanjkay
Copy link
Member

Thanks for confirming @alemens

For anyone stumbling upon this, please read Apple's documentation about System Integrity Protection here, before disabling it.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 5, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants