android平板重启apk消失不见

重启平板,FactoryTest软件消失不见,查看log:

03-14 19:15:30.020: I/PackageManager(360): /system/app/FactoryTest.apk changed; collecting certs

03-14 19:15:30.040: W/PackageManager(360): Package com.starnet.factorytest at /system/app/FactoryTest.apkreverting from /data/app/com.starnet.factorytest-1.apk: new version 1 better than installed 1

03-14 19:15:30.040: I/PackageManager(360): Package com.starnet.factorytest codePath changed from /data/app/com.starnet.factorytest-1.apk to /system/app/FactoryTest.apk; Retaining data and using new

03-14 19:15:30.050: W/PackageManager(360): Signature mismatch for shared user : SharedUserSetting{4120fd58 android.uid.system/1000}
03-14 19:15:30.050: W/PackageManager(360): Package com.starnet.factorytest shared user changed from to android.uid.system; replacing with new

03-14 19:15:30.050: E/PackageManager(360): Package com.starnet.factorytest has no signatures that match those in shared user android.uid.system; ignoring!

是由于我在/system/app/目录下也放置了FactoryTest.apk; (此apk不能正常显示,没签名),我在/data/app/也安装了FactoryTest.apk(此apk会显示出来)。在重启后由于会判断/system/app/与/data/app/,由于我安装重复,判断为“ new version 1 better than installed 1”,故此把/data/app/下能正常显示的FactoryTest.apk给清除了,所以apk消失。

解决:android:versionCode="1"
    android:versionName="1.0" 版本改为

android:versionCode="2"
    android:versionName="2.0" 即可。

或是把/system/app/的apk删除即可。

你可能感兴趣的:(android小知识)