launchd 正在尝试调用已卸载的“SCFinderPlugin.plugin”

Jas*_*man 3 launchd macos

在某些时候,我曾尝试在 Mac OS 10.6 上安装和使用“SCPlugin”,但发现它不是我需要的。

根据安装文档,它说要从这些位置删除 .plugin 文件:

  • /Library/Contextual Menu Items/SCFinderPlugin.plugin
  • /Library/Receipts/SCPlugin.pkg
  • /Applications/SCToolbarButton
  • /usr/local/bin/svn (如果您安装了可选链接)

但是卸载几个月后,我仍然看到我的控制台报告错误:

com.apple.launchd.peruser.501[93]   (org.tigris.scplugin.launch[29882])  Exited with exit code: 1
com.apple.launchd.peruser.501[93]   (org.tigris.scplugin.launch)         Throttling respawn: Will start in 10 seconds
com.apple.launchd.peruser.501[93]   (org.tigris.scplugin.launch[29883])  posix_spawn("/Library/Contextual Menu Items/SCFinderPlugin.plugin/Contents/Resources/SCPluginUIDaemon.app/Contents/MacOS/SCPluginUIDaemon", ...): No such file or directory
com.apple.launchd.peruser.501[93]   (org.tigris.scplugin.launch[29883])  Exited with exit code: 1
Run Code Online (Sandbox Code Playgroud)

我对 scplugin 进行了系统范围的搜索,但没有任何报告。如何确保 launchd 不会尝试启动插件?

Chr*_*sen 7

您可以通过在终端窗口中输入以下命令来暂时阻止launchd尝试启动该程序:

launchctl remove org.tigris.scplugin.launch
Run Code Online (Sandbox Code Playgroud)

效果只是暂时的,因为定义何时以及如何启动该程序的控制文件仍然存在,并且launchd将在您下次登录后再次读取它。您需要找到并删除该文件才能使更改永久化。

文件名通常是的launchd标签1.plist添加到末尾。由于我无法确定launchd文件的名称或位置2,因此我下载并检查了SCPlugin的可安装包。事实证明,它的文件遵循命名约定。完整路径名是./Library/LaunchAgents/org.tigris.scplugin.launch.plist

您应该能够使用Finder删除文件。打开一个新的Finder窗口并导航到该目录(或按 ??G,键入/粘贴/Library/LaunchAgents/,然后单击 Go),然后删除该文件(将其拖到废纸篓或按 ??;您可能需要输入密码)。


1标签是launchd使用的标识符。来自launchd的控制台消息显示了有问题的标签:org.tigris.scplugin.launch

2 launchd在几个目录中查找文件:

  • ~/Library/LaunchAgents/
  • /Library/LaunchAgents/
  • /Library/LaunchDaemons/
  • /System/Library/LaunchAgents/
  • /System/Library/LaunchDaemons/

最后两个应该是“仅限系统”(仅适用于操作系统捆绑和提供的东西),但我看到第三方软件将项目放在/System/Library/.