Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

I am getting error when i install my Android app in device Redmi 3s prime, and it is working on genymotion emulator

I'm having this error:

$ adb push F:\skylixwork\CollagePhoto\app\build\outputs\apk\app-debug.apk
/data/local/tmp/com.collagephoto java.io.IOException: An existing connection was forcibly closed by the remote host
Error while Installing APK

Installation failed with message INSTALL_CANCELED_BY_USER. It is possible that this issue is resolved by uninstalling an existing version of the apk if it is present, and then re-installing.

WARNING: Uninstalling will remove the application data!

Do you want to uninstall the existing application?

like image 659
Jaymin Bhadani Avatar asked Nov 23 '16 06:11

Jaymin Bhadani


1 Answers

Works !

  1. enable developer mode - In your phone, go to Settings, About phone and click on MIUI version 7 times. You’ll see a pop up which says you are a developer now.

  2. Go back to Settings, Additional settings, Developer options and enable USB Debugging.

  3. Connect your phone to your PC/Mac and on the phone authorize your computer

  4. go back to Developer options, scroll down to find Turn on MIUI optimization and disable it. Your phone will be rebooted

  5. I solved my issue this way.

like image 69
Axay Prajapati Avatar answered Nov 09 '22 05:11

Axay Prajapati