launchctl
- LaunchAgents
/System/Library/LaunchAgents/*.plist
(system built-in apps)/Library/LaunchAgents/*.plist
(system apps)-
~/Library/LaunchAgents/*.plist
(user apps) -
LaunchDaemons
/System/Library/LaunchDaemons/*.plist
(system built-in apps)/Library/LaunchDaemons/*.plist
(system apps)-
~/Library/LaunchDaemons/*.plist
(user apps) -
These services appear under "Login Items" > "Allow in the Background"
launchctl print system
launchctl print system | grep enabled # enabled services
disable
launchctl disable system/com.apple.ManagedClientAgent.enrollagent
launchctl disable system/com.apple.mdmclient.daemon
launchctl disable system/com.apple.devicemanagementclient.teslad
unload
- Disable a daemon
launchctl unload "/Library/LaunchDaemons/org.nixos.nix-daemon.plist"
launchctl unload "~/Library/LaunchAgents/com.koekeishiya.yabai.plist."
launchctl unload -w /System/Library/LaunchAgents/com.apple.rcd.plist
load
launchctl load -w /System/Library/LaunchAgents/com.apple.rcd.plist