1

I installed the October 2020 update for my Xiaomi A2, and then it entered a reboot loop, giving me a "Cannot load Android system" message.

Actually, when I boot up the phone, I automatically get to the recovery menu, which only gives me two options: wipe the data partition, or reboot. And rebooting sends me back to the recovery menu.

Here's what I did:

  • First, using fastboot, I reinstalled the entire OS except the data partition. That ended up in the same reboot loop.
  • Then, using TWRP and executing it with fastboot boot twrp-3.4.0-1-jasmine_sprout.img I could adb shell into my device. From there I ran an fsck -f which did find a couple inode problem. But fixing those problems still did yield the same reboot loop.
  • Using TWRP again, I locally cloned my data partition using adb pull /dev/block/mmcblk0p69 data.img, then I tried the "wipe the data partition" option. My phone did reboot properly, but of course it was reset to factory settings.

Question: is there a way I can restore my phone to a working state with my previous data? I really don't want to reconfigure all of it…

Also I don't really understand what's the problem with my original data partition. Is there a way to know why Android doesn't want to boot with it and why it sends me to the recovery partition?

More info:

  • Running fsck on the local data.img says it has no error whatsoever
  • I can mount the data.img and browse it. It's full of, well, files!
1
  • in twrp do 'adb pull /tmp/recovery.log' and check if there is something like "successfully decrypted" - be aware for FBE you can't wipe locksettings.db android.stackexchange.com/q/216155
    – alecxs
    Commented Nov 7, 2020 at 15:30

1 Answer 1

1

So, here's the best I could do:

  • Try to boot normally
  • The phone will crash and try to reboot to the recovery partition.
  • At that very instant, press volume down and power, so that it goes to fastboot instead
  • From fastboot, launch TWRP with fastboot boot twrp-3.4.0-1-jasmine_sprout.img
  • Once in TWRP, get a shell using adb shell
  • Then from this shell, look at the file /sys/fs/pstore/console-ramoops-0. It contains the previous kernel boot log!

In my case, here's what the boot log contains : init: Rebooting into recovery, reason: enablefilecrypto_faile. So apparently something is wrong with Androi File-Based Encryption

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .