首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >PackageKit:*无法posix_spawn:错误2

PackageKit:*无法posix_spawn:错误2
EN

Stack Overflow用户
提问于 2018-02-13 09:23:08
回答 3查看 3.8K关注 0票数 1

我有一个安装程序内置在“软件包”工具。在安装时,无法postix_spawn: error 2消息正在显示。

你能帮我解决这个问题吗?

请查找以下installer.log文件以获得更多详细信息

代码语言:javascript
复制
PackageKit: ----- Begin install -----
Feb 13 12:49:12 asutos-mac installd[465]: PackageKit: request=PKInstallRequest <1 packages, destination=/>
Feb 13 12:49:12 asutos-mac installd[465]: PackageKit: packages=(   "PKLeopardPackage <file://localhost/Users/efi/Desktop/FCC/OSX/FieryColorCloud.pkg#FieryColorCloud.pkg>")
Feb 13 12:49:15 asutos-mac installd[465]: PackageKit: Extracting file://localhost/Users/efi/Desktop/FCC/OSX/FieryColorCloud.pkg#FieryColorCloud.pkg (destination=/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/C/PKInstallSandboxManager/692B6502-401B-46BD-ADB6-F1E52BFA3115.activeSandbox/Root, uid=0)
Feb 13 12:49:22 asutos-mac installd[465]: PackageKit: prevent user idle system sleep
Feb 13 12:49:22 asutos-mac installd[465]: PackageKit: suspending backupd
Feb 13 12:49:22 asutos-mac installd[465]: PackageKit: Using trashcan path /var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/T/PKInstallSandboxTrash/692B6502-401B-46BD-ADB6-F1E52BFA3115.sandboxTrash for sandbox /var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/C/PKInstallSandboxManager/692B6502-401B-46BD-ADB6-F1E52BFA3115.activeSandbox
Feb 13 12:49:22 asutos-mac installd[465]: PackageKit: Shoving /var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/C/PKInstallSandboxManager/692B6502-401B-46BD-ADB6-F1E52BFA3115.activeSandbox/Root (2 items) to /
Feb 13 12:49:22 asutos-mac install_monitor[20439]: Temporarily excluding: /Applications, /Developer, /Library, /System, /bin, /private, /sbin, /usr
Feb 13 12:49:22 asutos-mac install_monitor[20439]: PackageKit: Locking applications
Feb 13 12:49:22 asutos-mac installd[465]: PackageKit: Executing script "./postinstall" in /private/tmp/PKInstallSandbox.ZLdi87/Scripts/com.efi.FieryColorCloud.3qlsuM
 Feb 13 12:49:22 asutos-mac installd[465]: ******PackageKit: *** Couldn't posix_spawn: error 2******
Feb 13 12:49:23 asutos-mac install_monitor[20439]: Re-included: /Applications, /Developer, /Library, /System, /bin, /private, /sbin, /usr
Feb 13 12:49:23 asutos-mac installd[465]: PackageKit: releasing backupd
Feb 13 12:49:23 asutos-mac installd[465]: PackageKit: allow user idle system sleep
Feb 13 12:49:23 asutos-mac installd[465]: PackageKit: Install Failed: Error Domain=PKInstallErrorDomain Code=112 "An error occurred while running scripts from the package “FieryColorCloud.pkg”." UserInfo={NSFilePath=./postinstall, NSURL=file://localhost/Users/efi/Desktop/FCC/OSX/FieryColorCloud.pkg#FieryColorCloud.pkg, PKInstallPackageIdentifier=com.efi.FieryColorCloud, NSLocalizedDescription=An error occurred while running scripts from the package “FieryColorCloud.pkg”.} {
        NSFilePath = "./postinstall";
        NSLocalizedDescription = "An error occurred while running scripts from the package \U201cFieryColorCloud.pkg\U201d.";
        NSURL = "file://localhost/Users/efi/Desktop/FCC/OSX/FieryColorCloud.pkg#FieryColorCloud.pkg";
        PKInstallPackageIdentifier = "com.efi.FieryColorCloud";
    }
Feb 13 12:49:23 asutos-mac installd[465]: PackageKit: Running idle tasks
Feb 13 12:49:23 asutos-mac installer[20435]: install:didFailWithError:Error Domain=PKInstallErrorDomain Code=112 "An error occurred while running scripts from the package “FieryColorCloud.pkg”." UserInfo={NSFilePath=./postinstall, NSURL=file://localhost/Users/efi/Desktop/FCC/OSX/FieryColorCloud.pkg#FieryColorCloud.pkg, PKInstallPackageIdentifier=com.efi.FieryColorCloud, NSLocalizedDescription=An error occurred while running scripts from the package “FieryColorCloud.pkg”.}
Feb 13 12:49:23 asutos-mac installd[465]: PackageKit: Removing client PKInstallDaemonClient pid=20435, uid=0 (/usr/sbin/installer)
Feb 13 12:49:23 asutos-mac installd[465]: PackageKit: Done with sandbox removals
Feb 13 12:49:24 asutos-mac installer[20435]: Install failed: The Installer encountered an error that caused the installation to fail. Contact the software manufacturer for assistance.
EN

回答 3

Stack Overflow用户

发布于 2018-12-17 18:22:23

errno=2ENOENT on macOS。

这可能是由#引起的!指令,该指令启动postinstall脚本,指定目标系统上不存在的程序。您应该验证包中的postinstall脚本是否指定了系统上存在的解释器的完整路径。

票数 0
EN

Stack Overflow用户

发布于 2020-03-23 08:51:15

也许,您的shell脚本可能有问题(很可能是关于“散列-砰”,即#!指令)。

尝试以下步骤:

  1. 在源代码中找到所有的预安装和后安装安装程序脚本。
  2. 对于每个预安装/postinstall脚本: a.将整个脚本内容复制到一个新文件(例如preinstall_ new /postinstall_new),但#除外!指令。在preinstall_new/postinstall_new文件顶部键入正在使用的#!/bin/bash或其他解释器(不要复制、使用键盘编写)。c.使preinstall_new/postinstall_new文件成为可执行文件(chmod +x preinstall_new) d.用新创建的preinstall_new/postinstall_ newly文件(mv preinstall_new preinstall)替换原来的预安装/postinstall脚本
  3. 触发生成并验证安装程序。
票数 0
EN

Stack Overflow用户

发布于 2022-07-26 21:00:05

我也有同样的问题,或者我认为。不管怎样,我发现它是如何在网上冲浪的。我不收任何学分。我试着遵循用户"Kienz“在上面说的话:https://jira.atlassian.com/browse/SRCTREE-7836

如果要在这里删除ctrl +c ctrl +v

{更改后,"hg日志“工作。但是您不能拉/推,因为"mercurial_credential_manager.py“不适用于Python3。如何禁用"mercurial_credential_manager.py"?

请修复它与Python3一起工作的原始目录。}

在我等了20多下,按下源树>首选项> mercurial选项卡后,按钮"Reset to integrated“将错误日志更改为"Mercurial integrated 4.6.1”。

这对我有效的26/07/2022对不起,如果解释是不够的,但就是这样!

还有其他问题,我开始使用终端进行git操作,至少SourceTree会帮助您可视化。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/48763315

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档