Search This thread


Senior Member
May 3, 2011
4. Run "Flash.bat" (It will erase all your data and relock bootloader)
*If you don't want to relock bootloader, remove "fastboot oem lock" from "Flash.bat" and save.

Just a short question, will data be kept when not executing the OEM relock?

edit: Ok, i found out the the line "fastboot -w" will erase the user data. Anyone tried without this one?
Last edited:
  • Like
Reactions: comfort zone


Senior Member
Dec 20, 2016
4. Run "Flash.bat" (It will erase all your data and relock bootloader)

It is not necessary to delete data and reset the system!
You can upgrade to the newer version.

If you use Mi Flash Tool, select: flash_all_except_storage.bat

Or manually via fastboot:

adb reboot bootloader
fastboot flash devcfg devcfg.img
fastboot flash dsp dsp.img
fastboot flash modem modem.img
fastboot flash rpm rpm.img
fastboot flash tz tz.img
fastboot flash keymaster keymaster.img
fastboot flash cmnlib64 cmnlib64.img
fastboot flash cmnlib cmnlib.img
fastboot flash boot boot.img
fastboot flash system system.img
fastboot flash vendor vendor.img
fastboot flash mdtp mdtp.img
fastboot flash aboot aboot.img
fastboot flash sbl1 sbl1.img
[COLOR="DarkOrange"]fastboot boot patched_boot.img[/COLOR]

Open Magisk -> Install -> direct
Last edited:

Top Liked Posts

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