14

I got the following error message when trying to boot my fourth simulator:

Unable to boot device due to insufficient system resources.

Please see Simulator Help for information on adjusting system settings to allow more simulated devices to boot at once.

maxUserProcs: 709, runningUserProcs: 569, enforcedProcBuffer: 144

I don't know what Simulator Help they are referring to, because I'm not finding anything about this. Google also doesn't help me. It's pretty clear from the error message that if runningUserProcs + enforcedProcBuffer is greater than maxUserProcs, you cannot boot another simulator. What isn't clear is how to change the maxUserProcs setting.

Does anyone know how I can change the maxUserProcs?

Community
  • 1
  • 1
Erik B
  • 40,889
  • 25
  • 119
  • 135

2 Answers2

17
sudo launchctl limit maxproc 2000 2500

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

Erik B
  • 40,889
  • 25
  • 119
  • 135
  • Also note that beginning with macOS 10.14 we auto-scale these values to the amount of system RAM, so an iMac Pro with 64 GB of memory should have a higher default limit. – russbishop Jun 25 '19 at 04:42
  • @russbishop "Unable to boot device due to insufficient system resources." error came up. I quit all the apps. and then tried to open up the simulator. Still the same issue. Any ideas on what I can do? – Akshit Zaveri Jul 23 '19 at 06:12
  • This worked for me. However I only got 8GB....so I don't know how much an impact this will have on my macbook M1. – Vladimir Despotovic Dec 11 '22 at 11:10
1

This pointer helped me, though, when I run this particular command given above

sudo launchctl limit maxfiles 2000 unlimited

it sets my setting as maxfiles 2000 10240

So I run again this bit different one

sudo launchctl limit maxfiles 65536 200000

and it now the setting got set as maxfiles 65536 200000

And doing this later one only helped me to re run the simulator again successfully. I have a Mojave 10.14.5.

xavier
  • 1,860
  • 4
  • 18
  • 46