FORUMS

Download Sony’s new AOSP-like concept for Xperia Z3

Over in our forums, Recognized Contributor Jozinek has posted a very … more

OnePlus 2 vs Moto X Style: Which is The Better Flagship?

Two big industry names have announced their newest flagship phones within the … more

Making Your Own Xposed Modules Is Easier Than You Think

Close to the heart of XDA is the Xposed Framework by Rovo89. Most of … more

ZenFone 2 Lolliflash and ZenPower Giveaway!

We recently did an in-depth review of the Asus Zenfone 2 but one of the things people may … more

[SOLVED] install failed shared user incompatible

631 posts
Thanks Meter: 296
 
By tweakradje, Senior Member on 15th August 2011, 11:35 AM
Post Reply Subscribe to Thread Email Thread
EDIT 31aug2012: also this message appears if there is no "classes.dex" in the apk

Hi,

When you try to install certain apk you might get this error when using "adb install something.apk"

Andoid creates "shared users" like app_1 app_3 etc for packages you install. These UID's are like 10001, 10002, 10003 etc.

Sometimes the administration of these shared users gets messed up and you get error messages like:

INSTALL_FAILED_SHARED_USER_INCOMPATIBLE


The shared user administration is kept in /data/system:

-rw-rw-r-- system system 129933 2011-08-15 12:08 packages.xml


How to solve? You need a rooted phone and adb:

adb shell chmod 666 /data/system/packages.xml

adb pull /data/system/packages.xml


Now edit (notepad++) and remove the shared user in question xml block from the file:
Code:
<shared-user name="com.navngo" userId="10000">
<sigs count="1">
<cert index="4" />
</sigs>
<perms>
<item name="android.permission.READ_PHONE_STATE" />
<item name="android.permission.DISABLE_KEYGUARD" />
<item name="android.permission.INTERNET" />
<item name="android.permission.WRITE_EXTERNAL_STORAGE" />
<item name="android.permission.ACCESS_FINE_LOCATION" />
<item name="android.permission.ACCESS_LOCATION_EXTRA_COMMANDS" />
<item name="android.permission.ACCESS_COARSE_LOCATION" />
<item name="android.permission.READ_CONTACTS" />
<item name="android.permission.WRITE_CONTACTS" />
<item name="android.permission.ACCESS_NETWORK_STATE" />
<item name="android.permission.WAKE_LOCK" />
<item name="android.permission.MODIFY_AUDIO_SETTINGS" />
</perms>
</shared-user>
adb push packages.xml /data/system

adb shell rm /data/dalvik-cache/*

adb reboot


Now you should be able to install that apk.

Cheers
Last edited by tweakradje; 31st August 2012 at 12:40 PM.
The Following 34 Users Say Thank You to tweakradje For This Useful Post: [ View ]
 
 
24th August 2011, 09:06 AM |#2  
OP Senior Member
Flag Android
Thanks Meter: 296
 
More
This problem might also be solved using ad uninstall command. (only for user apps)

Lets keep the same program as above as an example the you type from a dos box:

adb uninstall com.navngo.igo.javaclient

Now install it again. You need to know the package name. You can open the apk with winrar/zip and view the AndroidManifest.xml file. There you see the package name.

Cheers
The Following 3 Users Say Thank You to tweakradje For This Useful Post: [ View ]
7th October 2011, 09:53 PM |#3  
Junior Member
Flag Vinnitsya
Thanks Meter: 4
 
More
Thumbs up thanks
thanks,
that's helped me to install new dolphin browser on mine superpad tablet pc
12th October 2011, 05:41 AM |#4  
Star.Dust's Avatar
Junior Member
Thanks Meter: 0
 
More
Hi,
I want to use android:sharedUserId="android.uid.system"

Then I get this error: Installation error: INSTALL_FAILED_SHARED_USER_INCOMPATIBLE

I removed the system uid following this procedure :P

It didn't work though

How to use system level privilege? I am working with hardware video codec, without system privilege. I am facing the same problem here : developer.nvidia.com/archived-tegra-forums/forum/android-how-call-libpvnvomxso-successfully

Any suggestion/idea would be welcome
8th December 2011, 06:18 PM |#5  
Junior Member
Thanks Meter: 0
 
More
Unhappy The deleted "android.uid.system" in packages.xml comes back after reboot.
Hi,

I followed the instructions to remove section of android.uid.system in packages.xml. But after reboot, I felt that this file was re-generated and overwritten by system itself. I still can't install my app due to the same incompatible error.

Any help? Thanks!
31st January 2012, 10:03 AM |#6  
Junior Member
Flag Coimbatore
Thanks Meter: 3
 
More
Comment out shared-user name="android.uid.shared" xml block
Quote:
Originally Posted by mylifeisjourney

Hi,

I followed the instructions to remove section of android.uid.system in packages.xml. But after reboot, I felt that this file was re-generated and overwritten by system itself. I still can't install my app due to the same incompatible error.

Any help? Thanks!


Hi,

It worked for me... All you want to do is just comment out the block of XML elements under <shared-user name="android.uid.shared" userId="10012">

Note: I have "Su" permission in my Device.

This is is how i did

<!-- <shared-user name="android.uid.shared" userId="10012">
<sigs count="1">
<cert index="3" />
</sigs>
<perms>
<item name="android.permission.USE_CREDENTIALS" />
<item name="com.google.android.googleapps.permission.GOO GLE_AUTH.mail" />
<item name="android.permission.WRITE_EXTERNAL_STORAGE" />
<item name="com.google.android.googleapps.permission.GOO GLE_AUTH.cp" />
<item name="android.permission.GET_ACCOUNTS" />
<item name="android.permission.READ_CONTACTS" />
<item name="android.permission.WRITE_CONTACTS" />
<item name="com.google.android.googleapps.permission.GOO GLE_AUTH" />
<item name="android.permission.READ_SYNC_STATS" />
<item name="android.permission.READ_PHONE_STATE" />
<item name="android.permission.READ_SMS" />
<item name="android.permission.MODIFY_PHONE_STATE" />
<item name="android.permission.WRITE_SETTINGS" />
<item name="android.permission.INTERNET" />
<item name="android.permission.SUBSCRIBED_FEEDS_READ" />
<item name="android.permission.VIBRATE" />
<item name="android.permission.SUBSCRIBED_FEEDS_WRITE" />
<item name="android.permission.WAKE_LOCK" />
<item name="android.permission.CALL_PRIVILEGED" />
</perms>
</shared-user> -->
The Following 2 Users Say Thank You to pradeepcse For This Useful Post: [ View ]
12th February 2012, 02:03 PM |#7  
Senior Member
Thanks Meter: 32
 
More
Quote:
Originally Posted by mylifeisjourney

Hi,

I followed the instructions to remove section of android.uid.system in packages.xml. But after reboot, I felt that this file was re-generated and overwritten by system itself. I still can't install my app due to the same incompatible error.

Any help? Thanks!

same here, after I change the file and reboot it restore the line
15th February 2012, 01:55 PM |#8  
Senior Member
Thanks Meter: 32
 
More
no one?
15th February 2012, 10:16 PM |#9  
OP Senior Member
Flag Android
Thanks Meter: 296
 
More
android.uid.system (id 1000) is used for installing packages and I think this trick only works for 10.000 and higher id's.

Use google to find out more about the problem: https://www.google.com/search?num=40...oid.uid.system

Cheers
The Following 2 Users Say Thank You to tweakradje For This Useful Post: [ View ]
30th May 2012, 08:26 PM |#10  
Member
Thanks Meter: 3
 
More
never mind
Last edited by it's; 30th May 2012 at 10:06 PM. Reason: -
30th May 2012, 10:10 PM |#11  
Member
Thanks Meter: 3
 
More
Okey, I did a small research to find out why my app was force closing everytime after I removed android:sharedUserId="android.uid.system" from AndroidManifest.xml.

It turned out that it doesn't have permission to force stop packages(it's a system monitor).

I have checked the androidmanifest.xml and everything looks correct to me. When installing, only wake lock and internet permissions are granted. I have attached the txt file... I hope somebody can help me out of here. :P
Attached Files
File Type: txt AndroidManifest.txt - [Click for QR Code] (1.0 KB, 855 views)

Read More
Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes