[Unlock Bootloader + TWRP + ROOT + CUSTOM ROM] Working on Xiaomi Mi 10T/Pro

Did you found this helpfull? Did it work for you?


  • Total voters
    29
Search This thread
This guide should be corrected somewhere.
Me, like other people, faced the same problem at step 13, before that all was fine.
Idk why, but i tried 2 times the entire procedure and got stuck in twrp reboot.
I tried using both Whale and Geoanto555 twrps but nothing changed.
After step 13 some error pop up and the phone is encrypted with a non-existing password.
True. I just installed Magisk and skipped the rest of the steps.
 
  • Like
Reactions: James_Mont

James_Mont

Member
May 2, 2017
8
2
Ok, managed to solve the problem.

For some reason, when extracting vbmeta.zip first-time, the directory was created instead file inside zip.
That's the reason I get an error - 'Is a directory.' - Don't know why... :unsure:
After that, I flashed vbmeta, decrypt, install zip, install magisk, everything works like charm again...:cool:
Can i ask how you decrypted after the vbmeta flash ?
It's all ok until i flash vbmeta and my phone "resume" the encryption and i cannot do anything because it ask for a password that i don't know.
How do you proceed exactly ?
Maybe my problem have something to do with the mi account association ?
I noticed (all the 3 times that i had to roll back with mi flash) that the phone tells me about association with mi account and i have to relog before starting the configuration and everything is fine.
Thx
 

d_man33

New member
May 10, 2012
4
1
Can i ask how you decrypted after the vbmeta flash ?
It's all ok until i flash vbmeta and my phone "resume" the encryption and i cannot do anything because it ask for a password that i don't know.
How do you proceed exactly ?
Maybe my problem have something to do with the mi account association ?
I noticed (all the 3 times that i had to roll back with mi flash) that the phone tells me about association with mi account and i have to relog before starting the configuration and everything is fine.
Thx
After flashing vbmeta.img (the one from MIUI zip), you should be able to bootup into MIUI. Still stuck?
 
  • Like
Reactions: James_Mont

Poppeye0

Senior Member
Nov 16, 2011
109
50
Hello, I have unlocked the bootloader, flashed TWRP and then installed Xiaomi.eu latest weekly. However, now the phone always boots to TWRP. When entering the install script in TWRP I first get a message "E:Unable to decrypt FBE device" but then a few moments later "Encryption status: not encrypted". I tried to format data / factory reset but it doesn't help, neither does re-flashing the ROM.

What can I do?
 

Desmanto

Senior Member
Apr 2, 2014
417
448
Xiaomi Mi 10T / 10T Pro
Hello, I have unlocked the bootloader, flashed TWRP and then installed Xiaomi.eu latest weekly. However, now the phone always boots to TWRP. When entering the install script in TWRP I first get a message "E:Unable to decrypt FBE device" but then a few moments later "Encryption status: not encrypted". I tried to format data / factory reset but it doesn't help, neither does re-flashing the ROM.

What can I do?
It seems to be the same problem with xiaomi.eu ROM here :

Reflashing the ROM should have save the phone. But it seems to be similar to my case, after flashing, still have to let go of the data, do a factory reset and it should boot again. I have partial backup of my data (as TWRP restore is not working), so it is just PITA several hours to restore the data again.
 

James_Mont

Member
May 2, 2017
8
2
After flashing vbmeta.img (the one from MIUI zip), you should be able to bootup into MIUI. Still stuck?
I have not tried to flash vbmeta extracted from miui rom, but it's a solution.
I've simply reflashed the stock rom with miflash and probably i'll wait for the release of an official twrp and any aosp rom that will support ota.

I suppose that the problem that i faced is because the phone is linked with my miui accout, but i'm not 100% sure.
 

Poppeye0

Senior Member
Nov 16, 2011
109
50
I found the solution for installing custom ROMs for the first time and it's a far cry from the process described on the first page. It always involves losing your data. I am in doubt that there's a good process at the moment that'll allow you to keep your data when moving away from the stock ROM. In short, the process involves this:

1. Put the phone into fastboot mode. Do not install TWRP but simply boot into it with i.e.
Code:
fastboot boot twrp.img

2. When in TWRP transfer your ROM (and Magisk if you want root) from your PC to the internal storage. With the correct drivers on your PC you should be able to do a data transfer as always. Flash ROM and optionally Magisk. Do not flash DMVerity remover!

3. After you have successfully flashed ROM and Magisk, reboot once again into recovery, not into system.

4. You'll now find yourself in stock recovery. You'll have to do a data wipe. After that you can boot into the system of your new ROM. That's it.

You might be able to flash TWRP permanently after this but I would advise against it. Incompatible TWRP is the main source of bootloops (fastboot and recovery loops amongst them). For some reason stock recovery is the only way to correctly wipe the data partition. This might have something to do with the filesystem and/or SE Linux context but until somebody finds out a secure alternative method I for my part will not flash TWRP.

If you want to upgrade your custom ROM the next time, you should be able to do it with steps 1-3, booting into system after that.
 
Last edited:

Desmanto

Senior Member
Apr 2, 2014
417
448
Xiaomi Mi 10T / 10T Pro
I have not tried to flash vbmeta extracted from miui rom, but it's a solution.
I've simply reflashed the stock rom with miflash and probably i'll wait for the release of an official twrp and any aosp rom that will support ota.

I suppose that the problem that i faced is because the phone is linked with my miui accout, but i'm not 100% sure.
Mine also linked and have no problem until I flashed the vbmeta. Reflashing vbmeta from MIUI ROM boot it back.

To update OTA for MIUI ROM, it seems there are partitions changes happend from A10 to A11. You have to disable all magisk modules first before flashing.

I found the solution for installing custom ROMs for the first time and it's a far cry from the process described on the first page. It always involves losing your data. I am in doubt that there's a good process at the moment that'll allow you to keep your data when moving away from the stock ROM. In short, the process involves this:

1. Put the phone into fastboot mode. Do not install TWRP but simply boot into it with i.e.
Code:
fastboot boot twrp.img

2. When in TWRP transfer your ROM (and Magisk if you want root) from your PC to the internal storage. With the correct drivers on your PC you should be able to do a data transfer as always. Flash ROM and optionally Magisk. Do not flash DMVerity remover!

3. After you have successfully flashed ROM and Magisk, reboot once again into recovery, not into system.

4. You'll now find yourself in stock recovery. You'll have to do a data wipe. After that you can boot into the system of your new ROM. That's it.

You might be able to flash TWRP permanently after this but I would advise against it. Incompatible TWRP is the main source of bootloops (fastboot and recovery loops amongst them). For some reason stock recovery is the only way to correctly wipe the data partition. This might have something to do with the filesystem and/or SE Linux context but until somebody finds out a secure alternative method I for my part will not flash TWRP.

If you want to upgrade your custom ROM the next time, you should be able to do it with steps 1-3, booting into system after that.
Moving from one type ROM to another type should always involve factory reset. The encryption seesm to make it more obvious. However upgrading along the same ROM usually can use dirty flash (at some cases still require reset though).

What I need right now is a working TWRP which can backup and properly restore /data. It is somehow not comfortable knowing that I can't do weekly TWRP backup.
 

Sub8

Senior Member
Jan 31, 2009
92
17
Marija Bistrica
Can i ask how you decrypted after the vbmeta flash ?
It's all ok until i flash vbmeta and my phone "resume" the encryption and i cannot do anything because it ask for a password that i don't know.
How do you proceed exactly ?
Maybe my problem have something to do with the mi account association ?
I noticed (all the 3 times that i had to roll back with mi flash) that the phone tells me about association with mi account and i have to relog before starting the configuration and everything is fine.
Thx

I have set the pin to unlock my phone, the same pin is used to decrypt data in twrp. (if we are talking about same
decrypt...)

The problem that I had is installing zips via TWRP.

If I remember correctly, steps are:

1. flash vbmeta via fastboot
2. boot into TWRP
3. push vbmeta zip to sd card
4. install vbmeta zip
5. mount data (you will bi asked for decryipt pass)
6. decrypt data
7. install zip (e.g. magisk)

After that, I was able to install zip in twrp.
 

calinorg

Senior Member
  • I found the solution for installing custom ROMs for the first time and it's a far cry from the process described on the first page. It always involves losing your data. I am in doubt that there's a good process at the moment that'll allow you to keep your data when moving away from the stock ROM. In short, the process involves this:

    1. Put the phone into fastboot mode. Do not install TWRP but simply boot into it with i.e.
    Code:
    fastboot boot twrp.img

    2. When in TWRP transfer your ROM (and Magisk if you want root) from your PC to the internal storage. With the correct drivers on your PC you should be able to do a data transfer as always. Flash ROM and optionally Magisk. Do not flash DMVerity remover!

    3. After you have successfully flashed ROM and Magisk, reboot once again into recovery, not into system.

    4. You'll now find yourself in stock recovery. You'll have to do a data wipe. After that you can boot into the system of your new ROM. That's it.

    You might be able to flash TWRP permanently after this but I would advise against it. Incompatible TWRP is the main source of bootloops (fastboot and recovery loops amongst them). For some reason stock recovery is the only way to correctly wipe the data partition. This might have something to do with the filesystem and/or SE Linux context but until somebody finds out a secure alternative method I for my part will not flash TWRP.

    If you want to upgrade your custom ROM the next time, you should be able to do it with steps 1-3, booting into system after that.
    People are mostly having recovery bootloops because they do fastboot flash boot recovery.img instead of fastboot boot recovery.img (you wouldn't believe the amount of times I've seen this)...
    Other main source of issues is flashing roms all around - they flash xiaomi EU then 12.5 alpha over it then go back to stock via Twrp, and end up with artefacts from 3 different roms, all with excuse that stock fastboot rom is too big, so they go with recovery rom...
     

    StatDam

    Member
  • Mar 11, 2021
    46
    27
    This guide should be corrected somewhere.
    Me, like other people, faced the same problem at step 13, before that all was fine.
    Idk why, but i tried 2 times the entire procedure and got stuck in twrp reboot.
    I tried using both Whale and Geoanto555 twrps but nothing changed.
    After step 13 some error pop up and the phone is encrypted with a non-existing password.
    Dude, literally I corrupted my phone after installing andrax. Nothing was working, nothing opened, screen didn't unlock. When I went to recovery, the recovery was corrupted too, there was no recovery, and then out of nowhere some chinese bullsh*t came on the screen. Fastbooted back TWRP, formated data + advanced wipe. Flashed ROM and everything works as normally. I nearly hard bricked the device, you don't know what HARD is.

    -- Try to use LR Recovery or PBRP recovery --
     

    mikekap

    Member
  • Dec 29, 2020
    14
    3
    Can you use Miflash tool to unlock bootloader? I see the link for miflash tool is posted to unluck bootloader. How is this possible?
    It'a fairly easy if you follow the directions on the first page, and you enable usb debugging, e.t.c. It may say that you'll need 168 hours or less on the device after you apply in miflash to unlock the bootloader, so you have to wait. After you do that you log in with your mi account in miflash tool and you are good to go. Remember to backup your files, because they are going to be deleted.
     

    papipucuk

    New member
    Jan 21, 2017
    3
    0
    Xiaomi Mi 10T / 10T Pro
    Can i ask how you decrypted after the vbmeta flash ?
    It's all ok until i flash vbmeta and my phone "resume" the encryption and i cannot do anything because it ask for a password that i don't know.
    How do you proceed exactly ?
    Maybe my problem have something to do with the mi account association ?
    I noticed (all the 3 times that i had to roll back with mi flash) that the phone tells me about association with mi account and i have to relog before starting the configuration and everything is fine.
    Thx
    same issue. can't decrypt data with security code. please help. now my apollo stuck on recovery mode
     

    trinimike100

    Senior Member
    Oct 28, 2012
    86
    10
    It'a fairly easy if you follow the directions on the first page, and you enable usb debugging, e.t.c. It may say that you'll need 168 hours or less on the device after you apply in miflash to unlock the bootloader, so you have to wait. After you do that you log in with your mi account in miflash tool and you are good to go. Remember to backup your files, because they are going to be deleted.
    Miunlock tool and mi flash tool are two different things. I cannot find any option to unlock bootloader on miflash tool. Nothing online either
     

    Top Liked Posts

    • There are no posts matching your filters.
    • 2
      I found the solution for installing custom ROMs for the first time and it's a far cry from the process described on the first page. It always involves losing your data. I am in doubt that there's a good process at the moment that'll allow you to keep your data when moving away from the stock ROM. In short, the process involves this:

      1. Put the phone into fastboot mode. Do not install TWRP but simply boot into it with i.e.
      Code:
      fastboot boot twrp.img

      2. When in TWRP transfer your ROM (and Magisk if you want root) from your PC to the internal storage. With the correct drivers on your PC you should be able to do a data transfer as always. Flash ROM and optionally Magisk. Do not flash DMVerity remover!

      3. After you have successfully flashed ROM and Magisk, reboot once again into recovery, not into system.

      4. You'll now find yourself in stock recovery. You'll have to do a data wipe. After that you can boot into the system of your new ROM. That's it.

      You might be able to flash TWRP permanently after this but I would advise against it. Incompatible TWRP is the main source of bootloops (fastboot and recovery loops amongst them). For some reason stock recovery is the only way to correctly wipe the data partition. This might have something to do with the filesystem and/or SE Linux context but until somebody finds out a secure alternative method I for my part will not flash TWRP.

      If you want to upgrade your custom ROM the next time, you should be able to do it with steps 1-3, booting into system after that.
    • 10

      [CONFIRMED] ( WORKING ON XIAOMI MI 10T/PRO )​



      |-Full tutorial for everything-|

      /** * Your warranty is now void. * * We are not responsible for bricked devices, dead SD cards, * thermonuclear war, or you getting fired because the alarm app failed. Please * do some research if you have any concerns about features included in this ROM * before flashing it! YOU are choosing to make these modifications, and if * you point the finger at us for messing up your device, we will laugh at you. **/


      ---Unlocking bootloader---


      This is one of the easiest parts of this tutorial.
      -Please keep in mind that this process will reset your device-

      You will need:

      • Xiaomi Mi 10T/PRO device
      • USB cable
      • Computer
      • MiFlash tool (official by Xiaomi for unlocking bootloader) [LINK]
      • 168 hours already spent on your Xiaomi device (It is a security feature that you cannot bypass)​
      • USB drivers for your device [LINK]
      • Created Xiaomi Account (Used to log in to the MiFlash tool --> so you could unlock your specific device that has the same account on it) [LINK]
      • ADB, Fastboot tools on Windows [LINK]
      -And that should everything needed for unlocking your bootloader-​

      Process:

      1. Open Settings --> About Phone --> TAP on your MIUI version till you see (You are now a developer)
      2. 1615716824282.png
      3. Go to Additional Settings --> Developer Options --> OEM Unlock + Mi Unlock Status + USB Debugging
      4. 1615713637531.jpg
      5. Go to Mi Unlock Status --> Add your Account (If you have not already) and device (Do what you see on the screen)
      6. 1615713637526.jpg
      7. Enable USB Debugging + Change Default USB Configuration (saves us some time)
      8. 1615713637522.jpg
      9. 1615713637510.jpg
      10. 1615713637500.jpg
      11. Plug your Xiaomi Mi 10T/Pro into the computer and choose on your mobile File Transfer. If anytime it asks you to prompt USB debugging from your computer --> Allow it and set it always to allow this computer.
      12. You will now run Command prompt as ADMIN. Go to your ADB, Fastboot tools path with $ cd C:\YOUR\PATH\TO\PLATFORM\TOOLS (now your adb and fastboot commands will work)
      13. Check if your device is connected to the computer --> $ adb devices Now go to fastboot $ adb reboot bootloader
      14. Open the MiFlash tool and log in to your Xiaomi Account --> Hit refresh and you should see your Xiaomi Mi 10T/Pro device (It will have a different name in the program --> fastboot name) Now hit UNLOCK, and that is all, your device is now Unlocked.
      15. OPTIONAL: If your device has not appeared in the MiFlash tool, open up Driver Booster and check for Drivers, update any MISSING DRIVERS and try again (The program works 100%, but sometimes it does not show the device because of NONE USB drivers in Fastboot mode or BAD USB drivers --> if you fix this you can easily Unlock it like in step 7.)
      16. Now your DEVICE will reset and show you a little icon of an unlocked lock on the top of the screen, which means your bootloader is unlocked.
      17. DONE




      ---Flashing TWRP and ROOT---


      You will need:

      • Xiaomi Mi 10T/PRO device
      • USB cable
      • Computer
      • TWRP image (should be renamed to recovery.img) [LINK]
      • Vbmeta - This is used to flash to vbmeta, so No-verity-opt-encrypt could work (the file is inside vbmeta.zip called vbmeta.img) [LINK]
      • No-verity-opt-encrypt - this is used so we could decrypt our phone storage (in short --> so we could WIPE everything --> very useful when flashing custom ROMS) [LINK]
      • MAGISK for ROOT (rename .apk to .zip) [LINK] (could be outdated in the future, search for Magisk GitHub and download the latest .apk version)

      Process:

      1. Plug your Xiaomi Mi 10T/Pro into the computer and choose on your mobile File Transfer. If anytime it asks you to prompt USB debugging from your computer --> Allow it and set it always to allow this computer.
      2. You will now run Command prompt as ADMIN. Go to your ADB, Fastboot tools path with $ cd C:\YOUR\PATH\TO\PLATFORM\TOOLS (now your adb and fastboot commands will work)
      3. Check if your device is connected to the computer --> $ adb devices Now go to fastboot $ adb reboot bootloader
      4. Your downloaded files should be in your ADB, Fastboot folder so you can flash them (TWRP, vbmeta)
      5. Now type $ fastboot flash recovery recovery.img
      6. After that is done, we will go to the recovery. Type $ fastboot boot recovery.img this will boot us into the recovery.
      7. Now you should be in TWRP recovery.
      8. Now we can flash MAGISK. Firstly we need to send it to our mobile phone. $ adb push Magisk.zip /sdcard (name of the magisk will be different)
      9. Go to the Install section on your phone and select Magisk --> now, swipe. Now you should have Magisk successfully flashed into your device.
      10. Exit from recovery to system. --> Reboot section --> choose System (on the top)
      11. If everything goes right, you can now run MAGISK apk, and it will ask you for additional things, etc.; etc., click OK, and your phone will reboot after 5 seconds. Congratulations, you have successfully installed TWRP recovery, and you have ROOT too.
      12. Now let's go back to fastboot mode. This time we will use MAGISK. On the top right side should be a "reload button," click it and select REBOOT TO BOOTLOADER.
      13. On your computer, now flash vbmeta with this command. $ fastboot flash vbmeta vbmeta.img.
      14. Next type $ fastboot boot recovery.img to go back to recovery, we need to flash now the no-verity-opt-encrypt. When you are there, push that file to your mobile like this. $ adb push Disable_Dm-Verity_ForceEncrypt_11.02.2020.zip /sdcard (name of the file could be different). Once that is done, go to the install section, click on the no-verity-opt-encrypt, and swipe to flash it.
      15. Now you can reboot to System and download the Official TWRP app [LINK] (might be outdated, search for TWRP Official app apkmirror, and download the latest version)
      16. This app is handy for flashing other versions of TWRP without the need for a computer. GUIDE: Open the app --> TWRP Flash --> It will ask you to prompt SuperUser rights, click allow. --> You will see two buttons (Select a device and Select a file to flash) --> The Select Device option is left empty (No device selected) and now click on the Select a file to flash and choose your .img file of TWRP. Now you tap, FLASH TO RECOVERY, and you are done.
      17. DONE


      ---Flashing custom ROMS---

      You will need:

      • Xiaomi Mi 10T/PRO device
      • USB cable
      • Computer
      • Your custom ROM .zip file
      • Everything else mentioned in this tutorial (TWRP, MAGISK, etc...)

      Process:

      1. Go to the recovery using Magisk or whatever you like.
      2. This time, we will go to the WIPE section. Do a regular SWIPE --> then FORMAT DATA (type YES) --> then Advanced WIPE (select everything EXCEPT for USB OTG)
      3. Now, if you did everything right, there should not be many errors (It should always show SUCCESSFUL on the top of the screen when operating)
      4. Now we can push our custom ROM .zip file to our Xiaomi Mi 10T/Pro device. The command should look like this $ adb push Evolution_X.zip /sdcard (the name of the custom ROM can be different)
      5. Go to the Install section, select your custom ROM and install it. Now, pray that nothing goes wrong. I have done it right with THIS EXACT TUTORIAL (made by my friend and me). If anything bad happens, ask me for help if you need it. Reboot to the System and ENJOY your new ROM.
      6. DONE
      I hope that this helped you. I had to find pretty much all of this on my own. Enjoy.

      There are more Custom ROMS for Xiaomi Mi 10T/Pro:
      (not on xda, but a Telegram group)

      TELEGRAM GROUPS:
      MOD EDIT: Telegram link removed, please read the STICKY!

      PitchBlackRecoveryProject (might not work for everyone)
      [LINK]
      3
      I am stuck in fastboot mode after flashing vbmeta. How can I boot the phone to normal?
      I'm not in any way a pro at this but this is what Whyle told me to do when I faced the same issue. Try this, download the MIUI rom that you were on before, extract vbmeta.img from the rom, flash that vbmeta back via fastboot. If it still wont boot, you could just flash boot.img ( also extracted from the MIUI rom that you were from ) to boot and recovery. But that would delete all your data which is what I've done.

      The command for flashing the boot.img is

      fastboot flash boot boot.img
      fastboot flash recovery boot.img
      fastboot reboot

      You will still be booted to an unlocked bootloader tho. Hope it helps.
      2
      Thanks for guide, might help someone.

      For this device there only exist two custom ROMS for now, Evolution X and Lineage OS

      That is not correct. Those two are the ones you will find ond XDA but on Telegram there is more roms.
      Lineage has not been updated since December but there is a unofficial 18.1 made by someone on Telegram, seems it is for testing only and not released yet.

      There is these roms besides Evo X and Lineage:

      Project 404
      HentaiOS
      CrDroid
      Fluid
      AncientOS
      Pixel Experience - To be released soon.

      There is more roms but they are not updated and is not worth mentioning here.
      2
      I found the solution for installing custom ROMs for the first time and it's a far cry from the process described on the first page. It always involves losing your data. I am in doubt that there's a good process at the moment that'll allow you to keep your data when moving away from the stock ROM. In short, the process involves this:

      1. Put the phone into fastboot mode. Do not install TWRP but simply boot into it with i.e.
      Code:
      fastboot boot twrp.img

      2. When in TWRP transfer your ROM (and Magisk if you want root) from your PC to the internal storage. With the correct drivers on your PC you should be able to do a data transfer as always. Flash ROM and optionally Magisk. Do not flash DMVerity remover!

      3. After you have successfully flashed ROM and Magisk, reboot once again into recovery, not into system.

      4. You'll now find yourself in stock recovery. You'll have to do a data wipe. After that you can boot into the system of your new ROM. That's it.

      You might be able to flash TWRP permanently after this but I would advise against it. Incompatible TWRP is the main source of bootloops (fastboot and recovery loops amongst them). For some reason stock recovery is the only way to correctly wipe the data partition. This might have something to do with the filesystem and/or SE Linux context but until somebody finds out a secure alternative method I for my part will not flash TWRP.

      If you want to upgrade your custom ROM the next time, you should be able to do it with steps 1-3, booting into system after that.
      1
      After flashing disable dm-verity, can I now reboot to twrp and install via usb otg/internal?
    Our Apps
    Get our official app!
    The best way to access XDA on your phone
    Nav Gestures
    Add swipe gestures to any Android
    One Handed Mode
    Eases uses one hand with your phone