views:

3764

answers:

7

When I launch the emulator I face many problems (Errors):-

HttpConnectionApp]emulator-5554 disconnected!
Cancelling 'net.paxcel.http.HttpConnectionApp activity launch'!

Emulator]emulator: ERROR: the user data image is used by another emulator.
aborting

Each time I have to re-run it but all in vain.

How can I improve this so that I can re-run the application on same AVD?

A: 

AFAIK, this happens when an emulator is started, but the Android Debug Bridge couldn't establish connection to it.

If you have just started the emulator with your application, watch if you get Waiting for HOME to launch... or something similar in your Console.

If you don't get that message, but the emulator has been started, chances are, you'll get into the ERROR: the user data image is used by another emulator situation again.

Dimitar Dimitrov
A: 

It's probably a bad install of ADT. Try uninstalling the plugin, restarting Eclipse, then installing it again fresh.

That of you aren't letting the emulator boot all the way up and are closing it before ADT/ADB can install/run your app.

fiXedd
no it did'nt work .Apart from ADT i installed fresh copies of all required s/w .But nothing work .
AMANDEEP SINGH
Well, I hate to sound condescending, but people have had this problem before... are you sure the virtual machine is completely booted?
fiXedd
A: 
  1. Please set wipe_data for emulator
  2. Use same instance of application (after modification if any) to avoid error you are getting.
Amby
+1  A: 

Run configurations > Target > Wipe user data > Run

It fixed the problem in my case.

Coc
+9  A: 

I had the same issue after my computer locked up and I had to power cycle it.

Wiping the user data didn't fix my problem, I had to delete the following folders manually

C:\Users\%UserName%\.android\avd\AVD2.1.avd\cache.img.lock
C:\Users\%UserName%\.android\avd\AVD2.1.avd\userdata-qemu.img.lock
Travis
+2  A: 

A quick-fix that obviously works is to restart the adb server each time this error occurs:

adb kill-server && adb start-server

Then, you simply run the application again (without restarting AVD) and that's it.

leden
+1  A: 

"adb kill-server && adb start-server" the first post, posted by 'leden' works for me.... Thanks..

Roy Samuel