Quick Tip: Increase the storage size of your Android Emulator

Circuit board and shield icon on blue background with digital code

Are you tired of getting this error?

This happens when you’re testing your App on your Android Emulator. After a couple runs, the virtual device runs out of space, and you have to start deleting apps…pretty annoying.

Well, it’s easy to fix. It’s just a matter or increasing the storage size of your virtual device. First off, you need to know the name of the virtual device you are using. Assuming you’re running on OSX, Go to your terminal and type:

$ [[path-to-android-sdk]]/tools/android avd

This will show you a window with all the AVDs (Android Virtual Devices) you have configured. Find the one you’re using and write down its name.

Next, go back to your terminal and type

$ open -a TextEdit ~/.android/avd/[[name of your avd]].avd/config.ini

This opens TextEdit with the AVD’s configuration file. Now look for and change or add this line

data.dataPartition.size=512m

And that’s it. You’re set!

13 COMMENTS

  1. Boricuaaaa essssooo! Thanks for the tip, have run into this before… annoying to say the least. But no more!

  2. I agree with A. User’s comment above. There is no reason not to have this handled with the CLI and wired to the GUI in Titanium Studio.

  3. This didnt work for me.
    I still get the error. I didnt have the name in the first place so added it.
    Not sure if Ive got an old SDK or something.

  4. Didnt work for me either.

    This did work:

    Open AVD ($ [[path-to-android-sdk]]/tools/android avd)

    click on the AVD, and click Edit.

    In the section Hardware: click New and add ‘Ideal size of data partition’, it gets added to the list with a value of 0. Change it to 512MB or something else. If you don’t type MB, but for example 512m, it will change back to 0.

    Save, now the line disk.dataPartition.size=512MB is added to the config file, so manually typing that might also work.

    • Yes, this works. As well as changing directly to hardware-emu.ini works as well. This parameter basically sits in this file.

Comments are closed.