jyoonPro
jyoonPro

Reputation: 1681

Genymotion Crash after a few minutes

I have built a demo application which works perfectly, and looks like the following:

working

Then after a few runs, Genymotion suddenly stops working, and a screen like the following appears:

not working.

The Logcat keeps recording the following lines:

05-25 13:58:24.326: E/eglCodecCommon(2163): writeFully: failed: Broken pipe
05-25 13:58:24.418: E/EGL_genymotion(2163): tid 2163: eglChooseConfig(544): error 0x3001 (EGL_NOT_INITIALIZED)
05-25 13:58:24.422: E/AndroidRuntime(2163): FATAL EXCEPTION: main
05-25 13:58:24.422: E/AndroidRuntime(2163): Process: com.nextgenintl.aimassistant, PID: 2163
05-25 13:58:24.422: E/AndroidRuntime(2163): java.lang.IllegalArgumentException: eglChooseConfig failed EGL_NOT_INITIALIZED
05-25 13:58:24.422: E/AndroidRuntime(2163):     at android.view.HardwareRenderer$GlRenderer.chooseEglConfig(HardwareRenderer.java:1173)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at android.view.HardwareRenderer$GlRenderer.loadEglConfig(HardwareRenderer.java:1135)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at android.view.HardwareRenderer$GlRenderer.initializeEgl(HardwareRenderer.java:1117)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at android.view.HardwareRenderer$GlRenderer.initialize(HardwareRenderer.java:1057)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:1550)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1000)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:5670)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at android.view.Choreographer$CallbackRecord.run(Choreographer.java:761)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at android.view.Choreographer.doCallbacks(Choreographer.java:574)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at android.view.Choreographer.doFrame(Choreographer.java:544)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:747)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at android.os.Handler.handleCallback(Handler.java:733)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at android.os.Handler.dispatchMessage(Handler.java:95)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at android.os.Looper.loop(Looper.java:136)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at android.app.ActivityThread.main(ActivityThread.java:5017)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at java.lang.reflect.Method.invokeNative(Native Method)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at java.lang.reflect.Method.invoke(Method.java:515)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:779)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:595)
05-25 13:58:24.422: E/AndroidRuntime(2163):     at dalvik.system.NativeStart.main(Native Method)

If I shut down Genymotion and relaunch it, it works fine again.

What is the cause of this problem, and is anyone experiencing it too?

Upvotes: 5

Views: 8048

Answers (4)

red-o-alf
red-o-alf

Reputation: 3225

In my case this was caused by setting the option OpenGL ES maximum API version to a value higher than what my GPU/drivers supported. Lowering the value to 2.0 fixed the problem, making execution super stable.

To make the above change:

  • Open Genymotion UI
  • Right click on your android instance name > Edit
  • Go to Display tab > Scroll down to "OpenGL ES maximum API version" > Edit value

Upvotes: 0

FilipeTR
FilipeTR

Reputation: 37

I had the same problem and fixed it choosing the same resolution of my virtual device. It says "Custom Tablet - 6.0.0 - API 23 - 2560x1600" and the resolution was lower than this. When I put the same, the device doesn't crash anymore

Upvotes: -1

miva2
miva2

Reputation: 2151

The broken pipe error means there is a problem with the connection between emulator and host computer.

To fix it you can restart the emulator (or follow the advice from the other answer).

Upvotes: 1

Marco Acierno
Marco Acierno

Reputation: 14847

It's not really caused by your application, so don't worry.

It often happens when you computer goes in sleep mode and when you come back Genymotion will throw this exception (it happens to me very often).

In your specific case sounds like the device goes in sleep mode so a way to fix it is simply to enable "Always stay awake" in developers options.

enter image description here

Another way to fix it is just to turn off your emulator and relaunch. (as you already do)

Upvotes: 22

Related Questions