xcode 6.1.1无法启动ios模拟器

时间:2014-12-28 06:09:51

标签: ios8 xcode6 ios-simulator

我在OSX 10.9.5上将Xcore从v5.1更新到v6.1.1,现在iOS模拟器无法启动。它报告错误'无法启动设备

我找到了其他帖子,例如IOS 8 Simulator unable to bootUnable to boot the iOS Simulator - xcode 6.0.1,但这些帖子中的解决方案不起作用。

我试过了:

  1. 重新安装xcode 6.1.1
  2. 将xcode从6.1更改为5.1并返回
  3. 添加/删除模拟器设备
  4. 设置正确的命令行工具
  5. 重置模拟器连接和设置
  6. 删除DerivedData
  7. 以上所有解决方案都没有解决问题。启动ios模拟器时有一些崩溃日志

    以下是相关日志记录:

    Process:         launchd_sim [517]
    Path:            /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/sbin/launchd_sim
    Identifier:      launchd_sim
    Version:         2.0.0 (560.3.4)
    Code Type:       X86-64 (Native)
    Parent Process:  launchd [164]
    Responsible:     launchd_sim [517]
    User ID:         501
    
    Date/Time:       2014-12-28 13:32:33.265 +0800
    OS Version:      Mac OS X 10.9.5 (13F34)
    Report Version:  11
    Anonymous UUID:  1DE0E720-8BE2-F93D-B888-E9EB45328623
    
    
    Crashed Thread:  0  Dispatch queue: com.apple.main-thread
    
    Exception Type:  EXC_BAD_INSTRUCTION (SIGILL)
    Exception Codes: 0x0000000000000001, 0x0000000000000000
    
    Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
    0   launchd_sim                     0x000000010a1a9350 0x10a182000 + 160592
    1   launchd_sim                     0x000000010a1868a9 0x10a182000 + 18601
    2   libdyld.dylib                   0x000000010a5ae145 start + 1
    
    Thread 0 crashed with X86 Thread State (64-bit):
    rax: 0x000000010a1b2fa7  rbx: 0x000000010a1b2f97  rcx: 0x000000010a1bead8  rdx: 0xffffffffffffffff
    rdi: 0x0000000000000002  rsi: 0x00000000000001c0  rbp: 0x00007fff55a7d930  rsp: 0x00007fff55a7d860
    r8: 0x0000000000000000   r9: 0x000000010a682600  r10: 0x00000000000045c8  r11: 0x000000010a8c815f
    r12: 0x0000000000000000  r13: 0x0000000000000000  r14: 0x00007fff55a7da80  r15: 0x0000000000000000
    rip: 0x000000010a1a9350  rfl: 0x0000000000010283  cr2: 0x000000010a63db98
    
    Logical CPU:     3
    Error Code:      0x00000000
    Trap Number:     6
    
    
    Binary Images:
    0x10a182000 -        0x10a1bafff +launchd_sim (2.0.0 - 560.3.4) <AAAFA861-0E11-3137-B438-BDDAD2793F55> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/sbin/launchd_sim
    0x10a1c9000 -        0x10a1ed61f +dyld_sim (239.4) <EE50CD24-1E90-32CE-A2A6-9D5777ED53A6> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/dyld_sim
    0x10a233000 -        0x10a23afff +libSystem.dylib (1213) <515F42A5-6E61-352F-9784-C75A1292B711> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/libSystem.dylib
    0x10a243000 -        0x10a43b74f +libobjc.A.dylib (647.1) <576F0DE8-DC61-357E-B54E-0C6E622AB95B> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/libobjc.A.dylib
    0x10a460000 -        0x10a465ff7 +libcache_sim.dylib (69) <7BA055A9-A632-39A7-89CA-76040A0B1B4A> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libcache_sim.dylib
    0x10a46b000 -        0x10a47afff +libcommonCrypto.dylib (60061) <4FC0684B-1435-317D-9622-5528E6891D1E> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libcommonCrypto.dylib
    0x10a489000 -        0x10a490fff +libcompiler_rt.dylib (60.3) <3BCC5FFD-F7D5-3428-8875-4F75DDD80904> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libcompiler_rt.dylib
    0x10a49a000 -        0x10a4a2ff7 +libcopyfile.dylib (119.1.1) <5704F196-9089-39A0-81AF-D0DDF0075D58> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libcopyfile.dylib
    0x10a4a9000 -        0x10a526fff +libcorecrypto.dylib (234.1.2) <0B51D5C2-03CD-30F4-B2DA-7442E80ECDA5> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libcorecrypto.dylib
    0x10a562000 -        0x10a589fff +libdispatch.dylib (443.3.3) <9CB452C0-FC46-3447-BBAD-A6E100EDF5E5> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libdispatch.dylib
    0x10a5ac000 -        0x10a5aeff7 +libdyld.dylib (353.5) <D4880F20-C90B-39C0-970F-44A45D6B3AF0> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libdyld.dylib
    0x10a5b5000 -        0x10a5b5ff7 +liblaunch.dylib (560.3.4) <01747FC0-882D-3570-A15C-ECF5091B71D0> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/liblaunch.dylib
    0x10a5bc000 -        0x10a5c2fff +libmacho_sim.dylib (857) <305B4A1E-8138-3867-9FC1-C99EF196BCC1> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libmacho_sim.dylib
    0x10a5c9000 -        0x10a5cbfff +libremovefile.dylib (35) <CDBD2F0C-2264-3959-974B-C01CFE9764F2> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libremovefile.dylib
    0x10a5d1000 -        0x10a5eaff7 +libsystem_asl.dylib (267) <A0A1AA90-5B6A-351B-B3D0-0E08329C43C7> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_asl.dylib
    0x10a5f8000 -        0x10a5f9fff +libsystem_sim_blocks.dylib (65) <2D04A6AD-DAB1-33BA-8384-4F505A9B4847> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_sim_blocks.dylib
    0x10a5ff000 -        0x10a69bfff +libsystem_sim_c.dylib (1046) <E000605A-4E5E-38C8-A389-7BB04B97A7D4> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_sim_c.dylib
    0x10a6c6000 -        0x10a6c9fff +libsystem_sim_configuration.dylib (700.3.1) <5683916A-3F9F-31D7-9943-90E5E126C1A3> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_sim_configuration.dylib
    0x10a6d0000 -        0x10a6d1fff +libsystem_coreservices.dylib (7) <94F5BEBA-D238-32BF-8BD2-B050D2F704FD> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_coreservices.dylib
    0x10a6d7000 -        0x10a6ecfff +libsystem_coretls.dylib (35.3.2) <0C120C14-A473-39E6-BCD4-CE9393E9735E> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_coretls.dylib
    0x10a6fe000 -        0x10a707ff7 +libsystem_sim_dnssd.dylib (561) <5C4C13B8-ED6D-3A44-BC74-4E096C29FAEF> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_sim_dnssd.dylib
    0x10a70e000 -        0x10a739fff +libsystem_sim_info.dylib (459) <94819159-805A-3A3F-B836-E8B45A6DBC09> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_sim_info.dylib
    0x10a74c000 -        0x10a750ff7 +libsystem_sim_kernel.dylib (141) <AAEC320A-EAD7-3B81-83AF-8F8DF00757B2> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_sim_kernel.dylib
    0x10a757000 -        0x10a788fe7 +libsystem_sim_m.dylib (3086.1) <166D1241-FC71-362E-BB19-F10DB0578001> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_sim_m.dylib
    0x10a790000 -        0x10a7aefff +libsystem_malloc.dylib (55.3.1) <FAE6F4E0-7BB1-3283-BC8E-2388E8E2B353> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_malloc.dylib
    0x10a7b8000 -        0x10a7f9ff7 +libsystem_network.dylib (410.1) <9C75D513-B1DB-308F-8169-882375A38F8B> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_network.dylib
    0x10a81f000 -        0x10a82afff +libsystem_notify.dylib (134.1.1) <CE924059-1CB3-3075-B56F-A96069F46BC2> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_notify.dylib
    0x10a833000 -        0x10a836ff7 +libsystem_sim_platform.dylib (141) <BDAFD2D9-6204-3A85-BB48-60DD2B1D5DA1> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_sim_platform.dylib
    0x10a83c000 -        0x10a83dfff +libsystem_sim_pthread.dylib (141) <1E4C9CA4-6CF0-3D7E-BB4A-5DB255DEF39B> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_sim_pthread.dylib
    0x10a843000 -        0x10a846fff +libsystem_sim_sandbox.dylib (359.1.1) <D52833FB-E840-314A-9DF5-E030B5C6CAD9> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_sim_sandbox.dylib
    0x10a84d000 -        0x10a854fff +libsystem_sim_trace.dylib (72) <F7D50A34-7BCF-3AEA-B294-D2DC9D971758> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libsystem_sim_trace.dylib
    0x10a85e000 -        0x10a864ff7 +libunwind_sim.dylib (126.2) <BE0D0D9B-A792-3614-89DD-750B0473AE7D> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libunwind_sim.dylib
    0x10a86c000 -        0x10a898fff +libxpc.dylib (560.3.4) <464E62EA-4CF2-3FEF-9C17-692AD8D66AA8> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/system/libxpc.dylib
    0x10a8b6000 -        0x10a8d2ff7  libsystem_kernel.dylib (2422.115.4) <9EDE872E-2A9E-3A78-8E1D-AB790794A098> /usr/lib/system/libsystem_kernel.dylib
    0x10a8f6000 -        0x10a8fcff7  libsystem_platform.dylib (24.90.1) <3C3D3DA8-32B9-3243-98EC-D89B9A1670B3> /usr/lib/system/libsystem_platform.dylib
    0x10a90f000 -        0x10a916ff7  libsystem_pthread.dylib (53.1.4) <AB498556-B555-310E-9041-F67EC9E00E2C> /usr/lib/system/libsystem_pthread.dylib
    0x10a922000 -        0x10a94ffff +libc++abi.dylib (126.2) <C601D38D-DBB7-37A1-8ECA-772C6AF5C1C6> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/libc++abi.dylib
    0x10a95e000 -        0x10a9c9fff +libc++.1.dylib (235.1) <F554D397-7776-3652-A236-69661F56110E> /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/libc++.1.dylib
    0x7fff6d7f6000 -     0x7fff6d829817  dyld (239.4) <7AD43B9B-5CEA-3C7E-9836-A06909F9CA56> /usr/lib/dyld
    
    External Modification Summary:
    Calls made by other processes targeting this process:
    task_for_pid: 0
    thread_create: 0
    thread_set_state: 0
    Calls made by this process:
    task_for_pid: 0
    thread_create: 0
    thread_set_state: 0
    Calls made by all processes on this machine:
    task_for_pid: 477
    thread_create: 0
    thread_set_state: 0
    
    VM Region Summary:
    ReadOnly portion of Libraries: Total=8456K resident=3380K(40%) swapped_out_or_unallocated=5076K(60%)
    Writable regions: Total=18.0M written=320K(2%) resident=476K(3%) swapped_out=0K(0%) unallocated=17.5M(97%)
    
    REGION TYPE                      VIRTUAL
    ===========                      =======
    Kernel Alloc Once                     4K
    MALLOC                             9396K
    MALLOC (admin)                       16K
    STACK GUARD                        56.0M
    Stack                              8192K
    VM_ALLOCATE                           8K
    __DATA                              892K
    __LINKEDIT                         2160K
    __TEXT                             6308K
    shared memory                         4K
    ===========                      =======
    TOTAL                              82.3M
    

3 个答案:

答案 0 :(得分:2)

此问题的最常见原因是DYLD_INSERT_LIBRARIES设置为OS X库。

我建议您取消设置DYLD_INSERT_LIBRARIES(可能在/etc/launchd.conf中)或以其他方式卸载设置它的产品,然后重新启动。

OS X Yosemite有一个软件更改来处理这种情况,所以如果您需要设置DYLD_INSERT_LIBRARIES的产品,我建议您更新到OS X Yosemite进行开发。


但是,既然您已提供崩溃日志,我可以告诉您该问题可能是您系统上的问题。 launchd_sim正在中止,因为它无法在/ private / tmp中创建一个目录。我怀疑你已经修改了/ private / tmp的权限,这样就失败了:

mkdir /private/tmp/com.apple.CoreSimulator.SimDevice.FE1168B2-EE8D-4C69-8AE7-99F5A80F808B.launchd_sim

您应该修复/ private / tmp的权限,并防止它们在将来搞砸。由于这个原因,除了iOS模拟器之外还有很多其他的东西会破坏。

答案 1 :(得分:1)

iOS 8.3,XCode 6.3 我在以下地方观察过类似的调用堆栈: 〜/库/日志/ DiagnosticReports / launchd_sim_&LT;邮戳&GT; _&LT; yourHostName&GT; .crash

我要强调Jeremy Huddleston Sequoia所说的权限在某些情况下应该归咎于权限。 (如我的)

修复:
sudo diskutil repairPermissions / - 修复系统目录的权限(如果/ tmp不正确)。

如果我没有设置DYLD_INSERT_LIBRARIES变量,这对我有用。 (即“echo $ DYLD_INSERT_LIBRARIES”返回空白)。我真的在敲打这个。我已经卸载了Xcode /重新启动/删除模拟器/等,如多个不同的S.O.讯息。

根本原因:
问题源于另一个应用程序,该应用程序抱怨没有对/ tmp文件夹的写访问权限,因此我更改了权限而不知道我的操作的全部后果。运行上面的diskutil命令修复了它和它找到的更多文件夹没有设置它们应该是。 现在我的模拟器运行了,我可以在Xcode中继续我的UI调试。

很棒的回答杰里米!谢谢!!

答案 2 :(得分:0)

我做了一个sudo chown $user:wheel /private/tmp而它似乎已经为我解决了。