Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Could not run adb reverse (React-Native)

BUILD SUCCESSFUL

Total time: 2 mins 6.65 secs Running C:\Users\arnold\AppData\Local\Android\sdk;/platform-tools/adb -s 192.168.95.101:5555 reverse tcp:8081 tcp:8081 Could not run adb reverse: spawnSync C:\Users\arnold\AppData\Local\Android\sdk;/platform-tools/adb ENOENT Starting the app on 192.168.95.101:5555 (C:\Users\arnold\AppData\Local\Android\sdk;/platform-tools/adb -s 192.168.95.101:5555 shell am start -n com.testproject/com.testproject.MainActivity)...

The build successful but it's not shown in GenyMotion emulator.

i running on Android 5.0.0 (API 21)

like image 652
arnold tan Avatar asked Jul 21 '17 05:07

arnold tan


People also ask

How do I run React Native projects on Android?

Plug in your device via USB # Let's now set up an Android device to run our React Native projects. Go ahead and plug in your device via USB to your development machine. Now check that your device is properly connecting to ADB, the Android Debug Bridge, by running adb devices.

How to solve could not connect to development server error in React Native?

How to Solve Could not connect to development server Error in React Native : 1. This error occurs when we close the server command prompt window by mistake . The server command window should look like this : 2. So there is no need to close and recompile the whole project again.

How to build a Gradle project from React Native?

React Native runs on backhand server which starts when we apply the react-native run-android or react-native run-ios command on our command prompt screen. This command start will build up our Gradle project and start synchronizing the whole package using JS server.

How to debug a device in ADB shell?

You can click the device option button, or if it doesn't exist for your device use adb shell input keyevent 82 command and select Dev Settings from menu, and then from the section DEBUGGING choose Debug server host & port for device and enter your PC's IP (you can find your IP from ipconfig command for Windows) for example 192.168.1.12:8081.


1 Answers

You can click the device option button, or if it doesn't exist for your device use adb shell input keyevent 82 command and select Dev Settings from menu, and then from the section DEBUGGING choose Debug server host & port for device and enter your PC's IP (you can find your IP from ipconfig command for Windows) for example 192.168.1.12:8081.

after that, you can reload your application from options menu or restart your application.

Please pay attention:

  • Your device and pc must be on the same network
  • Host port can be found from node window, for example: Running Metro Bundler on port 8081.

React-native option menu:

React-native option menu

Node window and successful Bundle loading enter image description here

like image 62
Mohsen Beiranvand Avatar answered Sep 27 '22 22:09

Mohsen Beiranvand