Unable to install APK!

I used to build many times and test my unity’s apks on my android but suddenly this:

Error building Player: UnityException: Unable to install APK!

Installation failed with the following output:
	pkg: /data/local/tmp/Package.apk

Failure [INSTALL_FAILED_CONTAINER_ERROR]

rm failed for -f, No such file or directory

2958 KB/s (10766339 bytes in 3.554s)

UnityEditor.HostView:OnGUI()

Happends to all of my android projects.

Please, if anyone could help me out with solving this. /=

Solved, replace the storage in player settings from “Internal Only” to “Automatic”.

Also check if you are trying to install a different app of the same name as the one you already have installed. This was my issue. Sounds silly, but i struggled to fix it.

I ran in he same problem but the previous solution didn’t solve it. What seems to have worked is to free up space on my device. I had roughly 300MB left on my internal memory for a 43MB APK. Hope this can help somebody.

I had to uninstall the app on my phone to get it to install.

I was having issues with my Keystore, and I think it was applying a different keystore/unsigned.

Greetings!
I’m having a similar problem with a virtual reality application.
I’m using gvr-unity-sdk-mater in version 1.0.3 and the version of my Unity is 5.4.2f1.
My device is a Galaxy Win Duos, model GT-I8552B and I have 1GB of internal memory.
The Android version is 4.1.2.
I already dive into the internet looking for solutions like build and export my .apk to the phone, but when I try to install it gives an exception of the type (there is a problem of package analysis). USB debugging is enabled and sources unknown as well, but the problem still persists.
In the project settings, “Virtual Reality Supported” is enabled, but I also tried disabling it and doing the build, and Minimum API Level is set to 4.0.3, but I already tested it for 4.1 and gives the same error. When running in the editor, everything works normally. “Install Location” is set to automatic, remembering that there is no previous installation of this .apk on my device.
I’ve seen in some tutorials the developers use a version earlier than mine, something like 5.3.1, something like that, but I’m not sure if it’s the version of Unity that causes the disorder.
I ask your help to help me solve this error so that I can test my application on my device.

Greetings! I’m having a similar problem with a virtual reality application. I’m using gvr-unity-sdk-mater in version 1.0.3 and the version of my Unity is 5.4.2f1. My device is a Galaxy Win Duos, model GT-I8552B and I have 1GB of internal memory. The Android version is 4.1.2. I already dive into the internet looking for solutions like build and export my .apk to the phone, but when I try to install it gives an exception of the type (there is a problem of package analysis). USB debugging is enabled and sources unknown as well, but the problem still persists. In the project settings, “Virtual Reality Supported” is enabled, but I also tried disabling it and doing the build, and Minimum API Level is set to 4.0.3, but I already tested it for 4.1 and gives the same error. When running in the editor, everything works normally. “Install Location” is set to automatic, remembering that there is no previous installation of this .apk on my device. I’ve seen in some tutorials the developers use a version earlier than mine, something like 5.3.1, something like that, but I’m not sure if it’s the version of Unity that causes the disorder. I ask your help to help me solve this error so that I can test my application on my device.

For android devices -
check developer settings.
On some devices you could find a setting ‘install via usb’ right bellow ‘usb debugging’ setting.
Enable this setting.

Hopefully, this helps.

For me the problem was that i had a guest user in my device(which i did not create and never used) and there i dont know how but my app was installed.
So i deleted the app from the guest user and it solved the problem for me.

Tip: go to the settings in your device and in the search write your app’s name. That is how i found that my app is installed on the guest user.

i had the same name game already installed thats why it was not installing,i deleted other one and now new apk is installed.

For Unity 2019:

I had to update the Target Architectures to make sure that x86 was checked for my Emulator.

Player Settings > Other Settings > Configuration > Target Architectures > Check all boxes

Here are the things to try:

In Player Settings / Android tab

Untick Publishing Settings / Use legacy SDK tools

Minify / Release : Gradle (Experimental)

Voodoo stuff:

  • Try to select “Gradle” in Build Settings (CMD+SHIFT+B)** / Build System** , even it seems selected, select it again manually.
  • Same with keystore: even if it seems its selected and Key/alias is selected and passwords are filled the editor might be bugged so just try to start from scratch and Browse for the (same) keystore.