Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android: Installation error: INSTALL_FAILED_INSUFFICIENT_STORAGE

Tags:

android

device

I'm getting "Installation error: INSTALL_FAILED_INSUFFICIENT_STORAGE" error while installing the application on my device today. It is working fine till yesterday, today only im facing this problem. I have deleted some files on my SD card, but still facing the issue. I'm sure it is not the issue with the space on SD card. Can anybody suggest how to resolve this.

--nehatha

like image 287
Venkat Papana Avatar asked Aug 20 '11 16:08

Venkat Papana


4 Answers

It got resolved by having android:installLocation="preferExternal" for <manifest> tag of manifest file.

Like below:

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="bros.imaq.demilic"
    android:versionCode="1"
    android:versionName="1.0"
    android:installLocation="preferExternal">

Thank you

like image 74
Venkat Papana Avatar answered Oct 23 '22 15:10

Venkat Papana


You need to do two things after which this error will be resolved.

  1. In your AndroidManifest.xml file add android:installLocation="preferExternal" within your manifest tag.

    <manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.packagename.appname"
    android:versionCode="1"
    android:versionName="1.0" 
    android:installLocation="preferExternal">
    
  2. More importantly, clear the cache data in your device. Goto settings -> storage -> click on cached data. This will clear the cache and free the space.

  3. Reconnect your device, clean your project and again run it on the device. The project will now run on your device.

like image 20
Kaveesh Kanwal Avatar answered Oct 23 '22 15:10

Kaveesh Kanwal


In my case the solution using the manifest tag didn't work, as there was no Android resource for that tag.

What did work was simply uninstalling the app on the phone. And the few other versions I had installed simultaneously.

like image 4
Wytze Avatar answered Oct 23 '22 17:10

Wytze


fixed my issue. problem was that i had set the set the install location via adb on my rooted KitKat 4.4.2 phone at one time, to put my apps on an SD Card:

adb shell
pm set-install-location 2

Said card was cheap and failed. even if i set the default location to the internal SD card, even if i removed the "damaged" (cheap and useless) SD card, i could now install no apps... but all is well now, the solution was to run

pm set-install-location 2
like image 3
mahesh Avatar answered Oct 23 '22 17:10

mahesh