33

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?

The Login Items page in the macOS Ventura System Settings

5 Answers5

29

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).

nohillside
  • 100,768
Glyph
  • 1,542
  • 1
    (You do need to xattr -d com.apple.quarantine dumpBTM after downloading it, but presumably if you're manually slinging binaries around, you can manage that) – Glyph Mar 29 '23 at 02:55
  • 1
    Thank you! sfltool dumpbtm revealed that apps in Trash still appear on the "Allow in the Background" list. – Aaron Adams May 02 '23 at 08:30
  • 4
    Once you run sfltool dumpbtm, how do you remove items from the list? – BallpointBen Jul 07 '23 at 04:14
  • I did run across documentation for the sfltool in a section on platform deployment: https://support.apple.com/en-ca/guide/deployment/depdca572563/web – Clinton Chau Jan 05 '24 at 17:56
13

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
Ax_
  • 253
  • 1
    Which of these are reflected as "Allow in the background" items? – nohillside Dec 15 '22 at 08:13
  • Hi @nohillside you find "Allow in the background" items into /Library/LaunchAgents those are Applications that launch on User Login – Ax_ Dec 16 '22 at 12:43
  • Problem is that I have "Allow in the background" items which show up in none of the LaunchAgents/LauchDaemons directories (and don't even have an (i) icon to click on). – nohillside Dec 16 '22 at 13:10
  • Paste into a terminal the lines you see in my answer, then share those output and also a screenshot of your Login Items Allow in the Background, for sure is somewhere there – Ax_ Dec 17 '22 at 00:35
  • 1
    For the people who are in this thread and have deleted apps and files from the above mentioned directories. Make sure you empty your trash too :) – vivideradicator Apr 09 '23 at 20:40
9

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.

benwiggy
  • 35,635
4

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/
-1

For short, sfltool dumpbtm show info. sfltool resetbtm reset database (to clean up uninstalled but still listed apps)