yashsingh1/xdaforums huggingface dataset:
[Xiaomi Redmi Note 5 Pro Questions & Answers] cinmil:
This happen to me 2 day ago.same like the user mention.screen freeze and then when restart it stuck forever on splash image.twrp also stuck on start image.read from 1 user from indonesia.he also have this symtom and the mi technician said ic cpu got damage.so guys.whether u have to change motherbod or buy new phone its up to you.but i suggesting buy a new phone.move on..changing mother price is u can get new phone with better chipset.hope this will known to other user that have this problem.i also don know what to call this phone symtom.. hardbricked faker?.fyi i already oder note 9s.but i really love reno5 huhu.so sad it cant be fix.
[Xiaomi Redmi Note 5 Pro Questions & Answers] mustafaokeer:
Same happened to me last week, tried all methods like OP but no luck so gave up and ordered redmi note 9 pro (64mp). But i miss my rn5 pro so much ?

Probably emmc or cpu got corrupted for no reason, shame on you xiaomi but i couldnt give you up ?
[Xiaomi Redmi Note 5 Pro Questions & Answers] Prathamesh 27:
Try installing through qualcom flash tool Link

I had this issue once because of incomplete flashing and due to this my device was hard bricked. I then installed firmware and stock rom by this tool ig..
[Xiaomi Redmi Note 5 Pro Questions & Answers] mustafaokeer:
Thanks for help, but this one didn't work too. Still getting errors.
[Xiaomi Redmi Note 5 Pro Questions & Answers] Prathamesh 27:
Can you explain what happened to your device? Also try flashing fastboot rom.

Also try to boot into orangefox recovery, and flash system from there.

Use orangefox, it is good for our device.
[Xiaomi Redmi Note 5 Pro Questions & Answers] mustafaokeer:
Not sure what happened. Phone suddenly shut down on its own. Tried to power on stuck at mi logo. Tried to go recovery (orangefox) it also stuck at splash screen. Tried flashing another recovery (twrp) via fastboot, it returned with FAILED (remote: 'Error flashing partition : Write Protected'). I get this error while flashing main partitions too (data/system/boot/recovery). Tried various versions of miflash, each one returned with errors. Tried on edl mode, still errors. Tried qfil flasher, errors again :( so i gave up. I guess this is a hardware problem, not software.
[Xiaomi Redmi Note 5 Pro Questions & Answers] Prathamesh 27:
First things first: you never ever flash recovery! You boot into recovery and flash recovery through booted recovery. Try booting into recovery

Use:

fastboot boot xxx.img
[Xiaomi Redmi Note 5 Pro Questions & Answers] mustafaokeer:
actually firstly tried this. It finishes without errors, phone boots into recovery but again stuck at recovery logo(twrp/orangefox). tried official recovery, it boots without errors and can be used with only wipe data option. Tried it but stuck at %99.99
[Xiaomi Redmi Note 5 Pro Questions & Answers] SubwayChamp:
If you now can't flash through fastboot (doesn't?) then probably your OEM unlock toggle was disabled.
[Xiaomi Redmi Note 5 Pro Questions & Answers] mustafaokeer:
if i check "fastboot oem device-info" it says my phone is unlocked.

tried relocking bl via fastboot and unlocking via miunlocker still no luck :(
[Xiaomi Redmi Note 5 Pro Questions & Answers] SubwayChamp:
No luck in which part; re-locking it or re-unlocking it? Also you can flash something through fastboot or for example erase some partition? so probably flashing mdtp or persist partition could solve it.
[Xiaomi Redmi Note 5 Pro Questions & Answers] mustafaokeer:
no problems with relock re-unlock processes. Just can't flash anything and cant access recovery.

current status is https://ibb.co/WxXRL0D
[Xiaomi Redmi Note 5 Pro Questions & Answers] SubwayChamp:
Why do you want to flash the recovery (stock?) in the boot partition?
[Xiaomi Redmi Note 5 Pro Questions & Answers] mustafaokeer:
Oops my bad, it should be fastboot flash recovery recovery.img. but this command returns with same error too. Error flashing partition:Write protected
[Xiaomi Redmi Note 5 Pro Questions & Answers] SubwayChamp:
It seems either a hardware damage or an ARB protection. Although this is not the same issue than yours, you could try with the method and the file linked https://xdaforums.com/showpost.php?p=83588965&postcount=16
[Xiaomi Redmi Note 5 Pro Questions & Answers] Prathamesh 27:
This may sound stupid but try changing where your phone is connected i.e., if it is connected to usb3.0 port then change it to 2.0 and vice versa... I don't know how that works but for my phone that had worked!

---------- Post added at 01:09 PM ---------- Previous post was at 12:57 PM ----------

The command should be fastboot boot XXXX.img

(here XXXX.img being the recovery image file)

Dont flash recoveries through fastboot, it fails. Boot recovery through fastboot and then flash through the recovery.
[Xiaomi Redmi Note 5 Pro Questions & Answers] mustafaokeer:
Yeah normally doing like this, but recovery stuck at splash logo when i boot to recovery via fastboot.

Also tried 3 pc(2 desktop 1intel 1amd, also 1 intel notebook) and 8-9 usb ports total (2.0/3.0) every time it fails. I'm almost sure that's an hardware issue

Tried edl mode, phone goes to edl mode but miflash and qfil give error when flashing. Miflash gives an error like "emmc skipstorageinit=0"

my phone is not 2 years old yet but obviously warranty is void so didn't send to service.Bought it for 1700 turkish liras (220$) on november 2018 and if the problem is related to motherboard it should cost like 1000-1500 liras. So i bought redmi note 9 pro for 3000liras and gave up on trying to revive rn5.
[Xiaomi Redmi Note 5 Pro Questions & Answers] SubwayChamp:
Did you try to flash mdtp.img?, also try with vbmeta.img using

fastboot --disable-verity flash vbmeta vbmeta.img

or simply

fastboot flash vbmeta vbmeta.img

I never used, I read that a USB hub can work too.

Also try formatting first the partition that you want to flash, for example format the boot partition using

fastboot erase boot

then try flashing the boot partition but remember that it has to be concordant with the ROM that currently is flashed onto your device otherwise won't boot.
[Xiaomi Redmi Note 5 Pro Questions & Answers] Urzu18:
I wish to be updated here. Same issue! :(
[Xiaomi Redmi Note 5 Pro Questions & Answers] supermike23:
Help me too please!!

I have a Redmi Note5 Pro from Saturday while uploading instagram stories decided to crash and got reset stuck with Bootloop on MI.com logo. The device said it's unlocked.

I CANNOT go into recovery mode.

I have connected to device to my laptop (Windows 10) through fastboot try to flash any recovery: OrangeFox, TWRP, no success.

This is the error:

c:\adb fastboot flash recovery recovery.img

Sending 'recovery' (31161 KB) OKAY [ 0.669s]

Writing 'recovery' FAILED (remote: 'Error flashing partition : Write Protected')

fastboot: error: Command failed

So I try this command: fastboot boot recovery.img

It loads the recovery either TWRP or OrangeFox but only the Logo nothing else.

So now I can use ADB commands.

I can do adb devices and it says it's in recovery mode

Then with ADB SHELL LS

I can see the folder tree

With Push and Pull I can copy folders but cannot access and copy the content of SDCARD and STORAGE.

I know those folders are protected even though my phone should be unlocked but apparently it is not then.

Via fastboot I have those details:

fastboot oem device-info

(bootloader) Verity mode: true

(bootloader) Device unlocked: true

(bootloader) Device critical unlocked: true

(bootloader) Charger screen enabled: false

OKAY [ 0.006s]

Finished. Total time: 0.006s

Is there a WAY with lower level commands or software to access to data write protected inside the phone memory?

Or the only solution is to give the Device to experts and do the CHIP Off recovery data?

Please Help!

If anyone can help to recover my data seriously I do I am happy to give a compensation with PayPal cause I would appreciated the effort and help!

Thanks in advance for anyone's willingness to help!
[Xiaomi Redmi Note 5 Pro Questions & Answers] Prathamesh 27:
Flashing recovery never worked for me.

Try booting in pitchblack just to see if this works. You just have to get lucky once!

During copying of files, what command did you use?

Try using adb pull "/sdcatd/Android"

May I suggest flashing orignal fastboot ROM without cleaning all data as last resort? If you do this, don't disconnect your phone till you get completed confirmation from the app(the green loading bar disappears). I had to wipe my phone clean because I just pulled it out while the process was about completed.
[Xiaomi Redmi Note 5 Pro Questions & Answers] supermike23:
I tried to download the PitchBlack Recovery Project still just logo no options to select.

I plugged my phone in fastboot run from powershell: fastboot boot recovery.img

It loads the recovery but only the logo no options to select

Then I tried any commands of adb from cmd just working adb devices, adb shell ls, adb pull ls /sdcard is not working dont show anything.

I believe the folder is protected.

Any work around to get this folder copied? or delete the protection?

If I choose a rom to flash with my flash which one really keep user data?

I mean clean_all_except_userdata.

And by userdata what's included? the folder DCIM and Whatsapp folder are considered user data?

Will be they kept?

I don't see much options if not going to a data recovery company to extract data from the chip?

no help at all from Xiaomi it's a shame as Google!

They should think of a better way to keep data secure but also allow the owner to retrieve his data without loosing it, especially after a normal phone usage not doing anything out of the ordinary!

So pissed off!

How did it work for you? were you able to boot a custom recovery?

Is it the problem of doing from a Windows 10 Laptop with usb3.0?
[Xiaomi Redmi Note 5 Pro Questions & Answers] SubwayChamp:
Try flashing vbmeta and then you should try to boot to OrangeFox and after flash it.
[Xiaomi Redmi Note 5 Pro Questions & Answers] Prathamesh 27:
Okay I don't know why this is happening and yes I successfully copied one folder(the pictures folder)

Do you know which folders you want to copy?

You try to use the command that I gave

adb pull "/sdcard/DCIM"

Try individually for each folder. This may work and you could get all your data. Also

adb pull "/sdcard"

worked for me.

Yes you should try installing rom by selecting save_user_data.

This would leave sdcard untouched. I don't have idea about /data folder, but it should also be left untouched ( No idea, do this on your own risk).

I had everything backed up in cloud. Because I pulled the plug before the process finished, it wouldn't boot. I had to clean Qualcomm flash the rom :(

Try flashing vbmeta.img as [MENTION=7644154]SubwayChamp[/MENTION] suggested.
[Xiaomi Redmi Note 5 Pro Questions & Answers] supermike23:
I tried flashing vbmeta but not working same error. Write protected. :(

Cant find a solution or work around it seems

I just need to decrypt those folders I guess and then be able to see the inside and then finally copy them.

Any work around?

What about flashing with save user data mode it will keep my ROM data such as Whatsapp folder and DCIM inside the phone untouched or they will be erased?

Thanks

---------- Post added at 12:27 AM ---------- Previous post was at 12:21 AM ----------

I tried same commands so many times with any boot custom rom but no success

fastboot boot recovery.img (any recovery TWRP, OrangeFox and others)

Just loading the LOGO and that's it then I can see the phone connected on my laptop and I can use adb commands.

With adb I try adb shell ls and see the folders but cannot copy them cause they must be encrypted and protected unfortunately.

Any work around?

Doing flash with save user data will really keep my data in DCIM and so on?

---------- Post added at 12:34 AM ---------- Previous post was at 12:27 AM ----------

I tried same commands so many times with any boot custom rom but no success

fastboot boot recovery.img (any recovery TWRP, OrangeFox and others)

Just loading the LOGO and that's it then I can see the phone connected on my laptop and I can use adb commands.

With adb I try adb shell ls and see the folders but cannot copy them cause they must be encrypted and protected unfortunately.

Any work around?

Doing flash with save user data will really keep my data in DCIM and so on?
[Xiaomi Redmi Note 5 Pro Questions & Answers] Prathamesh 27:
[MENTION=9323665]supermike23[/MENTION]

This you might find it useful.

You might need to change recovery img dummy img and maybe edit xml files for your device.

Good luck!
[Xiaomi Redmi Note 5 Pro Questions & Answers] supermike23:
what do you mean you might need to change recovery img dummy img and what xml files should I edit?

Thanks
[Xiaomi Redmi Note 5 Pro Questions & Answers] SubwayChamp:
OK, you may try the next steps, just one by one, every try is apart.

1.- Disable DM verity by fastboot commands:

fastboot oem disable_dm_verity

and then see if you can flash/boot to OrangeFox/TWRP trying these 4 possible methods described next:

2.- The first 3 are copied/pasted from other thread:

"+ by entering terminal command in command line: >>fastboot boot twrp-x.x.x-x-whyred.img<<, or

+ by holding together "Volume Up + Power" until you see the MI logo, release "Power" button but keep pressing "Volume Up" until you see the recovery, or

+ by holding together "Volume Up + Volume Down + Power" until you see recovery"

- Typing fastboot reboot (once custom recovery is flashed) and pressing only volume up till recovery screen appears completely.

Of course you should have to successfully flash it previously in order to work.

3.- Flash the recovery image onto the boot partition, and then reboot normally, supposedly device will enter to boot and will find the recovery image there, type

fastboot flash boot TWRP/OrangeFox/Whatever.img

4.- In MiFlash tool there is an option to keep data, flashing the same Miui version that you had previously won't delete data, I use successfully this version many times https://androidfilehost.com/?fid=4349826312261688231
[Xiaomi Redmi Note 5 Pro Questions & Answers] drnightshadow:
You need fasboot and flashed dummy.img first!!! <-- you can take it from MIUI FASTBOOT ROM

Than you can flash fastboot boot recoveyTwrp.IMG.

Than you can flash your recovery by TWRP (OrageFox,etc).

If you'll install OrageFox it will auto reboot in OrangeFox in 5 sec...and viola your done...

No extra steps needed.

So in short step by step

-use miunlock to unlock bootloader

-put phone on fastboot mode

-type 'fastboot flash antirbpass dummy.img'

-type 'fastboot flash recovery twrp.img'

-type 'fastboot boot twrp.img'

- in TWRP click install chose OrangeFox recovery zip file

- and viola in 5 sec you'll get Installed Orangefox

- install custom ROM as instructed in ROM thread

Good luck and stay safe!
[Xiaomi Redmi Note 5 Pro Questions & Answers] supermike23:
1) I can't flash ANY Fastboot images and I can't access to any recovery mode.

The command you gave me, reports an error.

So I do this process over and over again but no luck:

Turn on the Redmi Note 5 Pro in Fastboot mode.

I try to flash any recover it won't work, your command doesn't work no success either it's like giving me an error.

I try to do flash boot recovery recovery.img (recovery.img can be any custom recovery) it loads only the LOGO.

Now I can see the device in ADB if I do adb devices it turns that the device is in recovery mode but only with LOGO.

I can't access to any folder though see them

The device seems to be unlocked from fastboot commands. If I use MI Unlock tool will definitely erase data so I wanna keep my data and try to recover them.

What happened to you and how did you solve to keep your data with data I mean whatsapp folder, DCIM folder and sms. those 3 things I care about cause in DCIM there are photos and also screenshots .

Thank you so much.
[Xiaomi Redmi Note 5 Pro Questions & Answers] supermike23:
If I use miunlock as procedure it will erare my data to unlock bootloader and I really wanna keep my data.

I need to recover my DCIM folder including photos, screenshots, screenrecorder

my WhatsApp folder and SMS

In order you can see what I do trying with many recovery custom ones but cannot flash any.

I know there is an option of flashing a ROM with save user data mode though I am not sure what clean_except_user_data with miflash does. if really keeps data like DCIM, sms, whatsapp folders and so on untouched or will erase them. that's my doubt.

Anyway that's what I do:

- phone in fastboot mode

- run fastboot commands

- see the phone attached and use your command fastboot flash antirbpass dummy.img' NOT sure which dummy.img is the right one for my redmi note 5 pro I flashed the one I found online. anyway no error as you can see.

- trying to flash any recovery won't work as you can see. WRITE-PROTECTED even though from fastboot it says device unlocked. of course cannot access to USB debug as the phone is stuck in bootloop

- if I boot in any recovery as Twrp, or others I can see only the LOGO running that's all. No commands prompt appearing. :(

The phone is attached still on my laptop runnin windows 10, it says as android device attached actually the name of the phone too RedmiNote 5 Pro but cannot see the content of course it's not in MTP mode and OS hasn't loaded anyway.

- i can run adb shell ls see the whole folders but cannot copy and see the sdcard or storage of course cause they are encrypted.

Any help?

If I use a custom rom and miflash to flash any rom even the MIUI selecting the option clean_all_except_user_data (what does it do). It really keeps my personal data untouched such as Whatsapp folder, DCIM and so on?

Anyone has tried and can assure that?

Thanks.
[Xiaomi Redmi Note 5 Pro Questions & Answers] SubwayChamp:
Probably you doesn't have enabled USB debugging, I didn't recommend dummy.img cause I don't know exactly from which flashing cycle you are coming but keep it in mind that if you had a Miui ROM working before and you didn't switch to custom ROMs then the dummy.img in this thread should help you https://xdaforums.com/redmi-note-5-pro/how-to/index-everything-anti-roll-t3816219 fastboot in Whyred doesn't allow downgrades so you would need firstly flash this image to do it "permissive" in order you can flash something "custom" on it.

Anyway if this doesn't solve the issue so it depends on what you messed up before you can flash as I said you previously the exact Miui ROM that was previously running using MiFlash tool through the option to Keep_userdata and your data won't be deleted.
[Xiaomi Redmi Note 5 Pro Questions & Answers] supermike23:
Nothing is working my problem is not the one you are addressing sorry!

Should I create a new post?

So maybe someone can help me.

My problem is that from DEVICES-INFO the bootloader seem unlocked.

If I launch any custom rom with fastboot boot recovery.img it runs only the logo doesn't allow me to do anything so the device doesn't mount the disk

WITH ADB commands I can only see the tree of the folders but cannot access to sdcard and storage as they are protected.

if I flash any custom recovery the error would be write-protected not anti-rollback.

If I try MIFLASH what's the difference between flash_all_except_data.bat and flash_all_except_data_storage.bat?

There seem no difference between them?

Same code just a tiny difference in the .sh

Will this code flash and erase storage?

fastboot %* flash storsec %~dp0images\storsec.mbn || [MENTION=279333]ECHO[/MENTION] "Flash storsec error" && exit /B 1

fastboot %* flash storsecbak %~dp0images\storsec.mbn || [MENTION=279333]ECHO[/MENTION] "Flash storsecbak error" && exit /B 1

My concern is to keep DCIM folder and its content inside and WhatsApp folder safe.

Is that possible?

Thanks in advance.
[Xiaomi Redmi Note 5 Pro Questions & Answers] SubwayChamp:
No, I pretty understood what your issue and goal are, the idea is just to find a way to flash a recovery so you can navigate to the folders that you want to take a copy.

Also the idea to flash dummy.img was Just in case ARB was linked in some way with WRITE_PROTECTED barrier so it doesn't look too easy find a proper solution for this anyway I never were so confident to try to preserve some data from my device instead to recover my device itself and the one thing I can think of is trying to flash the same fastboot ROM that you had previously using MiFlash tool either in fastboot and if it is not allowed then in EDL mode.

The first preserves user data, this means the apps with its settings, the general settings (of course also your internal SD Card) and the second is to preserve only internal storage or internal SD Card where DCIM and WhatsApp folders are allocated.
[Xiaomi Redmi Note 5 Pro Questions & Answers] supermike23:
Thanks for your help.

I thought it's the opposite!

flash_all_except_data.bat WILL KEEP DATA

flash_all_except_data_storage.bat WILL KEEP DATA AND STORAGE

Is that correct?

So flash_all_except_data_storage is the one I should use! It's the one that does less wiping right?

Though why the .bat seems exactly the same?
[Xiaomi Redmi Note 5 Pro Questions & Answers] SubwayChamp:
MiFlash tool only have three options:

- Clean all: this is a clean flash, this wipes all and format all the partitions but without re-lock bootloader.

- Save user data: This preserve user data (general settings, preferences, etc) and internal storage/memory.

- Clean all and lock: This does the same that the first but re-locking bootloader.

Your option is clearly the second.
[Xiaomi Redmi Note 5 Pro Questions & Answers] R3D5H4D0W:
Hello! I have the same exact issue. At this point i'm not even interested in revive my phone but in recover my personal data (Pictures and whatsapp conversations specially) Have any of you found a way to?

Sorry for my bad english.
[Xiaomi Redmi Note 5 Pro Questions & Answers] gotxges:
Hi.

I think that all your data are lost and unrecoverable
[Xiaomi Redmi Note 5 Pro Questions & Answers] R3D5H4D0W:
Yeah, I agree. Do you think it's possible to revive my phone? Without buying a new mainboard.
[Xiaomi Redmi Note 5 Pro Questions & Answers] gotxges:
No, i think it's impossible.

The only possibility it's repair MMC with UFI BOX
[Xiaomi Redmi Note 5 Pro Questions & Answers] Bhumik69:
hello did you restored your write protected whyred
[Xiaomi Redmi Note 5 Pro Questions & Answers] Bhumik69:
hello i ALSO HAVE THE SAME PROBLEM DOES YOU DEVICE IS WORKING NOW PLS HELP
[Xiaomi Redmi Note 5 Pro Questions & Answers] nguyenlucky:
It's a hardware (eMMC storage) failure, don't bother trying anything.

A flash memory is automatically switched to Write Protection Mode when damaged.
[Xiaomi Redmi Note 5 Pro Questions & Answers] eisenbergw:
Hi @SubwayChamp,

Do you have a guide or something similar that describes these different partitions? I've searched for information about mdtp.img and vbmeta.img, and found nothing useful. What other partitions are there (besides the obvious ones like system, boot, cache, etc)?

Edit: finally found some threads on vbmeta.img. That mystery is solved. Now to sort out the other partition mysteries...
[Xiaomi Redmi Note 5 Pro Questions & Answers] Megarox:
It did it work?
[Xiaomi Redmi Note 5 Pro Questions & Answers] drnightshadow:
Oh don't tell us where vbmeta.img threads are.. it's still a mystery :alien: :unsure: