Friday, July 12, 2019

htc - App can't be moved to SD card


There was an app moved to SD card.



I did a factory reset. Then I reinstalled the app. It was side loaded by Humble Bundle app, it's not from Google Play.


Now the app can't be moved to SD, getting error "Couldn't move app".


I am guessing there is this some type of Android's cache for this app on SD already that prevents it from moving again, but this is just a speculation.


Titanium backup couldn't move it either. Well, it said it did but it's still "on the phone".


Any ideas welcome.


The phone is HTC Sensation.



Answer



You most probably left some residuals of the (moved) app on your SD card.


The easiest way to remove that would probably to pull out the SD card and remove the moved app on your computer (it's not accessible on your phone easily).


For example, the full path to the moved tricorder app on my phone is: /mnt/sdcard/.android_secure/org.hermit.tricorder-1.asec



Just access it on your PC and remove the appropriate .asec file in the .android_secure folder.


Background (why not to do it on the phone):


Moved Apps are located in a cryptoloop mounted container file which is stored at /mnt/sdcard/.android_asec/*. This is however not accessible so that normal apps cannot mess around with moved apps (there's a tmpf mounted over /mnt/sdcard/.android_secure with 0kb space to inhibit access). The original .android_secure is bind mounted to /mnt/asec/secure where the system can access the containers.


app_36@android:/ $ mount 
# omitted unecessary stuff, only the sdcard, the bind mount and the tmpfs mount are shown
/dev/block/vold/254:1 /mnt/sdcard vfat [mount-options-omitted] 0 0
/dev/block/vold/254:1 /mnt/secure/asec vfat [mount-options-omitted] 0 0
tmpfs /mnt/sdcard/.android_secure tmpfs [mount-options-omitted] 0 0
# no output, tmpfs still mounted:
app_36@android:/mnt/sdcard/.android_secure # ls

app_36@android:/mnt/secure/asec # umount /mnt/sdcard/.android_secure
# umounted... now there's what we expect:
app_36@android:/mnt/secure/asec # cd /mnt/sdcard/.android_secure
app_36@android:/mnt/sdcard/.android_secure # ls
org.hermit.tricorder-1.asec

No comments:

Post a Comment

samsung galaxy s 2 - Cannot restore Kies backup after firmware upgrade

I backed up my Samsung Galaxy S2 on Kies before updating to Ice Cream Sandwich. After the upgrade I tried to restore, but the restore fails ...