FORUMS
Remove All Ads from XDA

Xiaomi Poco F1 [ROOT, Unlock Bootloader, with STOCK RECOVERY, OTA UPDATES etc!]

36 posts
Thanks Meter: 38
 
By exepowered, Member on 10th October 2018, 03:53 PM
View First Unread Post Reply Email Thread
WARNING: Before attempting to root your device, do note that by unlocking your bootloader and modifying your device with root, ROMs, etc... you are NOT risking voiding your warranty!
I am NOT responsible for what you do to your device either, so follow these instructions at your own risk. Make sure you know what you're doing, it's best to understand the process rather than just copy and paste commands and such.


Hello!
Some people asked me how to root Xiaomi Pocophone F1 with magisk and to keep stock recovery on it, to recive OTA updates etc. so this is the complete guide

Sorry for all language misstakes, my english is not perfect, so please, if you have found anything, inform me via private message, so I can edit the post and correct it.


1. Unlock Bootloader Unlocking Bootloader Explanation and Troubleshooting for NEWBIES | thanks to @madsponge26
2. TWRP boot (not flashing, you will keep your stock recovery)
3. Pull stock boot.img from your phone (method II)
4. Boot.img patching (Patching stock boot.img with magisk manager app) (method II)
5. Patched magisk boot.img flashing (method II)

Tools and Information we need
USB Driver
Minimal ADB Fastboot
TWRP 3.2.3-x Unofficial with working DECRYPTION 12/10/2018
Magisk Manager App


How to Unlock Bootloader


Back up Files (Internal Storage)

1. Go to Settings > About phone
2. Find the MIUI Version and press 6-8 times
3. Go to Additional Settings > Developers Options
4. Press and check USB Debugging and OEM Unlocking
5. Go to Settings > Developers Options > Mi Unlock Status > Add Account & Device and log in with your MI account.

6. Go to MIUI Unlock website
7. Login to your MI account
8. You should be able to download Mi Unlock and unlock bootloader without filling any forms or applying for permissions (I was able to do that this way)
- if not, then apply and wait.

*Install Xiaomi USB Drivers from link above or by Mi Unlock app settings option.*

In MI Unlock app:
1. Shut down your phone manually, and hold Volume down key and Power button to enter Fastboot mode.
2. Connect your phone to PC using USB cable and click "Unlock".

***Mi account should verified.



Booting into TWRP, getting ADB SuperUser access, pulling stock boot.img


1. Open Minimal ADB Fastboot terminal AS ADMINISTRATOR!
2. Shut down your phone
NOW FOCUS
3. Connect your phone to your PC and hold Power and Volume Down buttons until Fastboot screen will be visible.
4. Follow the steps:

Put that command in your Minimal ADB Fastboot terminal:
Code:
fastboot devices
Your phone should be visible.
example: ,,7e00a8e3 fastboot"

Code:
fastboot boot <path to your TWRP .img recovery file>
Your phone should be booted into TWRP recovery.
If ask's for password: CLICK CANCEL
If ask's for keeping /system read only: swipe (allow modifications)


UPDATE:
NOW YOU CAN JUST FLASH MAGISK.ZIP AND REBOOT
There was no TWRP with working decryption before.


Method II:

Code:
adb devices
Your phone should be visible.
example: ,,7e00a8e3 recovery"

Code:
adb shell
Here we go! We got access to Super User shell via ADB ^^

and now the magic:

- In TWRP recovery, go to Advanced > File Manager
- Go to "/dev/block/platform/" folder (go into ,,soc" folder, if you have one there)
- Here you will see some files and folders, we need to open folders and search for the folder called "by-name" inside one of them. || For me it was /dev/block/platform/soc/1d84000.ufshc and ,,by-name" inside of it.
- At the end, we need name of the folder contains ,,by-name" inside for this string: /dev/block/platform/soc/FOLDER NAME/by-name
- Now go to your ADB Shell terminal and put that command:

soc = you should have this folder too, if not; ignore (please confirm that in comments)
FOLDER NAME = your folder with ,,by-name" inside
Code:
ls -al /dev/block/platform/soc/FOLDER NAME/by-name
Now you should see partitions of your phone.
You need to find your boot partition, for me it was:
Code:
lrwxrwxrwx    1 root         root                16 Feb 15  1970 boot -> /dev/block/sde45
--

Pulling our stock boot.img!

Go to your ADB Shell terminal and put that commands:
Replace sde45 with your partition from step above*
Code:
dd if=/dev/block/sde45 of=/sdcard/boot.img
Code:
exit
Code:
adb pull /sdcard/boot.img
Our stock boot.img should be downloaded into our Minimal ADB Fastboot directory!

Code:
adb reboot


Stock boot.img patching and flashing (For Method II only)


1. Save your stock boot.img into phone's internal storage/sdcard
2. Download latest Magisk Manager from MAGISK GITHUB REPO
3. Install Magisk Manager on your phone.
4. Open Magisk Manager, check Keep Force Encryption
5. Click Install > Install > Boot Image Patching > Select your stock boot.img and patch it.
6. Save your patched boot.img to your computer

7. Shut down your phone
8. Open Minimal ADB Fastboot terminal on your PC
9. Connect your phone to your PC and hold Power and Volume Down buttons until Fastboot screen will be visible.
4. Follow the steps:

Enter commands:
Code:
fastboot devices
Your phone should be visible.
example: ,,7e00a8e3 fastboot"

Code:
fastboot flash boot <path to your patched_boot.img>
Code:
fastboot reboot
5. Open Magisk Manager, your phone should be rooted.
6. Download Root Checker from Play Store and check if your device is rooted.


FOR OTA UPDATES:
- Uninstall magisk with Magisk Manager App (Restore Image option)
- Apply OTA update
then:

Method I:
- Boot into twrp (version with working decryption)
- Flash Magisk ZIP again

Method II:
- Pull boot.img and patch it again
- Flash new patched boot.img



If you have any questions or problems, type those in the comment below, I will try to help you

Stock Mi Recovery 3.0 for Pocophone F1: GOOGLE DRIVE
The Following 16 Users Say Thank You to exepowered For This Useful Post: [ View ] Gift exepowered Ad-Free
 
 
10th October 2018, 03:54 PM |#2  
exepowered's Avatar
OP Member
Thanks Meter: 38
 
More
Before flashing OTA update, you need to uninstall magisk and install it again after update.
The Following User Says Thank You to exepowered For This Useful Post: [ View ] Gift exepowered Ad-Free
10th October 2018, 08:28 PM |#3  
Senior Member
Thanks Meter: 88
 
More
Thanks for a great tutorial, this is what I needed, just a few queries.
1. After ota will I retain root or again the whole process will have to be repeated.
2. In this process if I start with an unlocked bootloader with 8.10.9 beta rom any chance or need to wipe data or internal storage.
3. What if after flashing twrp, I just flash magisk and reboot without flashing force encryption disabler, stock recovery will automatically overwrite twrp, will I lose any data or root.
10th October 2018, 08:54 PM |#4  
exepowered's Avatar
OP Member
Thanks Meter: 38
 
More
Quote:
Originally Posted by sanjay0501

Thanks for a great tutorial, this is what I needed, just a few queries.
1. After ota will I retain root or again the whole process will have to be repeated.
2. In this process if I start with an unlocked bootloader with 8.10.9 beta rom any chance or need to wipe data or internal storage.
3. What if after flashing twrp, I just flash magisk and reboot without flashing force encryption disabler, stock recovery will automatically overwrite twrp, will I lose any data or root.

1. For now you need to uninstall magisk root before any OTA update, and install it again after it. I don't figured it out yet, how to update OTA and keep magisk.
2. Mi Unlock App will tell you if your internal storage needs to be wiped or not after connecting your phone in fastboot mode.
For me there was a red text that my internal storage will be wiped, for you it will be propably similar.

3. In this tutorial you are not flashing TWRP, you are just booting your phone into TWRP without flashing it to get acess to Super User via ADB and to pull stock boot.img to patch it later with magisk.
Target of this tutorial is to keep stock recovery, so it wont be overwrited because you will be already using it. It shouldn't affect magisk root, but
it would be an good idea to check ,,Keep Force Encryption" in Magisk Manager app before patching boot.img if you are not going to flash Disable Force Encryption zip etc.
11th October 2018, 04:44 AM |#5  
Senior Member
Thanks Meter: 88
 
More
Quote:
Originally Posted by exepowered

1. It depends propably on OTA update type. Can't answer for sure now, but OTA is comming on Friday with new version of MIUI 10 Beta so I will check that.
2. Mi Unlock App will tell you if your internal storage needs to be wiped or not after connecting your phone in fastboot mode.
For me there was a red text that my internal storage will be wiped, for you it will be propably similar.

3. In this tutorial you are not flashing TWRP, you are just booting your phone into TWRP without flashing it to get acess to Super User via ADB and to pull stock boot.img to patch it later with magisk.
Target of this tutorial is to keep stock recovery, so it wont be overwrited because you will be already using it. It shouldn't affect magisk root, but
it would be an good idea to check ,,Keep Force Encryption" in Magisk Manager app before patching boot.img if you are not going to flash Disable Force Encryption zip etc.

Thanks for ur help.
11th October 2018, 10:48 AM |#6  
Junior Member
Thanks Meter: 0
 
More
Hi, thanks for the tutorial but I have a problem when unlocking my bootloader, when I am on the Mi unlock application and I connect my phone in fastboot mode mi unlock do not recognize my phone and therefore impossible to click unlock.
My computer recognizes the phone well but not the application do you have solutions?
11th October 2018, 10:53 AM |#7  
Senior Member
Flag Białystok
Thanks Meter: 164
 
More
Open it as administrator

Wysłane z mojego POCOPHONE F1 przy użyciu Tapatalka
11th October 2018, 11:16 AM |#8  
Junior Member
Thanks Meter: 0
 
More
Quote:
Originally Posted by uremytoy

Open it as administrator

Wysłane z mojego POCOPHONE F1 przy użyciu Tapatalka

I opened it in administrator mode, it does not work
11th October 2018, 11:36 AM |#9  
Senior Member
Flag Białystok
Thanks Meter: 164
 
More
Inside unlock tool there are drivers. Try to install them. I've had the same and it worked for me

Wysłane z mojego POCOPHONE F1 przy użyciu Tapatalka
11th October 2018, 11:53 AM |#10  
Junior Member
Thanks Meter: 3
 
More
hey dudes, can someone please upload the stock recovery for me?
everytime the phone wants to install an ota it just boots into twrp and i have to manually reboot it from there.
so if i just flash the stock poco recovery the phone would updtate the ota normally and root still would be there?
The Following User Says Thank You to WasIstDenn For This Useful Post: [ View ] Gift WasIstDenn Ad-Free
11th October 2018, 07:12 PM |#11  
exepowered's Avatar
OP Member
Thanks Meter: 38
 
More
Before flashing OTA update, you need to uninstall magisk and install it after update.
The Following User Says Thank You to exepowered For This Useful Post: [ View ] Gift exepowered Ad-Free
Post Reply Subscribe to Thread

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread