I have an Android 8.1 device (encrypted, not rooted) that is configured to use an SD card as internal storage. That SDcard broke down and needed to be replaced.
After inserting a fresh replacement card, the device recognized it and asked how it should be formatted. I chose "internal", and the format went though without issues. The card shows up under "Storage" with the correct capacity, just as the old one did.
However, using this card is not possible. All apps that try to access it (like camera, browser downloads, file managers) show "SD card not available" errors.
When I connect to the device through adb shell
to check how the file systems are mounted, I can see a difference. This is what shows up when the old card is inserted:
bbb100:/ $ mount
[...]
/dev/block/dm-3 on /mnt/expand/beb7cb3c-0c09-43cf-83b8-ce1eac90a92b type ext4 (rw,dirsync,seclabel,nosuid,nodev,noatime)
/mnt/expand/beb7cb3c-0c09-43cf-83b8-ce1eac90a92b/media on /mnt/runtime/default/emulated type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1023,fsgid=1023,gid=1015,multiuser,mask=6,derive_gid)
/mnt/expand/beb7cb3c-0c09-43cf-83b8-ce1eac90a92b/media on /storage/emulated type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1023,fsgid=1023,gid=1015,multiuser,mask=6,derive_gid)
/mnt/expand/beb7cb3c-0c09-43cf-83b8-ce1eac90a92b/media on /mnt/runtime/read/emulated type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1023,fsgid=1023,gid=9997,multiuser,mask=23,derive_gid)
/mnt/expand/beb7cb3c-0c09-43cf-83b8-ce1eac90a92b/media on /mnt/runtime/write/emulated type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1023,fsgid=1023,gid=9997,multiuser,mask=7,derive_gid)
bbb100:/ $
and this appears when the new card is inserted:
bbb100:/ $ mount
[...]
/dev/block/dm-3 on /mnt/expand/49d563a3-0905-4173-a1b3-8c29e3917d2c type ext4 (rw,dirsync,seclabel,nosuid,nodev,noatime,data=ordered)
bbb100:/ $
So it seems the new card is not initialized correctly and/or several directories do not get mounted for whatever reason.
Things I tried to no avail:
- re-formatting the card
- eject, mount
- reboot the device
- ran
sm partition disk:179,64 private
inadb shell
just to see if there are any errors on the console (via) - there is no error - tried with different SD card (also brand new) - same behavior
- copied device- and partition UUIDs (PTUUID, PARTUUID) from old SD card to new card using
gdisk
, hoping that Android would recognize the new card as "known" and mount it. It doesn't.
What's going on here and what else can I do to make the card work?