Question [SOLVED] Invalid sparse file format at header magic - Xiaomi Mi 11 Lite 5G

can someone help me, got this error when I flash GSI on fastbootD
C:\adb2>fastboot flash system sys.img
Invalid sparse file format at header magic
after the flash continue, I reboot on BL, wipe data, reboot and go directly on standard fastboot.....can't boot anymore on BL
I tried with PixelExperience_Plus_arm64-ab-vndklite-11.0-20210825-UNOFFICIAL.img
and also system-roar-arm64-ab-vndklite-floss.img
got same error and result
thanks

I have tested several gsi, from phh AOSP, CAOS and settled on LiR (most recent).
"Invalid sparse file format at header....."​happens always. But I had never any issues. Here my steps (always flashing from Linux Lappy):
1, Flashing MIUI stock (when coming from Xiaomi.eu e.g.)
2. reboot to bootloader
3. fastboot flash vbmeta vbmeta.img
4. ./fastboot reboot fastboot
5. fastboot flash system LiR....
6. reboot in stock recovery
7. wipe data
8. If not coming from MIUI, then I do fastboot -w, after flashing the image
Working always

ydd0ras said:
I have tested several gsi, from phh AOSP, CAOS and settled on LiR (most recent).
"Invalid sparse file format at header....."​happens always. But I had never any issues. Here my steps (always flashing from Linux Lappy):
1, Flashing MIUI stock (when coming from Xiaomi.eu e.g.)
2. reboot to bootloader
3. fastboot flash vbmeta vbmeta.img
4. ./fastboot reboot fastboot
5. fastboot flash system LiR....
6. reboot in stock recovery
7. wipe data
8. If not coming from MIUI, then I do fastboot -w, after flashing the image
Working always
Click to expand...
Click to collapse
thank's for your answer
1, I'm on stock eu and W10.. is miui stock different than eu??
2, where can I get vbmeta
5, where can I get Lir
or where can I get AOSP...or maybe it's for a different device..

You have to be on stock MIUI. Didn't worked here from Xiaomi.eu.
If you have Telegram look for phhtreble or gsi treble. You'll find all you need there. Can help you there.
I have an Mi 11 lite 5G as well
gr0ndpa

ginally got GSI flashed.....will do a tuto later...

@rayman95 oh please, can you share how you solved it? Stuck at the same spot right now ..

RootedLee said:
@rayman95 oh please, can you share how you solved it? Stuck at the same spot right now ..
Click to expand...
Click to collapse
hi, it seems that this issue can't be solved, I mean the error message, but if you wait the flash continue without error at the end but look here I made a tuto to bypass HERE

for me after error , boot only fastboot , after long set power buton its sleep and not react... please help?

Related

Huawei P20 Briked?

Hi there
I think my phone is briked. I wantet to downgrade my phone to the 108 version becaus there was android auto working.
So i tried to flash the System.img from the 108 Software. I tried 2 different:
http://pro-teammt.ru/firmware-database/?firmware_model=ANE-lx1&firmware_page=0
and the Middle east from the thread here.
Id did flash over fastboot, but after every start the Build number was still on the 112 Firmware.
So i tried the Trebel ASOP, RR and LOS. ASOP Booted but had only forceclose on every service. RR and LOS did not work.
Then i tried to flash the ramdisk, recovery, vendor kernel etc from the update.app from the 108 Firmware. No my phone is briked.
I tried to flash eveyrthing from the .112 updateapp from the Official thread but nothing happend.
Then i tried to flash every possible .img file from the .112 app but most of them gave "Error Command not allowed"
So here i Am. Bootlooping phone and i dont know what else to do.
Since the beginning i could flash every system.img but it still was on the 112 Build and suddenly it bricked. I cant get to the 112 Version back with flashing system.img because it bootloops. Same for Treble and the newest 126 Version or the old 108 Build.
The only thing booting is ASOP Treble but i cant navigate coz of the 1000 of forceclosed errors.
I formated the userpartition as i was asked from Huawei, and bevore i did those installations i did a fullwipe with EMUI.
The Recovery cant connect to the server, and yeah.. i dont know what to do next. ofc i have unlocked bootloader. I bought the Phone in Switzerland with Dual Sim. ANE-LX1.
Does anyone have another idea?
Cheers
EDIT:
After 10000 billions klicks i managed to get through the treble wizzard, even when the com.android.phone has stopped is comming every second.
At the Moment im in the About Phone Screen and i see this: (I am in the newest ASOP Treble SU with gapps)
Model: ANE-LX1
Android Version 8.1
Baseband: unknown
Kernel Version 4.4.23+ (gcc version 4.9x 20150123 (prerelease) (GCC))
Fri Mar 9 09:51:47 CST 2018
Build Number ANE-LX1 8.0.0.112(c432) <------- WTF ?!?
I hope this informations is something to work with.
SIM CARD is not readable.
Edit2:
I connected it to HI SUit. It says my device running properly on the .112 Version (WTF i got Treble installed)
I cant connect anything. How the hell can i get rid of this ****ing wong Build number??
Same for Checking Updates. .112 should be newest (its not its 126) Any ideas?
Edit3:
Can only Flash with fastboot. Twrp cant mount the partitions. Trying to installing the zip or adb sideload gives me an error code or command not allowed :\
i think the best way is
download a FULL-Update for your build
https://forum.xda-developers.com/9-lite/help/huawei-honor-firmware-download-t3790327
read this https://forum.xda-developers.com/hon...flash-t3778085
if you understand and have the know how : good luck
with this way i have my Ho9L reflash to stock-rom
you have to know what you're doing
use Magisk (search inside xda the thread)
this work by me better as SuperSU (with less problem's)
use this twrp, it's work WITH encryption
ttps://forum.xda-developers.com/huawei-p20-lite/development/recovery-testing-t3783587
if you understand what i am write - you can reset your phone to "delivered-state" and beginning by zero (initial-setting's) and
what ever you flash - you have a chance to reset your phone
first look on bootloader-screen if
- bootloader unlocked
- FRP unlock
THIS is essential !
last tip: let the fingers from custom-rom if this not expressly build for OREO
OREO is other as NOUGAT ! very different !
Relock your bootloader before trying an Erecovery...
please try this :
- download full update rom for your device, extract the .APP files using HuaweiUpdateExtractor
- boot into fastboot by press and hold Volume Down and plug in usb cable into your pc and your phone, hold it until it boot into fastboot
- do this :
fastboot flash kernel kernel.img
fastboot flash ramdisk ramdisk.img
fastboot flash recovery_ramdisk recovery_ramdis.img
fastboot flash recovery_vbmeta recovery_vbmeta.img
fastboot flash recovery_vendor recovery_vendor.img
fastboot flash system system.img
fastboot flash vbmeta vbmeta.img
fastboot flash vendor vendor.img
- reboot your device and hold Volume Up and Volume Down to get it boot into eRecovery and do Wipe Cache Partitions and then do Factory Data Reset, and reboot again
- let it boot normally, and see what happen next, i can't remember for sure because it's been so long i unbricked my Nova 2s with this method. there are 2 possibility, you'll boot into system normally, or it will boot into eRecovery again and there is an option Download Latest Version And Recovery and you can choose that, of course you should have connection to internet via wifi.
please report back if you have difficulties.
heindrix said:
please try this :
- download full update rom for your device, extract the .APP files using HuaweiUpdateExtractor
- boot into fastboot by press and hold Volume Down and plug in usb cable into your pc and your phone, hold it until it boot into fastboot
- do this :
fastboot flash kernel kernel.img
fastboot flash ramdisk ramdisk.img
fastboot flash recovery_ramdisk recovery_ramdis.img
fastboot flash recovery_vbmeta recovery_vbmeta.img
fastboot flash recovery_vendor recovery_vendor.img
fastboot flash system system.img
fastboot flash vbmeta vbmeta.img
fastboot flash vendor vendor.img
- reboot your device and hold Volume Up and Volume Down to get it boot into eRecovery and do Wipe Cache Partitions and then do Factory Data Reset, and reboot again
- let it boot normally, and see what happen next, i can't remember for sure because it's been so long i unbricked my Nova 2s with this method. there are 2 possibility, you'll boot into system normally, or it will boot into eRecovery again and there is an option Download Latest Version And Recovery and you can choose that, of course you should have connection to internet via wifi.
please report back if you have difficulties.
Click to expand...
Click to collapse
I'm getting this error when I'm trying to extract UPdate.app of anE-LX1 8.0.0.108(C185)
https://ibb.co/k0HmGy
haidermiz said:
I'm getting this error when I'm trying to extract UPdate.app of anE-LX1 8.0.0.108(C185)
https://ibb.co/k0HmGy
Click to expand...
Click to collapse
go to settings, untick all options that have "verify" in it, and try extract again.
heindrix said:
go to settings, untick all options that have "verify" in it, and try extract again.
Click to expand...
Click to collapse
thanks it worked
heindrix said:
please try this :
- download full update rom for your device, extract the .APP files using HuaweiUpdateExtractor
- boot into fastboot by press and hold Volume Down and plug in usb cable into your pc and your phone, hold it until it boot into fastboot
- do this :
fastboot flash kernel kernel.img
fastboot flash ramdisk ramdisk.img
fastboot flash recovery_ramdisk recovery_ramdis.img
fastboot flash recovery_vbmeta recovery_vbmeta.img
fastboot flash recovery_vendor recovery_vendor.img
fastboot flash system system.img
fastboot flash vbmeta vbmeta.img
fastboot flash vendor vendor.img
- reboot your device and hold Volume Up and Volume Down to get it boot into eRecovery and do Wipe Cache Partitions and then do Factory Data Reset, and reboot again
- let it boot normally, and see what happen next, i can't remember for sure because it's been so long i unbricked my Nova 2s with this method. there are 2 possibility, you'll boot into system normally, or it will boot into eRecovery again and there is an option Download Latest Version And Recovery and you can choose that, of course you should have connection to internet via wifi.
please report back if you have difficulties.
Click to expand...
Click to collapse
When i did fastboot flash vendor vendor.img it says
target reported max download size of 471859200 bytes
sending sparse 'vendor' 1/2 (460706 KB)...
OKAY [ 18.084s]
writing 'vendor' 1/2...
FAILED (remote: Command not allowed)
haidermiz said:
When i did fastboot flash vendor vendor.img it says
target reported max download size of 471859200 bytes
sending sparse 'vendor' 1/2 (460706 KB)...
OKAY [ 18.084s]
writing 'vendor' 1/2...
FAILED (remote: Command not allowed)
Click to expand...
Click to collapse
Hi there, if you have TWRP, you could flash system and vendor using TWRP. boot into TWRP, choose install, choose use image file, and flash system.img to system, and vendor.img to vendor.
heindrix said:
Hi there, if you have TWRP, you could flash system and vendor using TWRP. boot into TWRP, choose install, choose use image file, and flash system.img to system, and vendor.img to vendor.
Click to expand...
Click to collapse
Tried then phone was stuck at installing update 5% after 5 mins there was a screen android written on it then again it booted to erecovery i factory reset data, wiped cache then again it rebooted and it's finally open now thanks
heindrix said:
Hi there, if you have TWRP, you could flash system and vendor using TWRP. boot into TWRP, choose install, choose use image file, and flash system.img to system, and vendor.img to vendor.
Click to expand...
Click to collapse
I did that a installed stock rom after that I tired to reset data it said failed, it failed at 20% then I WIPED CHAHE and now when It opened I sign in and downloaded snapchat but it's noy opening and in settings about phone there's no model number mentioned it says unknown I don't know what to do
haidermiz said:
I did that a installed stock rom after that I tired to reset data it said failed, it failed at 20% then I WIPED CHAHE and now when It opened I sign in and downloaded snapchat but it's noy opening and in settings about phone there's no model number mentioned it says unknown I don't know what to do
Click to expand...
Click to collapse
if you could, please provide screenshot so i can see it more clearly.
after you flashing the rom, one thing you must do is to format the data and cache through emui erecovery, as long as you're not format the data and cache successfully, the rom will not works properly.
for another reference, please refer to my other post here : https://forum.xda-developers.com/ma...0-pro-help-t3776050/post76916307#post76916307
heindrix said:
if you could, please provide screenshot so i can see it more clearly.
after you flashing the rom, one thing you must do is to format the data and cache through emui erecovery, as long as you're not format the data and cache successfully, the rom will not works properly.
for another reference, please refer to my other post here : https://forum.xda-developers.com/ma...0-pro-help-t3776050/post76916307#post76916307
Click to expand...
Click to collapse
Greetings, I downloaded the rom of my Huawei p20 EML-L09 and it has two Update.app
How and in what order should I install them?
Udpate.app that weighs 4.62gb and
update_EML-L09_hw_la.app which weighs 1.5gb
Thanks a lot.
ajbn7 said:
Greetings, I downloaded the rom of my Huawei p20 EML-L09 and it has two Update.app
How and in what order should I install them?
Udpate.app that weighs 4.62gb and
update_EML-L09_hw_la.app which weighs 1.5gb
Thanks a lot.
Click to expand...
Click to collapse
Hi,
this guide is two years old, if you want to recover your phone, download Service ROM from androidhost.ru website, and flash it using dload method .
Which EMUI version are you running? Your region is C605 ?
-Alf- said:
Hi,
this guide is two years old, if you want to recover your phone, download Service ROM from androidhost.ru website, and flash it using dload method .
Which EMUI version are you running? Your region is C605 ?
Click to expand...
Click to collapse
Correct, my region is 605. I already downloaded the latest version available for download on that page which is 8.1.
Before my phone went into brick, it had version 9.1
And bring those two update.app
ajbn7 said:
Before my phone went into brick, it had version 9.1
Click to expand...
Click to collapse
For 9.1 you can download
https://androidhost.ru/2bCG
Unpack .zip archive , find dload file and simply transfer it to the SD card, without unpacking it! (instructions can be found in ReleaseDoc folder).
Turn off your phone and flash FW using three button combo.
Note: Service ROM L-29 contains both version - L-29 & L-09 .
-Alf- said:
For 9.1 you can download
https://androidhost.ru/2bCG
Unpack .zip archive , find dload file and simply transfer it to the SD card, without unpacking it! (instructions can be found in ReleaseDoc folder).
Turn off your phone and flash FW using three button combo.
Note: Service ROM L-29 contains both version - L-29 & L-09 .
Click to expand...
Click to collapse
I struggled so hard to download the file, and to my surprise it does not include the software version for the L-09, only for the L-29
Are there any risks if I try to install version 8.1?
Another thing, the Huawei p20 does not have a micro sd slot, I guess I should do it through a USB OTG?
ajbn7 said:
I struggled so hard to download the file, and to my surprise it does not include the software version for the L-09, only for the L-29
Click to expand...
Click to collapse
Are you sure?
I'm really sorry, but most of the packages are universal.
ajbn7 said:
Are there any risks if I try to install version 8.1?
Click to expand...
Click to collapse
It may brick your phone definitively.
ajbn7 said:
Another thing, the Huawei p20 does not have a micro sd slot, I guess I should do it through a USB OTG?
Click to expand...
Click to collapse
Yes, you can.
ajbn7 said:
I struggled so hard to download the file, and to my surprise it does not include the software version for the L-09, only for the L-29
Are there any risks if I try to install version 8.1?
Another thing, the Huawei p20 does not have a micro sd slot, I guess I should do it through a USB OTG?
Click to expand...
Click to collapse
Okay, I definitely don't get the 9.1 for Eml-09 for free.
So last query (I hope), what is less risky, install Rom 8.1 which is for my region and exact model, or install Rom 9.1 with my region but for model L-29 or install a Rom 9.1 for my model but with a different region?
Thank you for your support.
ajbn7 said:
what is less risky?
Click to expand...
Click to collapse
L29 EMUI 9.1 C605. Even if it succeeds the phone will not work correctly.
Most probably you will get the wrong model or in build number "system_0.46 (xxxx)" . HiSuite will not recognize your device (and no OTA update).

Facing System Partition not found when flash OOS rom or GSI rom via fastboot

Hi, I'm trying to flash OOS rom on my phone, Curtana. But I got an error when flash it.
The Terminal facing System: (REMOTE: Partition not found).
And I'm stuck at fastboot, can't not boot system or to recovery.
Thanks for your help.
nhokloz105 said:
Hi, I'm trying to flash OOS rom on my phone, Curtana. But I got an error when flash it.
The Terminal facing System: (REMOTE: Partition not found).
And I'm stuck at fastboot, can't not boot system or to recovery.
Thanks for your help.
Click to expand...
Click to collapse
OOS ?!?!? is there OxygenOS for curtana?
where did you get it?
can i have a link or adress please...
javidman said:
OOS ?!?!? is there OxygenOS for curtana?
where did you get it?
can i have a link or adress please...
Click to expand...
Click to collapse
You can get here https://t.me/curtanacloud/472
I have found a solution. I flashed stock rom via MiFlash to have fastbootd (not fastboot). Then reboot to Bootloader and type 'fastboot reboot fastboot' to boot to fastbootd. Then I can flash any system.img I want.
Another method, but I've try yet.
1. Unlock bootloader
2. Flash LOS recovery
3. Boot bootloader
In CMD
4. Enter: 'fastboot reboot fastboot'
5. Then you will see 'fastbootd', enter 'fastboot flash system system.img' (system.img = gsi img)
6. enter 'fastboot reboot recovery'
In recovery
7. go to factory reset
8. select format data/factory reset then format data
9. then select reboot system

TWRP on DOOGEE N20PRO

Hi all
i want to install TWRP on my Doogee N20PRO . i cannot find a TWRP File on the internet to install. I could find some for the N20 but not for the N20PRO. it´s an Helios P60 Processor with an MTK6771. I tried to install the HAVOC 3.7 but i get the Message "writing 1/15 failed (remote: this partition doesn´t exist)
beinfo said:
Hi all
i want to install TWRP on my Doogee N20PRO . i cannot find a TWRP File on the internet to install. I could find some for the N20 but not for the N20PRO. it´s an Helios P60 Processor with an MTK6771. I tried to install the HAVOC 3.7 but i get the Message "writing 1/15 failed (remote: this partition doesn´t exist)
Click to expand...
Click to collapse
This is simple about TWRP: Your phone have МТК Helio Р60 MT6771V/CA WITH Android 10.0 and it's a NEW phone now. So no developments yet.
For install GSI ROMs your need unlock bootloader and after follow the correct instructions to new phones shipped with A10!
If you only want install GSI so I suggest:
1- Have stock ROM first, always!!;
2- With security 1- you should unlock bootloader;
3- You can install GSI with stock recovery without problems.
The only part is: you cannot backup userdata.....
DragonPitbull said:
This is simple about TWRP: Your phone have МТК Helio Р60 MT6771V/CA WITH Android 10.0 and it's a NEW phone now. So no developments yet.
For install GSI ROMs your need unlock bootloader and after follow the correct instructions to new phones shipped with A10!
If you only want install GSI so I suggest:
1- Have stock ROM first, always!!;
2- With security 1- you should unlock bootloader;
3- You can install GSI with stock recovery without problems.
The only part is: you cannot backup userdata.....
Click to expand...
Click to collapse
Cool This helps already a lot.
i unlocked the Bootloader properly, but then i got a partition error. I assume i´ve an error in the command line. The phone was anyway only an interim solution till my POco F2 was back from repair. now i use it as a playground.
fastboot erase system - there i get a partition error.
erasing the User data was sucessful
but then
fastboot flash system system.img it stops at step 1/15 again for the partition error (partition doesn´t exist) Stock rom is available.
somebody knows the options i´ve to add to the command line?
beinfo said:
The phone was anyway only an interim solution till my POco F2 was back from repair. now i use it as a playground.
fastboot erase system - there i get a partition error.
erasing the User data was sucessful
but then
fastboot flash system system.img it stops at step 1/15 again for the partition error (partition doesn´t exist) Stock rom is available.
somebody knows the options i´ve to add to the command line?
Click to expand...
Click to collapse
Try but REMENBER I am not responsible for any errors. Bootloader should unlocked by adb-fastboot!!
Spoiler: Instructions
1. You need know the difference about fastboot and FASTBOOTD in your device!!
Your device has bootloader mode: recovery - fastboot - reboot (system)
Stock recovery has very options: reboot system - reboot to bootloader - wipe - Enter fastboot - ...
reboot to bootloader => normal fastboot
Enter fastboot => FASTBOOTD
FASTBOOTD => some options
2. Device in fastboot
Code:
fastboot --disable-verification flash vbmeta vbmeta.img
vbmeta file from stock ROM or pulled from device
3.
Code:
fastboot -w
4.
Code:
fastboot reboot fastboot
(you MUST be at the FASTBOOTD menu now. If not, you will not be able to flash the GSI successfully)
5.
Code:
fastboot erase system
or
Code:
fastboot delete-logical-partition system
6.
Code:
fastboot delete-logical-partition product
- deletes the product partition, allowing a larger system partition
I not need resize-logical-partition product. But if you want:
You will need a larger system partition to flash a GSI. There are 2 ways to achieve this
6A. fastboot resize-logical-partition product 509344768
6B. fastboot resize-logical-partition system 3089272064 or 3889272064
resizes product and system partitions. This gives you about 3GB of system partitions. You can adjust or arrive at your own numbers if you want different sizes.
7.
Code:
fastboot --disable-verity --disable-verification flash system GSI.img
8.
Code:
fastboot -w
for confirm great & fast start GSI
9.
Code:
fastboot reboot bootloader
9A.
Code:
fastboot erase userdata
for confirm and boot clean
10. Reboot to system
Code:
fastboot reboot
Enjoy
I also have an N20 Pro which I received Dec 2020. Had some trouble setting it up. I got the OEM ROM from Doogee customer support and was able to extract the boot image and patch it with Magisk. I then burned it with the SP Flash tool. It wouldn't boot until I burned a special vbmeta.img to turn off encryption. Now it's working fine.
Sorry this doesn't help you with TWRP but I think most people looking for TWRP are really looking to root their phone.
beinfo said:
Hi all
i want to install TWRP on my Doogee N20PRO . i cannot find a TWRP File on the internet to install. I could find some for the N20 but not for the N20PRO. it´s an Helios P60 Processor with an MTK6771. I tried to install the HAVOC 3.7 but i get the Message "writing 1/15 failed (remote: this partition doesn´t exist)
Click to expand...
Click to collapse
Okay so what ive seen is that you should avoid flashing custom roms via adb fastboot especially with our doogee phones, and also there are many incompatiable roms so what you will need is to unlock bootloader and do the whole twrp install thing adn also install magisk
before hand install treble info from google playstore and take down the information "arm64 a/b" and search for roms with that information to install custom os/rom/gsi properly. GSI versions are more preferred if your phone supports treblle
if your twrp keeps getting wiped after reboot open file :mount your system and connect to pc via usbcable (mtp if not showing disable mtp and re- enable it )
now got to where build.prop is saved there will be a file called recovery from boot.p , copy the file to pc , open with notepad, remove everything , save and copy back to phone (overwrite)
then go ahead and install magisk
make sure your magisk is working install edxposed, riru core , and busybox ndk get the apps you need for them (edxposed manager...) and then instal and activate a module which you can test if its working(if framework is active in edxposed manager and the module working correctly then you can go ahead and
Install custom os through twrp
follow these instructions ( https://forum.xda-developers.com/t/...lexperience-10-gsi-android-10-stable.4081685/ ) with your custom rom (corvus, havoc, lineage...
(the g-apps didnt flash for me (error code 64) but i just rebooted and everything was working fine (including gapps but camera sucked (doogee's rear camera setup was just terrible))
https://forum.xda-developers.com/t/...lexperience-10-gsi-android-10-stable.4081685/
** i can confirm follow instructions properly and it should work (i used this pixel experience on my doogee n20 make sure you unzip the .xz file and youre flashing a .img file
**also make sure its the gsi file (

Question Unable to mount storage when trying to ADB sideload

I can't install any rom, ADB sideload fails with this error:
Unable to mount storage.
Devices on super may not mount until rebooting recovery.
To flash additional zips, please reboot recovery to switch to the updated slot.
I already tried to switch the slots many times.
I also tried to format data, but it tells me:
E: unable to check merge status
Updating partition details...
...done
Unable to mount storage
I can access the recovery and the factory-reset android, but i can't do anything more.
I think the problem is relative to encryption but I can't even format data, so I don't know how to escape this...
Now I can't even access the rom, I can only access TWRP and fastboot. The problem is that format data does not work, with the same error:
E: unable to check merge status
I tried repairing and changing filesystem, now I don't really know what to do...
just install rom using fast boot tool and
format data after that
muneeb rizwan said:
just install rom using fast boot tool and
format data after that
Click to expand...
Click to collapse
I have never used fastboot tool. I'm on linux. Is this the program i must install?
And also, do I need a fastboot rom?
[Tool] Flash Custom ROMs through Fastboot [mojito / sunny]
Are you struggling to install custom roms on this device? Lots of recovery errors? Can't boot to any rom? Don't worry. Fastboot is a good way to avoid such nonsense... Install any custom rom & miui recovery rom through fastboot Steps: 1...
forum.xda-developers.com
USE THIS TOOL AND YOU DONT NEED FASTBOOT ROM
Ok, i installed CrDroid with fastboot tool, then format data and then re-flashed the rom with adb, but the phone starts just on the CrDroid recovery (slot b) or on fastboot (slot a)...
What is the correct process to install a ROM? This A/B thing gets me mad
Now I managed to install an old MIUI fastboot rom from this link with XiaomiADBFastbootTools (a kind of mi flash tool for linux) and this rom now it is working, so I think I had some problems with the fastboot tool you suggested. But I don't really know what was the problem, the installation process seemed to work, It restarted to recovery, I rebooted to system but then it kept returning to recovery or to fastboot without entering in the system...
Switching slots directly in recovery is not functional. Just look after switching what the active slot is and you will see that it has not changed. Do the slot switching with the fastboot command from the PC.
fastboot --set-active=a
fastboot --set-active=b
StaryMuz said:
Switching slots directly in recovery is not functional. Just look after switching what the active slot is and you will see that it has not changed. Do the slot switching with the fastboot command from the PC.
fastboot --set-active=a
fastboot --set-active=b
Click to expand...
Click to collapse
yes, I was using these commands to switch slots. but when it is necessary to switch slots in the flashing process? I mean, what is the correct order? format - flash rom with adb - reboot to fastboot - switch slot - reboot to system...is this correct?
Slot swapping may not be required. Do it only when it is requested or when the boot crashes into recovery.
StaryMuz said:
Slot swapping may not be required. Do it only when it is requested or when the boot crashes into recovery.
Click to expand...
Click to collapse
OK, so is this the correct order?
Format - flash rom with adb - reboot to system
Now I have a problem with fastboot...I don't know why but it can't boot any recovery...
"fastboot boot recovery.img" remains stuck at:
Sending 'boot.img' (131072 KB)
Click to expand...
Click to collapse
and nothing happens! I tried with TWRP and OrangeFox.
I also tried to change slot but it fails:
fastboot --set-active=a
Setting current slot to 'a' FAILED (remote: 'unknown command')
fastboot: error: Command failed
Click to expand...
Click to collapse
The command 'Fastboot reboot' gives me a black screen with a white message: 'any key to shutdown', then the phone reboots to system...
What is the full designation of your phone?
StaryMuz said:
What is the full designation of your phone?
Click to expand...
Click to collapse
what is the designation?
Xiaomi Redmi Note .....
All of it, exactly.
StaryMuz said:
Xiaomi Redmi Note .....
All of it, exactly.
Click to expand...
Click to collapse
Redmi Note 10 64GB/4GB, I think the codename is sunny because I have the global/european version. Do you need more?
I think the best step is to upload the original Miui using MiFlash with the "clear all" setting.
Use this version of MiFlash.
You can get the right Miui here.
Before using MiFlash, I recommend loading the boot.img included in the downloaded Miui into your phone in fastboot mode.
Use the command:
fastboot flash boot_a boot.img
fastboot flash boot_b boot.img
Then use MiFlash and don't play Miui. Wait until the phone starts itself, then you can disconnect it.
If anything is not clear, ask questions.
StaryMuz said:
I think the best step is to upload the original Miui using MiFlash with the "clear all" setting.
Use this version of MiFlash.
You can get the right Miui here.
Before using MiFlash, I recommend loading the boot.img included in the downloaded Miui into your phone in fastboot mode.
Use the command:
fastboot flash boot_a boot.img
fastboot flash boot_b boot.img
Then use MiFlash and don't play Miui. Wait until the phone starts itself, then you can disconnect it.
If anything is not clear, ask questions.
Click to expand...
Click to collapse
Actually I'm already in a original MIUI and it is working. My pc is on linux so I can't use MiFlash but I used XiaomiADBFastbootTools (a kind of MiFlash tool for linux). Can I start from here or I have to install the MIUI version you linked?
The only thing is that I didn't specifically load the boot.img
Unfortunately I don't know the Linux version of MiFlash. They may not work equivalently. It needs to properly clean all the partitions of the phone and load all the files supplied in the ROM.
I recommend to use the Miui listed by me.

Official LineageOS for Redmi 9

There is official release of LineageOS 20 for Redmi 9:
Info about lancelot | LineageOS Wiki
wiki.lineageos.org
Pity, no support on XDA.
I have installed and tested a bit. Install sequence was like that:
- Flash MIUI 12 A11 with MiFlash. I have used EEA version, but maybe last global A11 would be more safe.
- Insert SD card with all software needed (Lineageos, gapps, lygisk).
- Go to fastboot and flash Lineageos recovery. Then immediately go to recovery by pressing volume up + power.
- In recovery do factory reset, format data.
- Flash Lineageos from SD (apply update in recovery).
- Flash MindTheGapps from SD.
- Reboot.
You can flash form adb instead of SD, but I haven't tried it.
If you want to pass SafetyNet, flash Lygisk and install Universal Safetynet Fix. Magisk should work too, but it wont survive OTA with Lineageos recovery.
This is not my main phone, so I haven't tested much. System looks and works OK, no obvious problems. Some WiFi channels on 5GHz are missing, like on others custom ROMs.
Bootloop with recent update.
Thanks for the pointer. I tried it and finally got LineageOS working on my Redmi 9 that had MIUI 13 (bootloader unlocked) already.
Here are the steps I did:
Download twrp-3.4.2_A12-lancelot-dimenzino.img from https://sourceforge.net/projects/recovery-for-xiaomi-devices/files/lancelot
Download miui_LANCELOTEEAGlobal_V13.0.3.0.SJCEUXM_f7755ce0ba_12.0.zip (or similar, should be the version currently on your phone) from https://xiaomirom.com/en/rom/redmi-9-lancelot-europe-fastboot-recovery-rom/.
Open miui_LANCELOTEEAGlobal..., extract vbmeta.img and rename it to vbmeta-miui.img.
Open https://download.lineageos.org/devices/lancelot, download
lineage-20.0-20230322-nightly-lancelot-signed.zip and vbmeta.img and recovery.img from the same build. Rename the latter two to vbmeta-lineage.img and recovery-lineage.img).
Download MindTheGapps-13.0.0-arm64-20221025_100653.zip from https://androidfilehost.com/?fid=14871746926876840643
Copy these files to your SD card:
- lineage-...-signed.zip
- MindTheGapps....zip
- miui_LANCELOT..._12.0.zip
Now:
1) Boot into fastboot. "FASTBOOT" in orange letters must be on screen.
2) fastboot --disable-verity --disable-verification flash vbmeta vbmeta-miui.img
3) fastboot flash recovery twrp-3.4.2_A12-lancelot-dimenzino.img
boot into recovery
4) fastboot reboot recovery
(TWRP comes up)
5) In TWRP, do wipe/factory reset.
6) In TWPR, install miui_LANCELOT..._12.0.zip, then reboot.
(MIUI logo comes up for a few mintues, then MIUI 12.5 starts)
7) In MIUI, power off phone
8) Boot into fastboot. "FASTBOOT" in orange letters must be on screen.
9) fastboot --disable-verity --disable-verification flash vbmeta vbmeta-lineage.img
10) fastboot --disable-verity --disable-verification flash recovery recovery-lineage.img
11) fastboot reboot recovery
(LineageOS recovery comes up)
12) In LOS recovery, install lineage-...-signed.zip and MindTheGapps....zip. Then reboot to system. It asks whether to erase data. Answer yes.
13) LineageOS boots. Yay!
IMEIs etc are all preserved.
Experience after one day on my Redmi 9 EEA (3/32GB):
LineageOS 20 runs much better than MIUI 13. It boots much quicker, it is more responsive, more apps can stay in RAM.
Finally, I get notifications reliably when someone sends me a mail or Whatsapp msg.
Downsides:
- status bar cannot show transfer speed (not supported)
- system settings (pull downwards from top of screen) aren't as nice. Only 4 buttons visible as buttons are really big. Have to pull down twice to change screen brightness.
- Update: camera cannot record 1080p video properly. 720p works.
I was able to install it correctly by following the official lineage tutorial that can be found at the following link: https://wiki.lineageos.org/devices/lancelot/install
I hope it helps you
Hi everybody,
after upgrading to lineage-20.0-20230405-nightly-lancelot-signed.zip google services crash. (mindthegapps 2023-03-23)
When downgrading to lineage-20.0-20230329-nightly-lancelot-signed.zip everything works fine again.
Karl-D said:
Hi everybody,
after upgrading to lineage-20.0-20230405-nightly-lancelot-signed.zip google services crash. (mindthegapps 2023-03-23)
When downgrading to lineage-20.0-20230329-nightly-lancelot-signed.zip everything works fine again.
Click to expand...
Click to collapse
The same thing happened to me when installing the gapps (in this case, litegapps) did not start the system and entered a type of bootloop. I better leave lineage and install bananadroid and I'm doing great.
On version 22-Mar-2023 Nightly.
After turning on Wi-Fi Calling for either of my SIM cards, I get the error:
com.mediatek.ims.ImsApp keeps stopping
and then after that, Wi-Fi Calling options disappear from SIM card settings.
Any ideas of things to try?
Can't install lineageOS 20, tried almost everything
I install miui 13 (android 12), dimensino a12 twrp (it only works with android 12), but there's no way to start lineageos recovery
any suggestions?
tenssa said:
Can't install lineageOS 20, tried almost everything
I install miui 13 (android 12), dimensino a12 twrp (it only works with android 12), but there's no way to start lineageos recovery
any suggestions?
Click to expand...
Click to collapse
See my post above (Saturday at 10:51 AM) how I went from MIUI 13 to LineageOS 20.
First fastboot flash dimenzino TWRP, using that flash MIUI 12.5, from MIUI 12.5 fastboot you can install LineageOS 20 recovery, and using that LineageOS 20.
hvdh said:
Thanks for the pointer. I tried it and finally got LineageOS working on my Redmi 9 that had MIUI 13 (bootloader unlocked) already.
Here are the steps I did:
Download twrp-3.4.2_A12-lancelot-dimenzino.img from https://sourceforge.net/projects/recovery-for-xiaomi-devices/files/lancelot
Download miui_LANCELOTEEAGlobal_V13.0.3.0.SJCEUXM_f7755ce0ba_12.0.zip (or similar, should be the version currently on your phone) from https://xiaomirom.com/en/rom/redmi-9-lancelot-europe-fastboot-recovery-rom/.
Open miui_LANCELOTEEAGlobal..., extract vbmeta.img and rename it to vbmeta-miui.img.
Open https://download.lineageos.org/devices/lancelot, download
lineage-20.0-20230322-nightly-lancelot-signed.zip and vbmeta.img and recovery.img from the same build. Rename the latter two to vbmeta-lineage.img and recovery-lineage.img).
Download MindTheGapps-13.0.0-arm64-20221025_100653.zip from https://androidfilehost.com/?fid=14871746926876840643
Copy these files to your SD card:
- lineage-...-signed.zip
- MindTheGapps....zip
- miui_LANCELOT..._12.0.zip
Now:
1) Boot into fastboot. "FASTBOOT" in orange letters must be on screen.
2) fastboot --disable-verity --disable-verification flash vbmeta vbmeta-miui.img
3) fastboot twrp-3.4.2_A12-lancelot-dimenzino.img
boot into recovery
4) fastboot reboot recovery
(TWRP comes up)
5) In TWRP, do wipe/factory reset.
6) In TWPR, install miui_LANCELOT..._12.0.zip, then reboot.
(MIUI logo comes up for a few mintues, then MIUI 12.5 starts)
7) In MIUI, power off phone
8) Boot into fastboot. "FASTBOOT" in orange letters must be on screen.
9) fastboot --disable-verity --disable-verification flash vbmeta vbmeta-lineage.img
10) fastboot --disable-verity --disable-verification flash recovery recovery-lineage.img
11) fastboot reboot recovery
(LineageOS recovery comes up)
12) In LOS recovery, install lineage-...-signed.zip and MindTheGapps....zip. Then reboot to system. It asks whether to erase data. Answer yes.
13) LineageOS boots. Yay!
IMEIs etc are all preserved.
Click to expand...
Click to collapse
I tried your method but failed. First --disable-verity was not recognized by fastboot and then miui_LANCELOTEEAGlobal_V13.0.1.0.SJCEUXM_64ecf18c80_12.0.zip did not installed - got error. Is it possible to flash LOS directly using recovery twrp-3.4.2_A12-lancelot-dimenzino.img?
bokel said:
I tried your method but failed. First --disable-verity was not recognized by fastboot and then miui_LANCELOTEEAGlobal_V13.0.1.0.SJCEUXM_64ecf18c80_12.0.zip did not installed - got error. Is it possible to flash LOS directly using recovery twrp-3.4.2_A12-lancelot-dimenzino.img?
Click to expand...
Click to collapse
Is your bootloader unlocked?
Did you disable PIN/fingerprint/pattern lock? (Not sure it is required, but some say to do that and I did it)
Was "FASTBOOT" on screen orange or blue (must be orange)?
Is you PC fastboot somewhat recent (mine is from Android SDK platform tools 29.0.6)?
Can you paste you fastboot cmdline and output here?
"Is it possible to flash LOS directly using recovery twrp-3.4.2_A12-lancelot-dimenzino.img?"
No, I tried that. LOS does not boot then. It needs the boot process (not sure which partitions) from MIUI 12. The one from MIUI 13 does not work.
hvdh said:
Is your bootloader unlocked? - Yes
Did you disable PIN/fingerprint/pattern lock? (Not sure it is required, but some say to do that and I did it) - yes
Was "FASTBOOT" on screen orange or blue (must be orange)? - orange
Is you PC fastboot somewhat recent (mine is from Android SDK platform tools 29.0.6)? android-tools-33.0.3-3
Can you paste you fastboot cmdline and output here?
Click to expand...
Click to collapse
[[email protected] Redmi9]$ fastboot --disable-verity --disable-verification flash vbmeta vbmeta-miui.img
Rewriting vbmeta struct at offset: 0
Sending 'vbmeta' (4 KB) OKAY [ 0.011s]
Writing 'vbmeta' OKAY [ 0.002s]
Finished. Total time: 0.015s
[[email protected] Redmi9]$ fastboot flash recovery twrp-3.4.2_A12-lancelot-dimenzino.img
Sending 'recovery' (65536 KB) OKAY [ 2.502s]
Writing 'recovery' OKAY [ 0.910s]
Finished. Total time: 3.415s
[[email protected] Redmi9]$
hvdh said:
"Is it possible to flash LOS directly using recovery twrp-3.4.2_A12-lancelot-dimenzino.img?"
No, I tried that. LOS does not boot then. It needs the boot process (not sure which partitions) from MIUI 12. The one from MIUI 13 does not work.
Click to expand...
Click to collapse
bokel said:
[[email protected] Redmi9]$ fastboot --disable-verity --disable-verification flash vbmeta vbmeta-miui.img
Rewriting vbmeta struct at offset: 0
hvdh said:
Thanks for the pointer. I tried it and finally got LineageOS working on my Redmi 9 that had MIUI 13 (bootloader unlocked) already.
Here are the steps I did:
Download twrp-3.4.2_A12-lancelot-dimenzino.img from https://sourceforge.net/projects/recovery-for-xiaomi-devices/files/lancelot
Download miui_LANCELOTEEAGlobal_V13.0.3.0.SJCEUXM_f7755ce0ba_12.0.zip (or similar, should be the version currently on your phone) from https://xiaomirom.com/en/rom/redmi-9-lancelot-europe-fastboot-recovery-rom/.
Click to expand...
Click to collapse
Click to expand...
Click to collapse
this recovery file is for MUI 13 not MUI 12.5, maybe I should try with miui_LANCELOTGlobal_V12.5.6.0.RJCMIXM_725b167c13_11.0.zip
Download Redmi 9 / 9 Prime (lancelot) V12.5.6.0.RJCMIXM MIUI 12.5 Stable Full Rom | XiaomiROM.com
The Stable update V12.5.6.0.RJCMIXM has been officially released for Redmi 9 / 9 Prime (codename is lancelot). Before updating, please make sure you …
xiaomirom.com
bokel said:
hvdh said:
Open miui_LANCELOTEEAGlobal..., extract vbmeta.img and rename it to vbmeta-miui.img.
Open https://download.lineageos.org/devices/lancelot, download
lineage-20.0-20230322-nightly-lancelot-signed.zip and vbmeta.img and recovery.img from the same build. Rename the latter two to vbmeta-lineage.img and recovery-lineage.img).
Download MindTheGapps-13.0.0-arm64-20221025_100653.zip from https://androidfilehost.com/?fid=14871746926876840643
Copy these files to your SD card:
- lineage-...-signed.zip
- MindTheGapps....zip
- miui_LANCELOT..._12.0.zip
Now:
1) Boot into fastboot. "FASTBOOT" in orange letters must be on screen.
2) fastboot --disable-verity --disable-verification flash vbmeta vbmeta-miui.img
3) fastboot twrp-3.4.2_A12-lancelot-dimenzino.img
boot into recovery
4) fastboot reboot recovery
(TWRP comes up)
5) In TWRP, do wipe/factory reset.
6) In TWPR, install miui_LANCELOT..._12.0.zip, then reboot.
(MIUI logo comes up for a few mintues, then MIUI 12.5 starts)
Click to expand...
Click to collapse
Click to expand...
Click to collapse
MIUI 13 starts again, not 12.5
bokel said:
hvdh said:
7) In MIUI, power off phone
8) Boot into fastboot. "FASTBOOT" in orange letters must be on screen.
9) fastboot --disable-verity --disable-verification flash vbmeta vbmeta-lineage.img
10) fastboot --disable-verity --disable-verification flash recovery recovery-lineage.img
11) fastboot reboot recovery
(LineageOS recovery comes up)
12) In LOS recovery, install lineage-...-signed.zip and MindTheGapps....zip. Then reboot to system. It asks whether to erase data. Answer yes.
13) LineageOS boots. Yay!
IMEIs etc are all preserved.
Click to expand...
Click to collapse
Sending 'vbmeta' (4 KB) OKAY [ 0.011s]
Writing 'vbmeta' OKAY [ 0.002s]
Finished. Total time: 0.015s
[[email protected] Redmi9]$ fastboot flash recovery twrp-3.4.2_A12-lancelot-dimenzino.img
Sending 'recovery' (65536 KB) OKAY [ 2.502s]
Writing 'recovery' OKAY [ 0.910s]
Finished. Total time: 3.415s
[[email protected] Redmi9]$
Click to expand...
Click to collapse
It worked up until final reboot, LOS recovery didn't start
I did it finally. I had to downgrade from Miui 13 to Miui 12.5 first using Miflash https://xiaomirom.com/en/download-xiaomi-flash-tool-miflash/ with fastboot rom https://xiaomirom.com/en/download/redmi-9-9-prime-lancelot-stable-V12.5.6.0.RJCMIXM/. At the end it gave an error because the phone was unlocked. But it was OK. After that just followed the LOS installation guide and it worked flawlessly.
bokel said:
I did it finally. I had to downgrade from Miui 13 to Miui 12.5 first using Miflash https://xiaomirom.com/en/download-xiaomi-flash-tool-miflash/ with fastboot rom https://xiaomirom.com/en/download/redmi-9-9-prime-lancelot-stable-V12.5.6.0.RJCMIXM/. At the end it gave an error because the phone was unlocked. But it was OK. After that just followed the LOS installation guide and it worked flawlessly.
Click to expand...
Click to collapse
Glad to hear that. I was out of ideas why my sequence did not work.
hvdh said:
Glad to hear that. I was out of ideas why my sequence did not work.
Click to expand...
Click to collapse
Could it be because you are using the same Miui 13, have you tried same sequence with with Miui 12.5? LOS won't boot into recovery with android 12. Anyways, the phone now works amazingly and I bought it only for 80$ like a new. Big thanks to all the people doing this great job with LOS and people like yourself! I am so happy!
bokel said:
Could it be because you are using the same Miui 13, have you tried same sequence with with Miui 12.5? LOS won't boot into recovery with android 12. Anyways, the phone now works amazingly and I bought it only for 80$ like a new. Big thanks to all the people doing this great job with LOS and people like yourself! I am so happy!
Click to expand...
Click to collapse
I had MIUI 13 installed, but reverted to 12.5 using dimenzino TWRP. I also booted MIUI 12.5 once in case it initializes somthing on first boot.
hvdh said:
See my post above (Saturday at 10:51 AM) how I went from MIUI 13 to LineageOS 20.
First fastboot flash dimenzino TWRP, using that flash MIUI 12.5, from MIUI 12.5 fastboot you can install LineageOS 20 recovery, and using that LineageOS 20.
Click to expand...
Click to collapse
Tried it twice, everything went fine during installation, but after reboot it won't go into (lineage) recovery (this is MIUI 13, android 12).
When i downgraded to MIUI 12.5 (android 11), lineageOS recovery works, but after installation there's bootloop.
I'll try during next week some other tricks, if i catch some free time.
Anyone tried to flash LOS with other twrp on android 11? With orange recovery or similar?

Categories

Resources