这周我无法启动模拟器,我尝试了一些文章中的几种解决方案,但是它不起作用。我的MacOS版本是OS X 10.10.5(14F27),而我的模拟器是iOS 8.4。

我从〜/ Library / Logs / CoreSimulator / CoreSimulator.log中获取了日志

8月27日11:29:14 LL-MBP.local CoreSimulatorService [8316]:可以
未注册服务com.apple.SystemConfiguration.PPPController:
launch_sim_register_endpoint:0xfffffecc 8月27日11:29:14 LL-MBP.local
CoreSimulatorService [8316]:无法注册服务
com.apple.audio.audiohald:launch_sim_register_endpoint:0x44e 8月27日
11:29:14 LL-MBP.local CoreSimulatorService [8316]:无法
注册服务
com.apple.coreservices.lsuseractivity.simulator支持:
launch_sim_register_endpoint:0x44e 8月27日11:29:14 LL-MBP.local
CoreSimulatorService [8316]:无法注册服务
com.apple.FSEvents:launch_sim_register_endpoint:0x44e 8月27日
11:29:14 LL-MBP.local CoreSimulatorService [8316]:无法
注册服务com.apple.SystemConfiguration.configd:
launch_sim_register_endpoint:0x44e 8月27日11:29:14 LL-MBP.local
CoreSimulatorService [8316]:无法注册服务
IndigoHIDRegistrationPort:launch_sim_register_endpoint:0x44e 8月27日
11:29:14 LL-MBP.local CoreSimulatorService [8316]:无法
注册服务PurpleFBTVOutServer:launch_sim_register_endpoint:
0x44e 8月27日11:29:14 LL-MBP.local CoreSimulatorService [8316]:
无法注册服务PurpleFBServer:
launch_sim_register_endpoint:0x44e 8月27日11:29:14 LL-MBP.local
CoreSimulatorService [8316]:错误域= NSPOSIXErrorDomain
代码= 60“无法启动iOS模拟器。” UserInfo = 0x7fbb204683f0
{NSLocalizedDescription =无法启动iOS模拟器。
NSLocalizedFailureReason = launchd无法响应。} 8月27日11:29:14
LL-MBP.local CoreSimulatorService [8316]:错误
Domain = NSPOSIXErrorDomain代码= 60“无法启动iOS模拟器。”
UserInfo = 0x7fbb204683f0 {NSLocalizedDescription =无法启动iOS
Simulator。,NSLocalizedFailureReason = launchd无法响应。} 8月
27 11:29:14 LL-MBP.local CoreSimulatorService [8316]:错误
Domain = com.apple.CoreSimulator.SimError代码= 146“无法在其中查找
当前状态:关机” UserInfo = 0x7fbb20808710
{NSLocalizedDescription =无法在当前状态下查找:关机}
8月27日11:29:14 LL-MBP.local CoreSimulatorService [8316]:错误
查找主机支持端口Aug 27 11:29:14 LL-MBP.local
CoreSimulatorService [8316]:错误
Domain = com.apple.CoreSimulator.SimError代码= 146“无效的设备
状态” UserInfo = 0x7fbb2083b420 {NSLocalizedDescription =无效的设备
状态} 8月27日11:29:14 LL-MBP.local CoreSimulatorService [8316]
:错误Domain = com.apple.CoreSimulator.SimError代码= 146
“无法在当前状态下查找:关机” UserInfo = 0x7fbb2080c350
{NSLocalizedDescription =无法在当前状态下查找:关机}
8月27日11:29:14 LL-MBP.local CoreSimulatorService [8316]:错误
Domain = com.apple.CoreSimulator.SimError代码= 146“无法在其中查找
当前状态:关机” UserInfo = 0x7fbb2080c350
{NSLocalizedDescription =无法在当前状态下查找:关机}
8月27日11:29:14 LL-MBP.local com.apple.iphonesimulator [8330]:
错误域= NSPOSIXErrorDomain代码= 60“无法启动iOS
模拟器。” UserInfo = 0x7fda2a9020f0 {NSLocalizedDescription =无法执行
引导iOS模拟器。NSLocalizedFailureReason = launchd失败
回应。} 8月27日11:29:14 LL-MBP.local CoreSimulatorService [8316]
:错误Domain = com.apple.CoreSimulator.SimError代码= 146
“无法在当前状态下查找:关机” UserInfo = 0x7fbb20b0f850
{NSLocalizedDescription =无法在当前状态下查找:关机}
8月27日11:29:14 LL-MBP.local CoreSimulatorService [8316]:错误
查找主机支持端口Aug 27 11:29:14 LL-MBP.local
CoreSimulatorService [8316]:错误
Domain = com.apple.CoreSimulator.SimError代码= 146“无效的设备
状态” UserInfo = 0x7fbb20b00e20 {NSLocalizedDescription =无效的设备
州}

有人对此有任何想法吗?

我将不胜感激!

最后,我在@Jeremy Huddleston Sequoia的帮助下解决了此问题。一开始,我在线尝试了许多解决方案,包括删除/ private / tmp文件夹。这样无论我清理多少次重新安装模拟器都无法正常工作。所以要小心一点

最佳答案

这些错误表明未加载launchd_sim或未运行,并且触发了看门狗以通知您失败。

如果在OS X 10.10.5中禁用AMFI,则Simulator运行时将不可用,并且可以这样显示。

但是,就您而言,launchd_sim在启动时崩溃。崩溃日志表明,尝试在/ private / tmp中创建其状态目录时遇到错误。

您可能会删除/ private / tmp(或错误地重新创建了它)。要创建/ private / tmp,请执行以下操作:

sudo mkdir /private/tmp
sudo chmod 1777 /private/tmp

关于ios - 删除/private/tmp后无法启动iOS模拟器,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/32239906/

10-13 07:11