6

We have non rooted Droid Razr Maxx which we use for development. The device is shared between two of us and we both have been debugging/installing from eclipse directly without any errors. We do uninstall the previous version (as prompted) and reinstall the same. On one of the installation attempts today, we got the "Installation error: INSTALL_FAILED_UID_CHANGED" error.

Console in Eclipse shows the following message:

[2014-01-02 16:34:05 - xxxAppNamexxx] Installing xxxAppNamexxx.apk...
[2014-01-02 16:34:08 - xxxAppNamexxx] Installation error: INSTALL_FAILED_UID_CHANGED
[2014-01-02 16:34:08 - xxxAppNamexxx] Please check logcat output for more details.
[2014-01-02 16:34:08 - xxxAppNamexxx] Launch canceled!

Logcat shows the following message:

01-02 16:34:21.031: W/ActivityManager(467): No content provider found for permission revoke: file:///data/local/tmp/xxxAppNamexxx.apk
01-02 16:34:21.070: W/ActivityManager(467): No content provider found for permission revoke: file:///data/local/tmp/xxxAppNamexxx.apk
01-02 16:34:21.961: W/ActivityManager(467): Permission denied: checkComponentPermission() owningUid=10110
01-02 16:34:21.961: W/ActivityManager(467): Permission denied: checkComponentPermission() owningUid=10110
01-02 16:34:22.539: W/PackageManager(467): Package couldn't be installed in /data/app/com.halinc.halc2c.xxxAppNamexxx-1.apk

The directory /data when viewed using a file manager in a non-rooted phone is empty.This is catch 22 as the solutions provided seem to suggest either rooting the phone(Change /data/local Permissions) or doing a factory reset(Installation error: INSTALL_FAILED_UID_CHANGED). We are looking for some less painful solutions.

Community
  • 1
  • 1
  • "The directory /data when viewed using a file manager in a non-rooted phone is empty" -- that is because you do not have permission to view it. You can try this solution to see if it helps: http://stackoverflow.com/a/14380315/115145 – CommonsWare Jan 02 '14 at 23:57
  • 1
    @CommonsWare I tried the solution mentioned in the link and get a "Failure" on install and uninstall. – user3155380 Jan 03 '14 at 15:11
  • What we ended up doing was doing a factory restore. That is a big "Hail Mary" and I believe cannot be considered a solution. Adding what we did in case any one encounters a similar issue. – user3155380 Jan 08 '14 at 22:25

1 Answers1

0

This problem occurs if the installation of an APK file fails half-way (e.g. due an invalid classes.dex file). During the following rollback not all files are deleted from the /data/ directory hierarchy. Those files cause future installations of a package with the same name to fail with INSTALL_FAILED_UID_CHANGED.

This is a known bug since at least Android 2.2.

As far as I know there is no solution besides a factory reset on an unrooted phone.

HHK
  • 4,852
  • 1
  • 23
  • 40