Simulator error FBSSystemServiceDomain code 4
IosIos SimulatorXcode6ios8.1Ios Problem Overview
I'm trying to run an app in the simulator but get this error message:
Unable to run app in Simulator
An error was encountered while running (Domain = FBSSystemServiceDomain, Code = 4)
I've not seen any previous references to this from googling around.
Its using XCode 6 Beta, the app is in Swift which links to a Obj-C static library. It runs fine on the device.
Any ideas?
Ios Solutions
Solution 1 - Ios
Go to the iOS Simulator menu and select Reset Content and Settings.
Alternatively, you could quit and reopen the Simulator.
Solution 2 - Ios
It's enough to quit and re-open the Simulator, this has been verified in the Xcode 6.0.1 release.
Solution 3 - Ios
This issue is discussed in the Xcode 6 Release Notes
> Testing on iOS Simulator may produce an error indicating that the > application could not be installed or launched. Re-run testing or > start another integration. (17733855)
And is also discussed in my sticky post in the Apple Developer Forums for iOS Simulator Debugging
> "(Domain = FBSOpenApplicationErrorDomain, Code = 4)", "(Domain NSPOSIXErrorDomain, Code = 3"), > "Domain=IDEUnitTestsOperationsObserverErrorDomain Code=3", "Lost > Connection to ...", "Debugger disconnected", or app getting SIGKILLed > soon after launch Upon installation of an app, SpringBoard will > SIGKILL that app's process in order to force a relaunch of the app > with the new executable. The problem is that there is a race > condition whereby SpringBoard may accidentally SIGKILL a new process > that we just launched rather than the old process. Which of the > various error messages you get depends on exactly when in the launch > process the SIGKILL was delivered. Normally, this shouldn't happen, > so the advise is to just try again (sorry =/). If you find that this > happes to you all the time or more frequently than you can tollerate, > we are incredibly sorry. We are aware that systems with slower disk > I/O will see this happen more frequently than faster systems, so if > you are using an NFS home directory, you may want to create a local > directory for your simulator data and setup a simlink to it from > ~/Library/Developer/CoreSimulator
Note that the original question is about domain FBSSystemServiceDomain whereas my post on devforums mentions FBSOpenApplicationErrorDomain. FBSSystemServiceDomain was used in earlier versions of iOS 8.0 betas.
Solution 4 - Ios
You can either Reset Content and Setting or just close iOS Simulator and relaunch.
Solution 5 - Ios
None of the solutions worked for me including the accepted answer of "Reset Content and Settings".
The only way I was able to get it to work was by downloading a previous iOS simulator version which let me install the app.
Solution 6 - Ios
I suggest you to use stable version of Xcode 6.1.
FBSOpenApplicationErrorDomain, code =4 error suggests it is an error from
cached data on the simulator.
There are three possible solutions :
-
Clean simulator. Use (Command + Shift + k) as shortcut key or goto Product -> Clean
-
Quit simulator and relaunch it.
-
Open simulator. Select iOS simulator -> Reset contents and settings...