views:

3866

answers:

11

I get this sometimes(not often) for one of my projects, couple of classes only
Installation error: INSTALL_FAILED_INSUFFICIENT_STORAGE

How do I increase emulator's storage?

A: 

The only time I've seen this happen it was when the host filesystem was basically out of space. Do you have much free space on the filesystem where the VM's filesystem is stored?

fiXedd
I have plenty of space on my hard disks 13GB free.
Pentium10
+1  A: 

I'm a beginner, but I had that problem while playing around with the "Hello Grid View". I was trying to use my own photos, which were all very large in file size.

The quick fix was to reduce the number of photos, thus reducing the size of the APK file.

But, I guess my follow up question for anybody else who hits this thread is this: How do I attach large files like JPGs and MP3s to an app and make sure they save on the SD Card so the APK remains small?

I think I found the answer here: http://developer.android.com/guide/topics/resources/index.htmlTry using "assets" instead of "resources" for any large elements.From the page:Resources are an integral part of an Android application. In general, these are external elements that you want to include and reference within your application, like images, audio, video, text strings, layouts, themes, etc. Every Android application contains a directory for resources (res/) and a directory for assets (assets/).
+4  A: 

this problem comes with android 1.5 .. try 2.0 or 2.1 or 2.2

Vishal
Thank you......
Pentium10
I'm getting this with 2.2 on my N1
Erik B
@Vishal i am getting on both 1.5 and 2.2 http://stackoverflow.com/questions/3584297/error-in-installation-of-an-application-on-sd-card-in-android-sdk-2-2
PM - Paresh Mayani
A: 

Hi, It is defenetly not a appropriate answer, but it is a small hint.

If you want to make use of static files in your App. You should put them as resources or as assets. But, if U have memory concerns like to keep your APK small, then you need to change your App design in such a way that,

instead of putting them as resources, while running your App(after installation) you can take the files(defenately different files as user may not keep files what you need) from SD Card. For this U can use ContentResolver to take audio, Image files on user selection.

With this you can give the user another feature like he can load audio/image files to the app on his own choice.

Andhravaala
A: 

I guess you should restart the emulator with "emulator -wipe-data -avd YourAvdName" or check "Wipe User Data" in run configuration if you are using Eclipse.

I am facing the same issue right now.

Roman Shestakov
A: 

I have the same problem. But I'm just not familiar on how to use the command emulator -wipe-data I tried it like this: C:\ emulator.exe -wipe -data -avd AVDv2.1 but it gives me an error: Unknown option -wipe

Also, how come "Wipe User Data" option is not in my Eclipse. I am using the Ganymede version

JoJo
It's -wipe-data not -wipe -data
I82Much
A: 

you can start the one when selecting one item from the left tree "virtual device" in AVD manager dialog on the platform of eclipse, the start UI has the option "Wipe User Data"

Jone
A: 

The following approach worked for me

  1. Navigate to your android SDK/tools folder in the terminal window (in case you didn't added the path for it)

  2. Make sure the virtual device you're planning to clean is powered off.

  3. Run the command "./emulator -wipe-data -avd YourAvdName" where YourAvdName is the name of your virtual android device

Anton
A: 

It works for me too, running command "emulator -wipe-data -avd YourAvdName". Thanks.

Tim
+2  A: 

I was searching for the answer to this question, and was unsatisfied with the above answers. But then I found the answer, so here it is for future reference:

http://groups.google.com/group/android-developers/browse_thread/thread/41852900bd603070/583943d91dc9f754?lnk=gst&q=insufficient+memory#583943d91dc9f754

To summarize (and clarify), in Eclipse, go to "Debug Configurations". You can find that in the drop-down under the "debug" icon. Select "target", and select a preferred emulator target to launch. Then under "additional emulator command line options," add this:

-partition-size 1024

Then CLOSE the emulator (and remove any devices), and click the debug icon, which will launch the preferred emulator you selected. This is important: Eclipse needs to launch the debugger, not AVD.

That fixed the problem for me.

SomeCallMeTim
A: 

You can wipe-user-data in eclipse by going to your run configuration settings choose Target tab, click Automatic then Start.... In the popup window you can select the option -wipe-user-data

pivotnig