I have some mysterious entries in the Login Items > Allow in the Background section in the macOS Ventura System settings.
How can I find out more information about them, such as their command-line arguments?
I have some mysterious entries in the Login Items > Allow in the Background section in the macOS Ventura System settings.
How can I find out more information about them, such as their command-line arguments?
You can get much more verbose output about all startup items simultaneously on the command line with sfltool dumpbtm
. The output is fairly self-explanatory, but the tool itself seems almost completely undocumented.
Objective See has a slightly more featureful and documented version that is also open source (compiled binaries can be downloaded from the release page). That tool's README also explains the new consolidation of the various types of login items (LaunchAgents, LaunchDaemons, login items).
xattr -d com.apple.quarantine dumpBTM
after downloading it, but presumably if you're manually slinging binaries around, you can manage that)
sfltool dumpbtm
revealed that apps in Trash still appear on the "Allow in the Background" list.
Commented
May 2, 2023 at 8:30
sfltool dumpbtm
, how do you remove items from the list?
Commented
Jul 7, 2023 at 4:14
sfltool
in a section on platform deployment: support.apple.com/en-ca/guide/deployment/depdca572563/web
Commented
Jan 5 at 17:56
In my specific case the "Allow in the Background" login items are coming from /Library/LaunchAgents
Other login related are
Applications that run on Startup
ls -lah /Library/StartupItems
Property list (plist) items running on startup
ls -lah /Library/LaunchDaemons
ls -lah /System/Library/LaunchDaemons
Applications that launch on User Login
ls -lah /Library/LaunchAgents
ls -lah ~/Library/LaunchAgents
ls -lah /System/Library/LaunchAgents
Applications that run on a set schedule
crontab -l
Kernel Extensions
kextstat
Login and Logout Hooks
defaults read com.apple.loginwindow LoginHook
defaults read com.apple.loginwindow LogoutHook
/Library/LaunchAgents
those are Applications that launch on User Login
Some items in the list (but not all) have a 'circle i' info button: ⓘ which you can click to reveal their location in the Finder.
In addition to the LaunchAgents
and LaunchDaemons
folders in /Library
and ~/Library
, applications may have items inside their bundle, e.g. inside:
/Applications/AppName.app/Contents/Library/LoginItems/
/Applications/AppName.app/Contents/Library/LaunchAgents/
/Applications/AppName.app/Contents/Library/LaunchDaemons/
which show up in the list.
However, I still have some items whose location I have not been able to identify, so other locations may also be involved.
As to command-line arguments: it's unlikely that such executables will have documentation for users, so apart from calling them with --help
or similar, you'd have to search the binary for strings.
These items are launchd
Launch Daemons and Agents.
The linked documentation describes the location and format of their defining property list files. Launch Daemons and Agents defined in /System/Library
are not shown in the System Settings.
The relevant files can be found in the following locations:
/Library/LaunchDaemons/
~/Library/LaunchDaemons/
/Library/LaunchAgents/
~/Library/LaunchAgents/
For short,
sfltool dumpbtm
show info.
sfltool resetbtm
reset database (to clean up uninstalled but still listed apps)
sfltool resetbtm
. it removes all there Open at Login
items.
Commented
Nov 7, 2023 at 9:38
sfltool dumpbtm
, find and remove unwanted items. URL
and Executable Path
Commented
Nov 7, 2023 at 9:49
sfltool resetbtm
and they all came back when I rebooted