adb unable to connect to Android-x86 in VirtualBox today

前提是你 提交于 2019-12-02 20:59:04
rinkesh

To connect Android virtual machine with adb follow these step

  1. On Android home screen, press ALT+F1 (Left alt). This will open a terminal with root access.

  2. Inside the terminal, type dhcpcd eth0. Execute the command twice, if you get an error or no result. This will give you an IP addresss. Now press ALT+F7 for close the terminal.

  3. Verify your IP address using the command ping <your IP Address>

  4. From the android terminal, type adb tcpip 5555. This will restart adb in tcpip mode.

  5. From your main OS terminal, type adb connect <your IP address>

I use bridged networking for the second adapter and use that IP address; i.e. adb connect 192.168.1.20. You can get the IP in Settings->About Phone->Status.

ALT+F1 trick looks good, but didn't work for me.

  1. I did run androvmConfiguration app, clicked Save, and then confirmed reboot action.
  2. After reboot, i did shutdown and turned off VirtualBox, and started AndroVMPlayer.
  3. Now adb connect <your IP address> worked for me!

It works for me instead of my local machine IP I inserted the android terminal IP i.e 192.168.56.101

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!