Error 7 issue after android Q - Xiaomi Mi 9 Questions & Answers

hello
It's been a while since I wrote anything on XDA, so please be gentle
Let's get the ball rolling.
I have been using MI9 since launch. I bought mine directly at the store in Shanghai, and brought it with me to Europe. After 2 weeks i unlocked the bootloader, and was able to flash TWRP + xiaomi.eu ROM (current beta at that time).
For a couple of months I received OTA updates (all firty flashes), up until introduction of beta android Q (miui 11).
I downloaded the ROM, and flashed, everything worked fine. after some time I had an issue with google pay, so thought of reverting to android Q. I checked, and dirty flash was not recommended option, so I prepared Android P ROM (not sure if exact version is relevant), booted to TWRP (3.3.1.42), wiped the data and tried to flash the ROM (from USB OTG).
Sadly - received error 7, some info about system partition.
I tried reflashing android Q - only to receive the same error.
Stuck at TWRP or fastboot, I used miflash and returned to a global stable.
then I reflashed twrp hoping to remove the error, but had the same error while flashing. Tried to flash from both internal memory, and usb OTG.
returned with miflash to stable, to use the phone..
bootloader is still unlocked, I can flash twrp again, but it will be wiped once I restart the system (as global roms "reflash" recoveries when they boot up).
I looked on some guides how to deal with error 7, but most of them aren't applicable (removing asses lines from config files, as there is no assess line in the ROMs).
Perhaps I am missing some files that I should flash, such as "vendor" files, or something ?
I thought that miflash restores fully to factory state, so TWRP shouldn'[t give any more errors.

There might be something wrong about either the rom, or the twrp.
> Since error 7 is the updater script checking for the phone model, it's either a bad script, or you missed an asserts file when flashing with MiFlash, as even the "factory" roms might not contain all partitions.
> Some partitions can't be seen by Mauronofrio's TWRP, but that shouldn't be a problem tho...
- Try using TWRP 3.3.1-1001 by a chinese team
- Try using the latest 10.10.2019 MIUI11 Rom from xiaomi.eu, I'm using in on an EEA phone and quite satisfied with it

Related

P9 Unable to get into TWRP due to flashing a different ROM

So I installed a version of the P9 OS EVAL09 from here - https://forum.xda-developers.com/p9/development/bluewei-test-crossflash-to-l09-c432-t3608270 the B387 version.
Prior to this, I was running unofficial CM 13 with TWRP installed, and it worked mostly fine.
The B387 .zip had a .update log which I was supposed to install via SDcard upgrade or something like that, however instead I removed a few lines from the update binary and installed via TWRP (in hindsight, probably what caused this problem).
Since then, I have launched into the new ROM with the purpose of updating, then moving to the unofficial Lineage OS.
However, I have encountered the biggest problem which is that, when I tried to reaccess TWRP it would automatically redirect to Huawei eRecovery, which does not allow me to reset/upgrade (as it says package info isn't correct).
I then tried to redo the process of flashing TWRP via ADB fastboot, and then it says that writing recovery has failed.
I can't download the stock ROM from huawei hicloud from the thread here - https://forum.xda-developers.com/p9/development/rom-stock-rom-eva-l19c636b168-t3419586 - as it always says the website is unavailable.
So far, the current OS installed is unusable, and I do not have any custom recovery software. If I can get TWRP to work again, then I should be ok as I made backups before.
edit 2018-01-18: The fix is to make the dload folder in the sd card and hard flash the ROM, which will get me back to a working stable version.

(flashing / booting) Problems with all roms

Hi,
since many days I have a new Mi8.
The device is a chineese model, and because it was delivered with unlocked bootloader and a shop ROM, i want to use the latest Xiaomi.eu stable rom.
After flashing the TWRP, i cleared all (System, Data, Cache, internal storage) and installes the latest xiaomi.eu ROM.
Unfortunately the ROM was notstartet. Later i readed, that the xiaomi.eu ROM needs the system partition, so i tried to install some different ROMs.
All tested roms failed to install (device missmatch), so i tried to use different recoveries and at least i updated the vendor Image to MI8Global_V10.3.5.0.PEAMIXM.
After this, some Roms are able to install, mut the ROMs wont boot.
After a clean install of the xiomi global fastboot image, the phone is running, but i still have problems to install custom ROMs or the stable Xiaomi.eu ROM.
The fastboot ROM installation with mi flash tools ends with an error (Not catch checkpoint (\fastboot -s .*lock) Flash is not done (I choosed the option clean all, not the lock function)
cDroid Rom is working, but with this ROM i cant use google pay.
cDroid with update to xiaomi.eu weekly is also working, but also without google pay.
Xiaomi.eu stable - bootloops
Do you have any ideas why i cant use all ROMs?
Should i choose a chineesevendor image or something else?
I also heared, that it could be, that the device bricks, when i try to re-lock the bootloader, is this an option?
Which ROM should work fith functional google pay ?
Thanks in advance
The problem seems to be solved,
i have to flash "Disable_Dm-Verity_ForceEncrypt" after the flashing of every ROM, then I have no bootloops / boot Problems.
Now i only have the problem with google pay...
I couldn't also get Miui Eu bootable on my mi8 last time. I didn't realize what you had mentioned Disable_Dm-Verity_ForceEncrypt. But I could manage to get MiRoom Miui workable and it seems ok for now.
stevedat said:
I couldn't also get Miui Eu bootable on my mi8 last time. I didn't realize what you had mentioned Disable_Dm-Verity_ForceEncrypt. But I could manage to get MiRoom Miui workable and it seems ok for now.
Click to expand...
Click to collapse
DM verity zip removes the 'DM Verity' check that looks for modifications to the boot partitions (D-device M-mapper). You cannot boot with modifications (like root) without disabling the verity check. Also, if you are on a stock ROM, your custom recovery image file will be overwritten with stock upon reboot if you don't disable DM Verity. Hope this helps you understand more.
Found it on this topic.
I´m still looking for a ROM with google pay support, but iu think with unlocked bootloader and without root therre is no chance...

Bring light into the darkness of encryption

Hi togehter,
I had some problems with flashing new custom roms and ended up in a bootloop with not being able to boot to recovery. This could be solved by flashing the stock image with the xiaomi flash tool.
Before I will fu up again I would like to bring some light into the darkness.
When coming from Stock Rom:
1. Unlock Bootloader -> done successfully
2. Flashed TWRP Recovery -> done successfully but storage (data) was encrypted
3. Flashed Magisk via Recovery -> done successfully (storage still encrypted)
from here I was happy using the Stock Rom with Root.
Now I started messing things up:
Because there are a few things that bother me about the stock rom i wanted to use lineageOS/Pixel Experience. So I proceeded as following:
1. Backup my data (still have to enter key when starting twrp to decrypt the storage) -> done successfully
2. Flash LineageOS -> resulted in bootloop to TWRP
When entering twrp there was no query about the key and data where encrypted. Also the Backup was not accessible .
3. I used all in one tool to erase storage and decrypt data. -> successfully... Now i was able to place data on the internal storage again and start flashing a rom
4. Flashing LineageOS -> done successfully and able to boot into rom
Back to TWRP data was encrypted and I had to enter key.
5. Flashing remove force encryption script via twrp. -> done but now i was facing boot to black screen. TWRP was not working anymore.
Only way to get it work again, was flashing stock image.
Why is the data system always encrypted. This is rly annoying and backups don't work, because i can not encrypt them. Also, I can not put any files on the memory because it is encrypted.
I would rly like to try a custom rom, but I would also like to be able to go back to a backup. What have i done wrong?
You have to flash no dm verify right after formatting data & flashing rom. Don't let it boot.
I would recommend using the stock firmware. Los/AOSP is rubbish for our device, it's too unstable, lacking features and has worse gestures.
SeppGoPro said:
Hi togehter,
.... What have i done wrong?
Click to expand...
Click to collapse
You need to format data (not just wipe data) in TWRP. Some people suggest before flashing a ROM and some say after, but I don't think it makes a great deal of difference either way.
Make sure you either flash the appropriate firmware and vendor recommended, or the fastboot ROM of that version.
Then in TWRP wipe cache and dalvik, then format data.
Reboot into TWRP, or unmount and mount the data partition in TWRP so it correctly reads the data partition.
Copy across the ROM (and GApps if needed)
Them flash.
Boot into the ROM and you should be good.
After initial setup, if you want root, boot into TWRP and flash Magisk.
From here, if you've set a pin on the ROM, you'll be encrypted, but everything should still work normally. You should be able to access everything normally in TWRP and also perform backups. You should be able to got data across from/to a PC normally.
Turbine1991 said:
You have to flash no dm verify right after formatting data & flashing rom. Don't let it boot.
I would recommend using the stock firmware. Los/AOSP is rubbish for our device, it's too unstable, lacking features and has worse gestures.
Click to expand...
Click to collapse
Not true in many ways.
There is need to flash no dm verity. It's one way of solving the issue, but it's not the only way. You should only do this if you know what it's for and if you know you want this.
AOSP ROMs are not unstable. I've been using them on mine for over 4 months. None are perfect and they have a few minor issues/bugs, but they are far from being considered unstable. I've never had shutdowns, reboots or FC'S.
Thanks for the replies.
Robbo.5000 said:
Make sure you either flash the appropriate firmware and vendor recommended, or the fastboot ROM of that version.
Click to expand...
Click to collapse
So for example with LineageOS 17 I can use the global vendor and firmware, but sometimes in the thread it is recommended to use chinese vendor and firmware. In this case I should flash another vendor and firmware then the global one.
What do you mean with a fastboot rom. How can I identify one of them?
Is the MiuiMix Rom a fastboot rom. This one changed my vendor and firmware. After flashing this rom, my bootlogo changed to redmi... Am i right with this suggestion?
SeppGoPro said:
Thanks for the replies.
So for example with LineageOS 17 I can use the global vendor and firmware, but sometimes in the thread it is recommended to use chinese vendor and firmware. In this case I should flash another vendor and firmware then the global one.
What do you mean with a fastboot rom. How can I identify one of them?
Is the MiuiMix Rom a fastboot rom. This one changed my vendor and firmware. After flashing this rom, my bootlogo changed to redmi... Am i right with this suggestion?
Click to expand...
Click to collapse
Fastboot ROMs are official ROMs that are flashed through the Mi Flash Tool
, with the phone booted into fastboot mode and connected to the PC. They contains almost all partitions, including vendor and all firmware. They will be a .tgz file. They are mainly used as an almost failsafe way to recover the phone, should you mess things up. Flashing them will restore the phone to factory, so will lose TWRP, but you're guaranteed a clean starting point.
If, for example, you want to install Havoc 3, it is recommended to flash it on top of either China or India 10.4 vendor and firmware. So if you're phone is currently on global firmware, you would then need to flash, say, Chinese firmware and vendor flies, before flashing Havoc.
If you have been previously flashing other mods, such as 75Hz, screen refresh rate, for example, then you might choose to flash the official Chinese fastboot ROM, instead of just the firmware and vendor, to ensure that you've cleaned the phone of any mods, etc. In most cases you will be fine flashing firmware and vendor, though.
Miuimix is a custom ROM, which is based on the official China MIUI ROM. Because it's based on the China ROM this is why the logo changed to Redmi.
Robbo.5000 said:
Miuimix is a custom ROM, which is based on the official China MIUI ROM. Because it's based on the China ROM this is why the logo changed to Redmi.
Click to expand...
Click to collapse
So in this case, i can just flash this rom and there is no need of flashing a diffrent vendor or firmware.
So final question: I'm happy with the stock rom plus root. I would like to try a custom rom but I'm not willing to go through the whole installtion procedure again. Is there a way of making a backup and keeping it?
When I backup the stock rom right now, the backup will ne encrypted again...When I formate the data, all my data will be gone again ?

Can't flash Lineage on MI 9T Pro: "package requires firmware from an Android 10 based MIUI build"

Really badly need some help here. My MI 9T Pro is on MIUI 12.5. When I first tried to flash Lineage 18.1 on the device (a week ago), I got the error message about Android 10 based MIUI build(in the subject line). I flashed the latest stable EEA firmware and tried again (I may have wiped too much in TWRP here: dalvik, cache, data, system, vendor). Then I got into a bad Fastboot loop (couldn't even flash back to TWRP). Don't remember how I got out of that (I think I flashed an empty vbmeta file onto the phone: vbmeta_dv_shivsom.img ).
Flashed back to MIUI stock 12.5 to get a clean start. Worked fine. Then flashed Pixel Experience, which worked fine. Flashed back to MIUI stock. Tried Lineage again. Got the same Android 10 error message before even beginning the flash. Then unzipped the Lineage ROM and edited the file updater-script (removing the Assert lines in the script). Zipped it back and tried to flash the modded ROM. Flash went through, but on reboot it got stuck on Fastboot. Have now done this in several rounds, gone back to stock, tried Lineage 17.1. Tried only doing Factory Reset and Format vs Wiping Cache and Dalvik). I also tried with the latest Havoc 4.8, same result. Tried with a modded Havoc. Tried to flash the latest China firmware before flashing the ROMs, didn't help. I'm totally stuck here and any help would be fantastic.
Forgot to mention. I also get the ERROR 7 message together with the Android 10 error message. (And when I tried to flash Havoc I got the ERROR 1 message together with the Android 10 error message.)
Greenwaldist said:
Forgot to mention. I also get the ERROR 7 message together with the Android 10 error message. (And when I tried to flash Havoc I got the ERROR 1 message together with the Android 10 error message.)
Click to expand...
Click to collapse
Do you have a global phone or an EEA/EU phone?
If it's a global phone flash the global MIUI ROM not EEA ROM.
Robbo.5000 said:
Do you have a global phone or an EEA/EU phone?
If it's a global phone flash the global MIUI ROM not EEA ROM.
Click to expand...
Click to collapse
Thanks a lot. The phone was bought i Europe (new). Flashed back to the 12.5 EEA stock from mi. But if you think the global version will make a difference, I can try that (if that works, any ideas why the EEA version would cause all these problems?).
Greenwaldist said:
Thanks a lot. The phone was bought i Europe (new). Flashed back to the 12.5 EEA stock from mi. But if you think the global version will make a difference, I can try that (if that works, any ideas why the EEA version would cause all these problems?).
Click to expand...
Click to collapse
You should be using the European ROM with the European phone, global ROM shouldn't make a difference. Try flashing the European firmware that is linked in the LOS OP.
When flashing you do not need to wipe system or vendor.
It is as rare as hens teeth the times when you need to wipe either system or vendor. In future did not do this. In future, only do the standard TWRP factory reset for a clean flash. There is almost never any need top go to the advanced wipe screen in TWRP.
Robbo.5000 said:
You should be using the European ROM with the European phone, global ROM shouldn't make a difference. Try flashing the European firmware that is linked in the LOS OP.
When flashing you do not need to wipe system or vendor.
It is as rare as hens teeth the times when you need to wipe either system or vendor. In future did not do this. In future, only do the standard TWRP factory reset for a clean flash. There is almost never any need top go to the advanced wipe screen in TWRP.
Click to expand...
Click to collapse
Will do. Yes, I followed bad step by step instructions and wiped too much on the first flash attempt. But any damage from aggressive wiping should be eliminated after I used the official MI flash tool and flashed it back too stock? Or is there any changes that remain on the devise after going back to pristine stock? ( Will stick to Factory Reset and Format Data in TWRP going forward.)
Greenwaldist said:
Will do. Yes, I followed bad step by step instructions and wiped too much on the first flash attempt. But any damage from aggressive wiping should be eliminated after I used the official MI flash tool and flashed it back too stock? Or is there any changes that remain on the devise after going back to pristine stock? ( Will stick to Factory Reset and Format Data in TWRP going forward.)
Click to expand...
Click to collapse
Flashing stock fastboot ROMs will restore everything.

Bootloop after flashing

It all started 1 month ago when my phone stopped working for 3 days, then went really slow.
Luckily I had the time to unlock it and I started trying to fix it today, but it won't work.
I tried to flash it with the latest EEA Rom on the MiFlash tool (succeed, but then it bootloop).
I also tried to flash it in recovery mod with OrangeFox but again it doesn't change anything
Btw phone is a Redmi Note 9 PRO (idk if the PRO does change anything)
Could you be more specific?
What did you unlock? Bootloader? Did you root the bootloader after?
Is it the correct rom for your device ( I know little of EU/EEA variants (I believe your choice here may be wrong) )
If you flash recovery then reboot into recovery, and it's still stock, you are using an unrooted bootloader.
Hello, thanks for the answer
This is hard to be specific as I've tried countless things and every one of them lead to others countless things not working either.
So yueah I unlocked the bootloader, and I think I'm in root already because when I try to install magisk via orangefox I get the following error
Error installing zip file '/sdcard/MAGISK/Magisk-v23.0.zip'​Which I believe tell that there is already another program rooting the bootloader.
About the ROM, I've tried severals of them, Global, EU, EEA, with Fastboot or Recovery, with different android version
Latest I've tried was :
joyeuse_eea_global_images_V12.0.4.0.QJZEUXM_20210423.0000.00_10.0_eea_8b93dea9fd
Then success, and bootloop
(Either the installation complete and nothing work, either the installation doesn't complete and I have to lookup for 1H30 where is it coming from)
how do I know if it's still stock after rebooting into recovery ?
Thanks a lot

Categories

Resources