Jun 19, 2011

Couldn't install on USB storage or SD card

troubleshooting

symptom
when updating apps installed on sd card, fail to install after downloading and "Couldn't install on USB storage or SD card." message is popped up

situation
  • apps installed on sd card
  • android 2.2
  • htc desire z
  • problem encountered on 2011-06-18

cause
it is believed caused by corrupted file system on sd card and file "smdl2tmp1.asec" is not correctly removed in previous installation

possible solution 1
  1. mount the sd card together with the device on a pc or mac via usb
  2. remove the file "smdl2tmp1.asec" located in /mnt/sdcard/.android_secure
notes
the file directory of ".android_secure" is not visible from android as it is protected by the os

possible solution 2
  1. move the app to phone memory / unmount sd card
  2. install update
  3. move the app to sd card

comments
  • this issue is solved on android 2.3 as described by others (not my experience)
  • keep a good practice of updating app in market such that no improper instruction/situation during the update procedures (e.g. sudden battery removal, force close market app during update)

reference
  • Fixing The "Couldn’t Install On USB Storage Or SD Card" Problem On Android (link)
  • intalling app unsuccessful - unknown error -18 - Android Market Help (link)