Xcode 9 Server:由于系统资源不足而无法启动设备

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/46360878/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-15 10:16:53  来源:igfitidea点击:

Xcode 9 Server: Unable to boot device due to insufficient system resources

iosxcodeios-simulatorxcode9xcode-server

提问by Lukas Würzburger

I'm trying to run my unit tests on all device simulators from iOS 8.4 to 11.0 at the same time by checking the option 'Run test in parallel' when setting up the Xcode Bot. Unfortunately after trying to boot the 13th simulator it failes with the error message in the build log:

我正在尝试通过在设置 Xcode Bot 时选中“并行运行测试”选项,同时在从 iOS 8.4 到 11.0 的所有设备模拟器上运行我的单元测试。不幸的是,在尝试启动第 13 个模拟器后,它失败并在构建日志中显示错误消息:

xcodebuild: error: Failed to build workspace xxxxx with scheme yyyyy.
Reason: Unable to boot device due to insufficient system resources.
Testing failed on 'iPhone 4s'

I'm running the server on a mac mini and i think it is just not capable to run so many simulators at the same time due to full memory.

我在 mac mini 上运行服务器,我认为由于内存已满,它无法同时运行这么多模拟器。

Anyone experience with it?

任何人都有经验吗?

采纳答案by Erik B

Increase the maximum number of processes until the next restart:

增加最大进程数,直到下次重新启动:

sudo launchctl limit maxproc 2000 2500

Increase the maximum number of open files until the next restart:

增加打开文件的最大数量,直到下次重新启动:

sudo launchctl limit maxfiles 2000 unlimited

For me it was the maximum number of processes that had to be increased. You might need even bigger numbers, those are just examples. Please refer to the documentation for more details.

对我来说,这是必须增加的最大进程数。您可能需要更大的数字,这些只是示例。有关更多详细信息,请参阅文档。

Source: https://help.apple.com/simulator/mac/9.0/index.html#/dev8a5f2aa4e

来源:https: //help.apple.com/simulator/mac/9.0/index.html#/dev8a5f2aa4e