Android adb unable connect with ip address - java

I have installed android operating system in Oracle Virtual box successfully.
but I am facing one problem ,
I tried many options, but I couldn't solve this problem .
My problem is - I am not able to adb connect to virtual box android os.
When i am selecting host-only Adapter option ,easy to connect with adb but no internet connection in android virtual box os.
When i am selecting NAT ,Internet connection fine but not connect with adb .
Please help me how to solve my problem ..

Finally, I solved my problem. This was my solution:
In the emulator press the CTRL + Home keys and press Devices > Network Adapters.
See the menu, select Network and select Bridged Adapter.
Press CTRL + ALT + F1 in the emulator to open the Android terminal and type the following command:
netcfg
Press CTRL + ALT + F7 to see the Graphical View.
Restart the emulator.
Use the found IP in the command:
adb connect <IP address>

At first enable adb over tcpip in the Android VM Terminal Emulator.
Type the command #
adb tcpip 5555
Then to connect via adb from a command line
Type the command #
adb connect 219.91.220.142
Further resources:
How can I connect to Android with ADB over TCP?
Android - adb tcpip error
Android x86 on VirtualBox: Android Connected But Not Online

Related

Cannot be root on Android Emulator

I'm currently trying to develop an application for Android devices on an Android Emulator. I installed Android 4.3 on a VMWare Workstation, on a Windows 10 OS.
I want to test the app I'm developping on the Android emulator, so I have to create a bridge connection between my phyisical computer where I develop the aps, and the emulator, where I can test it. But when I try to create this bridge, I have to change settings and to be root of the emulator. When I try to do a 'su' command, I have the following error :
'su : uid 10000 not allowed to su'
I tried to follow this tutorial to give me the root acces of the emulator, but it didn't worked for me. The best answer is to execute this commands :
adb shell mount -o rw,remount -t yaffs2 /dev/block/mtdblock03 /system
adb push su /system/xbin/su
adb shell chmod 06755 /system
adb shell chmod 06755 /system/xbin/su
How to get root access on Android emulator?
More over, When I did the installation of the Android Emulator, I've done the installation specifying the read-write option.
It is not working for me, because when I try the first row, I obtain this message :
ADB error : 'device not found'
Such as it is described in this link :
How to fix: Error device not found with ADB.exe
But the answer exists for a phone, and not for an emulator. Do you know how to fix it ? How can I be root, and how can I found the 'device not found' ?
Here are the different parameters of the VM
su stands for super users which is available only on rooted device. it is more like using android application with administrator privilege.Try using BLuestacks rooted version.

No active compatible device found to running android application

I've fully searched this site in order to solve my problem without any success.
My device is Sony Xperia Go (ST27i)
When I want to run my android application in Eclipse, I get this error:
No active compatible AVD's or devices found. Relaunch this
configuration after connecting a device or starting an AVD.
But I can see my device name in "device list" linked to USB ports.
Can you please help me about this problem?
Thank you.
see the
<uses-sdk
android:minSdkVersion="see here"
android:targetSdkVersion="see here" />
for compatibility in your manifest
Can you connect to your device? Try this from the command line:
adb shell
If this fails try this as root:
killall adb
adb shell
For future readers may have this problem:
I've installed Sony PC Companion and now I can use my phone in order to test the application.

Unable to open the avd which is created

i created a avd named droidX which later wen i am starting that avd it could not open it just hangs showing "Starting emulator for droidX"
you can use bluestack emulator http://www.bluestacks.com/
1) open bluestacks emulator.
2) go to your environment variable settings and click on path variable and add the path of your abd in the platform-tools folder (Optional if you have done it before.)
3)open cmd and type adb connect adb connect 127.0.0.1
4)now open eclipse and click on project -> run as-> Android Aplication and you should see blueStack emulator running.

Eclipse doesn't find my already running Android emulators

Configuration
Os: OSX
IDE: Eclipse Juno
I don't know why but when I try to run again my Android app, the "Android Device Chooser" frame opens but my emulators are not shown in "Choose a running Android device" section. What should I do ?
Goto the DDMS view and try resetting the ADB as shown---
Please check the required API levels of the application and than on the device.
Try to run following commands in terminal that will renew the adb server state :
adb kill-server
adb start-server
You can try to use adb over the wifi and than no cables will needed.

Androix x86 on Virtualbox, permanent net settings

I installed Android x86 on Virtualbox on my Win7 pc, to run the apps I create with eclipse in it.
I'm following a tutorial ( This one ) but I can't get the connecting part right.
When I boot my android virtual machine, i press ALT + F1 and type "netcfg", I see that the "eth0" port has no address and is DOWN.
If I type "dhcpcd" it dynamically gives it an IP so this is the configuration:
eth0 UP 192.168.10.74
and that fine, I can proceed to give an "adb connect 192.168.10.74" on Windows' cmd, and it works.
But, when I shut down or reboot the android virtual machine all settings are lost!!! How can I make it work?
There is a change in the step 5 of the process.
Select Installation - Install Android-X86 to hard disk
Hope this solves the problem.

Categories

Resources