Skip to content

Failed run android simulator : No connected devices! #3091

@nvcken

Description

@nvcken

I try to run app on android simulator but failed

:app:installDebug FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:installDebug'.
> com.android.builder.testing.api.DeviceException: No connected devices!

Activity

changed the title [-]Failed run react-native run-android : No connected devices![/-] [+]Failed run android simulator : No connected devices![/+] on Sep 28, 2015
satya164

satya164 commented on Sep 28, 2015

@satya164
Contributor

What does adb devices print? If debugging mode turned on in your phone?

nvcken

nvcken commented on Sep 28, 2015

@nvcken
Author

I have not plug real phone for running app.
I want to run app on "virtual android" simulator as like as xcode emulator

ide

ide commented on Sep 28, 2015

@ide
Contributor

Launch the simulator and try running again.

nvcken

nvcken commented on Sep 28, 2015

@nvcken
Author

It works.
Thanks all

mgenev

mgenev commented on Feb 11, 2016

@mgenev

@ide how to launch the simulator on its own? Cordova has always launched it for me so far

ide

ide commented on Feb 11, 2016

@ide
Contributor
TheNotary

TheNotary commented on May 23, 2016

@TheNotary

Google brought me here, thought I'd share notes:

If you don't have any devices listed from adb devices You'll want to start by creating an Android Virtual Device image.

$  android create avd -n <name> -t <target> --abi default/x86_64

<name> can be anything, such as react, <target> should be one of the options produced by the below command...

$  android list targets

If that listing is empty, use the android command's GUI to install a target platform and such.

When you have the platform, and the device, you can then boot the device with emulator:

$  emulator -avd <name>

Once booted, the command you were likely trying to run react-native run-android should produce the effect of a react mobile app running in your emulator window.

See: http://stackoverflow.com/questions/4974568/how-do-i-launch-the-android-emulator-from-the-command-line

emanuti

emanuti commented on Sep 5, 2016

@emanuti

In my case, It was on my device.
http://facebook.github.io/react-native/releases/0.23/docs/android-setup.html#troubleshooting
On Terminal, I made step 1 and after run react-native start at root directory and then on other table run react-native run-android.

ltfschoen

ltfschoen commented on Jun 2, 2017

@ltfschoen

Further to @TheNotary comment. Instead of creating your Android Virtual Device (AVD) from the command line with android create ...), you may find creating the AVDs with a GUI interface much easier (where you can see all the options available) by just opening the Android Virtual Device (AVD) Manager with android avd

lc-rezende

lc-rezende commented on Dec 23, 2017

@lc-rezende

So, basically everytime want to react-native run-android I first have to go to ../Library/Android/sdk/tools and run emulator -avd <avd_name>, wait until the emulator loads and then run react-native run-android?

francisrod01

francisrod01 commented on Dec 23, 2017

@francisrod01

@nvcken I think that you have the same problem with two adb in your machine.

Please remove android-tools-adb because it's outdated and appoint /usr/bin/adb to adb from Android SDK and try it again. ;)

See more about how I solved that in this issue lugg/react-native-config#202

dann1609

dann1609 commented on Mar 20, 2018

@dann1609

close all simulators and run it again.

markhu

markhu commented on May 11, 2018

@markhu

FWIW, some of the above advice is out-dated...

$ android list target
*************************************************************************
The "android" command is deprecated.
For manual SDK, AVD, and project management, please use Android Studio.
For command-line tools, use tools/bin/sdkmanager and tools/bin/avdmanager
*************************************************************************
Running /usr/lib/android-sdk/tools/bin/avdmanager list target
alidoran

alidoran commented on Jul 17, 2018

@alidoran

by this file memu adb and memu ide and memu connect problem solved

http://cdn.persiangig.com/download/e8HZsJdyji/memu%20repair.exe/dl

TheNotary

TheNotary commented on Jul 17, 2018

@TheNotary

The image upload didn't work and only made a malware link :/

alidoran

alidoran commented on Jul 17, 2018

@alidoran
alidoran

alidoran commented on Jul 17, 2018

@alidoran

i repair link
this file edit memu and need to turn off antivirus 3 second for install

TheNotary

TheNotary commented on Jul 17, 2018

@TheNotary

Ok, I got the mailware to download correctly, but now it says:

This malware requires Windows 7 and above to work.  

What should I do if I'm on a real operating system like Debian?

alidoran

alidoran commented on Jul 18, 2018

@alidoran
locked as resolved and limited conversation to collaborators on Jul 21, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @markhu@ide@TheNotary@satya164@emanuti

        Issue actions

          Failed run android simulator : No connected devices! · Issue #3091 · facebook/react-native