70

When launching my application in eclipse 3.7.0 I receive an error...

Emulator] emulator: ERROR: Unable to load Vm from snapshot. The snapshot has been saved for a different hardware configuration.

I have ran this application numersous times with out error but now this error displays. I have checked my AVD Manager and my platform and API Level are correct.

17 Answers 17

73

The problem isn't with your app, it is with the saved AVD snapshot. The AVD configuration has been edited since you last ran it successfully. Even changing skin/display resolution will produce this error. You could either:

  1. Change the AVD configuration back to how it was originally.
  2. Edit the AVD to disable the Snapshot. or
  3. When you next start the AVD, uncheck the Launch with snapshot, but keep Save snapshot checked. This way the snapshot will be ignored at start-up, but overwritten when you exit. You will then be able to use snapshot for subsequent runs as before.
9
  • 13
    Actually I got this error without changing the configuration at all. It is one of many many Eclipse-related bugs. Cough broken pipe.
    – Timmmm
    Jul 10, 2012 at 0:53
  • 2
    After experiencing this more, I believe it may be because the emulator doesn't shut down correctly and the snapshot gets corrupted.
    – Timmmm
    Jul 28, 2012 at 17:22
  • @Timmmm: Could be; I can only speak from my own experience, which I have done above. TBH I've not had too many gripes with ADT at all, but there is always room for more answers ;-) If you think what you've experienced is a stone cold bug, have you reported it to Google?
    – Chilledrat
    Jul 28, 2012 at 18:27
  • Yeah I think it is in the bug db somewhere. It wouldn't be so bad unchecking "Launch from snapshot" also means it doesn't save to a snapshot, so there is no way (that I can see) to recover it without deleting/recreating the AVD. Edit: Here is the bug, and actually there is a suggestion of how to recover the emulator, but tbh it is more effort than deleting the AVD: code.google.com/p/android/issues/detail?id=29923
    – Timmmm
    Jul 30, 2012 at 13:16
  • 1
    Never mind - I found the option you mention in the AVD 'Start' button dialog box rather than the run configuration options. Hope that helps someone. Nov 20, 2013 at 22:30
31

resolved issue by:

  1. going to project and selecting Clean
  2. going to Window>AVD Manager>Delete and create a new AVD
  3. Relaunch application, emulator will take a few minutes to load.
1
  • 5
    I think that deleting the AVD is an overkill in this situation. The simplest solution is to choose either Wipe User Data or use @Chilledrat's solution of to uncheck the Launch with snapshot, but keep Save snapshot checked, which will cause the snapshot to be ignored and overwritten the next time you close the virtual device.
    – Dzhuneyt
    Sep 24, 2012 at 8:27
14

To remove the list of stored snapshots in your system:

rm ~/.android/avd/[your_avd_name]/snapshots.img*
1
  • 4
    This has changed to rm -rf ~/.android/avd/[your_avd_name].avd/snapshots/
    – paul_h
    Feb 15, 2019 at 13:56
13

I had the same issue as Timmmm, nothing would resolve it.

Through the command line emulator.exe -avd avdname -snapshot default-boot gives me that same error. But I also noticed that it launches from the GUI just fine.

I went into the C:\users\uname\.android\avd\The_avd\ and deleted the snapshots.img.default-boot snapshot and the snapshots iso file.

It's easier than recreating the machine, but deletes your snapshot(s), and then you can use it again like normal.

10

Go to window-> Android Virtual Device Manager, choose your Virtual Device and Disable the Launch from snapshot and keep save to snapshot option and click Launch.

1
  • 2
    This is not a solution anyway, so it should be presented as a workaround. The problem is that error occurs EVEN when it is not true that hardware has changed, so if you actually WANT to use the Snapshot feature so emulator starts a lot of faster, you cannot due this problem. It seems like a bug anyway. I experience it randomly but most of the time I try to start an emulator instance WITHOUT changing nothing and having closing it the right way. Nov 20, 2012 at 11:33
9

Maybe try to disable the hardware snapshot in the Android Virtual Device Manager? It should be installed wherever you installed the android SDK.

enter link description here

3
  • This! deleting the AVD just to change one setting is nuts.
    – gcb
    Aug 30, 2013 at 0:41
  • 1
    I also had the same problem , i unchecked the "snapshot" option. It is working fine. Thanks Pratik. Sep 13, 2013 at 15:11
  • 1
    This should be this the real answer
    – Marcote
    Jul 11, 2014 at 13:53
3

In my case, it seems due to the fact that I closed my AVD between 2 launches of the same app, I got this error message at the second launch.

I didn't need to "Clean" the project, just launched the AVD manually using the AVD manager, waited for it to boot and launched the app again once booting was completed. Worked for me.

3

You may have been trying to start the emulator from AVD before this, and from the command line now. Most AVDs use arm instruction sets, so you may have to try something like:

emulator64-arm -avd <your avd label> -no-snapshot-load -no-snapshot-save
3

finally i got the solution follow these steps:

1)open avd manager
2)select the avd which is givin this err-"ERROR: Unable to load VM from snapshot. The snapshot has been saved for a different hardware configuration."
3)click on start
4)now uncheck these two options-"launch from snapshot" and "save snapshot"
5)now check "wipe user data"
6)start the avd now
7)as soon as the"ANDROID" is displayed, close the avd
8)now open avd manager again
9)uncheck "wipe user data"
10)check on these two options-"launch from snapshot" and "save snapshot"
11)now start the avd, it would be easily loaded from snapshots without errors

2

This is a known issue. Hopefully it will be fixed in the next release of the Android SDK but who knows? I think the solution from user1165694 is easier than the suggested solution on the issue.

2

In case anyone uses IntelliJ, in order to disable snapshot do the following:

  1. Open AVD
  2. Select your device and press Start...
  3. Uncheck Launch Snapshot
1

Please note : closing the Emulator AFTER the eclipse will cause this same error too. in that case there is no hardware change ofcourse but this Error will show up:

Unable to load Vm from snapshot. The snapshot has been saved for a different hardware configuration.

so always close Eclipse, BEFORE the Emulator.

0

Got this problem. And found a way. When i do not change anything in configuration, but just starting emulator once again. You need to click "power" button in emulator and then close it. One annoying thing that happens after start from snapshot is - i need to click power button to be able to unlock emulator.

0

In my case, this error was shown when I plugged a device whose USB debug mode hadn't been enabled. So no device could be found and running the application caused this error message to show depending on my last run configuration.

0

Its because of the process of exiting emulator not done properly. Try finding the running emulator by

ps -ef |grep emulator

Then it will list all the emulator tasks. Try killing the running emulator by

kill -9

Note: don't kill the following

user 0 11:27 pts/11 00:00:00 grep --color=auto emulator

-2

Clean the project and run on emulator with same api level.

If it still not resolves change once the api level of project and run on emulator with same api level.

In my case it runs ..........

0
-2

It is easier. You just have to change the name of your virtual Android device and then delete the one you do not charge and ready :)

Not the answer you're looking for? Browse other questions tagged or ask your own question.