yashsingh1/xdaforums huggingface dataset:
[Xiaomi Mi A1 Guides, News, & Discussion] ltf_195:
Hi OP [MENTION=7177145]jashancheema[/MENTION], I think you should update this thread since we already have working bootable twrp for oreo.

For people having bootloop , you can try this:

1. Download recovery from this post

2. boot to recovery.img

fastboot boot xxx_recovery.img

3. Flash magisk uninstaller from here and reboot your phone

4. If you successfully reboot your phone continue to install magisk

5. boot to twrp (step 2 above)

6. Flash lastest Magisk from here

7. reboot your phone and install Magisk Manager

Edit: If still failed try to flash Magisk 15.1 (on step 6), thanks @KalolParty for testing this
[Xiaomi Mi A1 Guides, News, & Discussion] akikara:
Followed steps above.

BUT stuck at " install magisk installer using direct method ".

I could not see direct method.

Two methods appear. "Download Zip Only" and "Patch Boot ımage File". If I choose first it just downloads, no install. But I confuse things in second choice. When I select it, It wants "Stock boot image." That is not clear. Should I choose the file you provided at step 2(I have applied January 2018 Update. My security patch is Jan 2018)?

If so After selecting patched boot img. It patches "patched boot img", right? But after last reboot nothing happens.
[Xiaomi Mi A1 Guides, News, & Discussion] KalolParty:
Did you actually try this method?

---------- Post added at 02:32 PM ---------- Previous post was at 02:01 PM ----------

Hey, please don't quote the OP. We'd all appreciate it if you could make the change.
[Xiaomi Mi A1 Guides, News, & Discussion] KalolParty:
Okay thanks! I'll try it and get back here!

---------- Post added at 03:15 PM ---------- Previous post was at 02:47 PM ----------

Didn't work for me. It just put my phone in a bootloop and force rebooting didn't help.

I had to boot into TWRP and flash the uninstaller and now its back to normal.

Thanks for your help though. Any other suggestions?
[Xiaomi Mi A1 Guides, News, & Discussion] ltf_195:
Did you encounter any error while installing?

Because it look like magisk problem,

If you can make catlog and post it to magisk support thread it would be great, because a lot of people having this problem
[Xiaomi Mi A1 Guides, News, & Discussion] KalolParty:
Nope, no errors. Installed just fine.

I'll try flashing 15.2 instead of 15.3

---------- Post added at 04:10 PM ---------- Previous post was at 03:35 PM ----------

Okay 15.2 didn't work but 15.1 did!

All of you trying to flash Magisk using [MENTION=7747487]ltf_195[/MENTION]'s method, flash 15.1. It works flawlessly
[Xiaomi Mi A1 Guides, News, & Discussion] NITRO_100:
Did you install magisk in direct method ?
[Xiaomi Mi A1 Guides, News, & Discussion] akikara:
I hope you answer my question too. :/
[Xiaomi Mi A1 Guides, News, & Discussion] ltf_195:
Guys, good news. Android O Rom can be download now http://en.miui.com/download-333.html. For people who have bootloop/softbrick/update installation fail, you can flash using MiFlash, you can keep your data, just follow the guide from the link.
[Xiaomi Mi A1 Guides, News, & Discussion] mehdazz:
reboot failed.

followed all the steps correctly, but the device goes to recovery mode after reboot.

the device do not boot up any more.. :crying::crying::crying:

I flashed it to stock again.
[Xiaomi Mi A1 Guides, News, & Discussion] ltf_195:
If you boot correctly you will see the Direct Install option. Here what you have to do.

1. check your security patch level . Setting>System>About phone>

If January, download the January patched_boot, if December, download the December patched_boot. Download again just to be sure

2. follow the step

3. After you boot to patched_boot.img (Step 10) make sure you are successfully boot on first try.

4. Then open magisk manager>Install>Direct Install (Recommended)
[Xiaomi Mi A1 Guides, News, & Discussion] 0741407414:
This is a great job
[Xiaomi Mi A1 Guides, News, & Discussion] Mizuru:
Could you upload the 15.1 magisk zip? Can't find the older versions.
[Xiaomi Mi A1 Guides, News, & Discussion] bonosharm:
after doing this method, do i relock the bootloader for making ota updates working or not?
[Xiaomi Mi A1 Guides, News, & Discussion] xxqxpxx:
Does this remove the data and apps on the device ?
[Xiaomi Mi A1 Guides, News, & Discussion] noiseee boy:
Hi team,

I want to root my phone, but what the problem with my phone is. I have some important data in it and not possible to take backup. So my question is, after rooting my phone. My phone's data got delete or should I have to cancel my plan to root
[Xiaomi Mi A1 Guides, News, & Discussion] traianescu:
post 33 + post 34
[Xiaomi Mi A1 Guides, News, & Discussion] barnumbirr:
Installed the SELinux Permissive Script Magisk module, fixes the camera lag. Thank you. :good:
[Xiaomi Mi A1 Guides, News, & Discussion] youlenin:
hi guys. my phone goes in bootloop when i use a patched boot image. i have made my own patched image but the phone still doesn't boot. the bootloader is unlocked.

Edit: I think I know what is the Problem, when I got the Oreo update I had some active magisk modules, one of them was the a1 Tool for gcam, and from what I understand now this module causes a bootloop in Oreo. So I want to ask you all if there is a method of uninstalling magisk modules without the manager app because the menus for the modules do not appear without root.
[Xiaomi Mi A1 Guides, News, & Discussion] _MrAlpha_:
Hello everyone, first forum post here so I'll try to be as detailed as possible.

I tried to root my Mi A1m running Oreo 8.0, however I've encountered a problem. When in fastboot mode, the pc doesn't recognize my device. Actually, when in device manager the Android device is listed but if I type in the command prompt fastboot devices no devices are found. Because of this, doing fastboot oem unlock asks me to connect a device.

What's the problem here? USB debugging is active, OEM unlockin also. I have the ADB drivers installed and the Google USB drivers too.

What am I missing? Am I doing something wrong?

Thanks everyone!
[Xiaomi Mi A1 Guides, News, & Discussion] mhdsanto85:
How can I install that? I'm new in magisk
[Xiaomi Mi A1 Guides, News, & Discussion] gaxander:
if you use SD card as adopted, make sure Magisk Manager is installed on internal storage. You must move it manually to internal storage.
[Xiaomi Mi A1 Guides, News, & Discussion] klebengan:
Instructions works flawlessly with me from fresh installed oreo.

Anyway i am using "fastboot boot patched_boot.img"
[Xiaomi Mi A1 Guides, News, & Discussion] Santosh Kolur:
Guys i tried the given steps but my phone's stuck at android one logo for the past 10 minutes , any suggestions?? Like the last command I used 'fastboot boot patched_boot.img" please help!
[Xiaomi Mi A1 Guides, News, & Discussion] tosmopolitan:
Same here. I followed every instruction properly. Probably going to have to reflash phone to last available ROM(December Nougat) and as a result lose all data because the encryption is different.
[Xiaomi Mi A1 Guides, News, & Discussion] solocesarxd:
How you installed magisk from inside the magisk manager app? It asks for a boot. Img
[Xiaomi Mi A1 Guides, News, & Discussion] Santosh Kolur:
could you provide me with stock oreo stable boot img?

---------- Post added at 04:45 PM ---------- Previous post was at 04:44 PM ----------

Nope i just installed the apk and flashed boot image
[Xiaomi Mi A1 Guides, News, & Discussion] klebengan:
It doesn't ask anything in my case. Just click install and it will download the magisk zip file and automatically install it. Done. Reboot. Voilla! All set.
[Xiaomi Mi A1 Guides, News, & Discussion] Aj.GaLaxY aCE:
What si the recommended way , I am quite confused. Never used magisk
[Xiaomi Mi A1 Guides, News, & Discussion] belean_cristian:
Hi.

Inside Magisk manager when you press install it will ask you to download it and install it. Once is downloaded it will ask you the method of installation. I chose Direct install (Recommended) from the list.

Good luck.
[Xiaomi Mi A1 Guides, News, & Discussion] traianescu:
in this case, flash again the img, but this time, if you used boot_a, now do it with boot_b and it will work for sure

it: cambia il commando flash con l'altra partizione, se ai fatto prima con boot_a, ora fai con il boot_b per esempio... ho sofferto anch'io sta stronzata e non capivo niente
[Xiaomi Mi A1 Guides, News, & Discussion] jashancheema:
Go to magisk manage and press install buttong

Then press direct install and reboot.

Simple,??
[Xiaomi Mi A1 Guides, News, & Discussion] mdabuzer75:
Method works confirmed.

flashed the patched_boot.img file as per the steps given

Installed magisk apk later

Inside the magisk app, installed direct(recommended) method

SafetyNet okay

one question, is this enough for surviving OTA?
[Xiaomi Mi A1 Guides, News, & Discussion] Yivi_Yuvaraj:
Working Great ...Thanks Mate
[Xiaomi Mi A1 Guides, News, & Discussion] ltf_195:
Didn't work for me, stuck on android logo
[Xiaomi Mi A1 Guides, News, & Discussion] vincenoy:
Confirm work, as per instruction explained. Thanks :good:
[Xiaomi Mi A1 Guides, News, & Discussion] carlox97:
Dont

Dont relock the bootloader or you phone will get brick, if you want to relock it you must go Stock again first and then lock it

---------- Post added at 01:40 AM ---------- Previous post was at 01:39 AM ----------

Is this method working for the MI A1 Global Version?
[Xiaomi Mi A1 Guides, News, & Discussion] marhensa:
OTA says:

couldn't update

installation problem

anyone can't install January OTA here?
[Xiaomi Mi A1 Guides, News, & Discussion] goofball2k:
No, you don't lose anything by rooting your phone.

But you should find a way to back up your stuff on your phone, even if you don't root. I would never entrust anything valuable on my phone without backups.
[Xiaomi Mi A1 Guides, News, & Discussion] Darielazza:
Hey can you help me, yesterday i.just follow to OTA update, but ive got problem here.

My root was gone, when i root again from fastboot, and restart my phone, my root is lost.

Can you help about this problem ? thanks

---------- Post added at 01:57 PM ---------- Previous post was at 01:56 PM ----------

yes i can, but my root was gone :(
[Xiaomi Mi A1 Guides, News, & Discussion] Kunalm007:
Please help
[Xiaomi Mi A1 Guides, News, & Discussion] Kunalm007:
Hello,

I have unlocked bootloader successfully in my Mi A1 and after installing magisk module v5.5.5, I clicked on install then it started installing v15.5 of magisk but in the end I am getting installation failed error msg. Please find screenshot below. And help me as soon as possible.
[Xiaomi Mi A1 Guides, News, & Discussion] lord bim:
I have solved repeating this command: fastboot boot patched_boot.img
[Xiaomi Mi A1 Guides, News, & Discussion] Putra14:
I need stock boot stable january security patch, please give me!
[Xiaomi Mi A1 Guides, News, & Discussion] goofball2k:
Download the fastboot rom and extract it.

Its not really polite to ask someone to get it for you when it's easily accessible to you.
[Xiaomi Mi A1 Guides, News, & Discussion] jcagara08:
THOSE guys got used to being spoonfed...sadly they area also plentiful in your country...
[Xiaomi Mi A1 Guides, News, & Discussion] Leonhart9907:
Can anybody help me?

Im on Android O 8.0 1st December 2017 patch rooted with Magisk 15.2

(i rooted my device using the patched_boot for december method , the one from the "root mia1 oreo without disabling ota updates" thread)

Now im afraid to update to the Jan 2018 OTA

I need a proper instructions.

I need to be very clear on this.

1) Do i need to uninstall all the modules or should i just disable them before i restore stock image from Magisk Manager Uninstall?

2) Do i need to uninstall Xposed if i have it installed?
[Xiaomi Mi A1 Guides, News, & Discussion] Kunalm007:
[MENTION=3023172]goofball2k[/MENTION] can u plz help me with this.?

Please find below screenshot
[Xiaomi Mi A1 Guides, News, & Discussion] amithiel:
Thanks a lot....i just got OREO, flashed magisk 15.1 to avoid bootloop, then flashed 15.3 :cool:
[Xiaomi Mi A1 Guides, News, & Discussion] goofball2k:
Before you do anything, you should remove all magisk modules and reboot. Then what I would do, personally, is then download the fastboot ROM, and use MiFlash to update to the latest (make sure you select Save User Data option in the lower right corner so you don't lose all your data when it flashes).

After that is done, then you can root again with Magisk, you'll need the updated patched boot and you'll need to unlock your bootloader again.

You need to get the updated patched_boot.img, and then boot from the patched_boot.img file (fastboot boot patched_boot.img). Then you can go into Magisk, select Install -> Direct Install.
[Xiaomi Mi A1 Guides, News, & Discussion] Kunalm007:
I have flashed "OPR..... 20180110." Fastboot version of stock Mi A1. Then patched it with Jan boot img. And then installed magisk. But still no changes.
[Xiaomi Mi A1 Guides, News, & Discussion] Passmind:
I've thought about doing this, have you tried it?
[Xiaomi Mi A1 Guides, News, & Discussion] goofball2k:
Yes, multiple times, I do it this way each time there is an OTA.

Did you actually patch it, or did you just boot from the patched boot image? The way I've always done it is to boot using the patched_boot.img (not actually flash the patched boot), then in Magisk Manager selecting the install -> Direct Install and letting MM do the install. After reboot, it should stay rooted.
[Xiaomi Mi A1 Guides, News, & Discussion] Kunalm007:
I have just followed all the steps given above.. but my magisk manager is not installing v15.5 , it's just downloading and boom that error msg :(
[Xiaomi Mi A1 Guides, News, & Discussion] arnabJ:
What does WiFI issue fixed means here:

Stock boot from January update has WiFi issues?
[Xiaomi Mi A1 Guides, News, & Discussion] idx1984:
Hi, I installed magisk still on android 7 and later I realized the update via OTA through the link indicated in the tutorial. I understand it is for any update via ota.

https://github.com/topjohnwu/Magisk/blob/master/docs/tips.md#ota-installation-tips
[Xiaomi Mi A1 Guides, News, & Discussion] Leonhart9907:
Thanks .. but now my problem is. When i restore image from the Magisk Manager Uninstall . It says "Stock Boot does not exist!" . If so .. where is the right directory to place my stock boot.img to??
[Xiaomi Mi A1 Guides, News, & Discussion] Soham Biswas:
When you used fast boot command ..you must have typed fastboot "flash" patched... It should be fastboot "boot" patched..not "flash"..it Should be "boot"...
[Xiaomi Mi A1 Guides, News, & Discussion] idx1984:
This message appeared to me when I removed Magisk and restarted it, it entered bootloop. Are you sure to follow step-by-step commands and direct installation of Magisk? In my case, I repeated the installation procedure for the December and January packages, then I checked the magisk manager, installed the Magisk and it worked, including the recovery of the ROM stock in the uninstall of Magisk to update via OTA.
[Xiaomi Mi A1 Guides, News, & Discussion] goofball2k:
I'm not being asked to install 15.5 anywhere. Maybe change your setting to Stable instead of Beta channel for updates? I'm on beta and I don't get prompted for 15.5.
[Xiaomi Mi A1 Guides, News, & Discussion] iG0tB0lts:
Why do we have to flash a patched boot.img for root in oreo? Also whats been changed in that boot.img provided.

Thanks
[Xiaomi Mi A1 Guides, News, & Discussion] Passmind:
So, I was on the December patch. I went ahead and remove Magisk, and it went into bootloop. So I installed the stock rom and fixed it, however, this locked the bootloader. I went ahead and downloaded January patched img, unlocked bootloader, installed Magisk, asked to update Magisk manager, installed Magisk and rebooted. After that it went to no command error. Any thoughts? (I had to reinstall stock rom to fix it again)
[Xiaomi Mi A1 Guides, News, & Discussion] goofball2k:
Did you just boot from the patched boot image (fastboot boot patched_boot.img), or did you flash it (fastboot flash boot patched_boot.img), then let Magisk do the direct install?

You should be just booting from the patched boot, and not flashing the patched boot image.
[Xiaomi Mi A1 Guides, News, & Discussion] Passmind:
I did boot, and immediately went to Magisk manager 5.5.4. when I run it, it won't show me the option to install Magisk. Only after I update Magisk Manager to 5.5.5 it let me install it. After rebooting it showed the error message.

Update: Tried again and it worked, only this time I installed Magisk Manager 5.5.5.
[Xiaomi Mi A1 Guides, News, & Discussion] Rohit99:
Not able to boot patched_boot.img

[MENTION=7177145]jashancheema[/MENTION] i am not able to boot into patched_boot, i am on latest jan update, it goes into boot loop when i do fastboot boot patched_boot.img
[Xiaomi Mi A1 Guides, News, & Discussion] _mysiak_:
By readings of my crystal ball, you were on Nougat with Magisk and Mi A1 Magisk module which contained modified framework-res.apk (night light). When you upgraded to Oreo, you haven't disable this module and now it's causing boot loop. Is my crystal ball right? :D
[Xiaomi Mi A1 Guides, News, & Discussion] Rohit99:
nope i never installed night light module, your crystal ball reading is wrong.
[Xiaomi Mi A1 Guides, News, & Discussion] abossard:
I have exactly this! You're crystal ball was about me :)

How can I solve it? I'd like to not do a Factory Reset, if avoidable.

Any ideas?
[Xiaomi Mi A1 Guides, News, & Discussion] iG0tB0lts:
I'd suggest booting into twrp and flashing magisk uninstaller.
[Xiaomi Mi A1 Guides, News, & Discussion] _mysiak_:
Install this from TWRP https://xdaforums.com/apps/magisk/module-tool-magisk-manager-recovery-mode-t3693165, then run terminal in TWRP and type "/data/media/mm" and disable modules with on screen instructions. If you don't have working TWRP recovery, this one should be working (don't flash/install it, just boot once) https://xdaforums.com/showpost.php?p=75163475&postcount=747
[Xiaomi Mi A1 Guides, News, & Discussion] SystemDoctor:
Whenever I try to press the Direct Install option from Magisk manager, the latest version of Magisk won't download. I checked my downloads through the Files app and it just stays there as a queued download. Anyone got any ideas as to what's causing this?

EDIT: What if I download the installer.zip seperately and place it on my phone, would that work?
[Xiaomi Mi A1 Guides, News, & Discussion] abossard:
Thank you! That worked! Awesome!
[Xiaomi Mi A1 Guides, News, & Discussion] moxaneat:
i follow the step for the OTA ....uninstall magisk and all but when OTA finish downloading and started step 1, it STILL got "installation problem" ....where could i have done wrong ...i am on oreo with december security update 7.12.19 ....please help
[Xiaomi Mi A1 Guides, News, & Discussion] akikara:
Stuck on "Boot Loop".

I am on latest security update for january. Enabled oem unlocking, usb debugging from developer options.

Here is screen shot of unlock and boot of patched_boot.img

da@xps15z:~/Desktop/ccc$ fastboot devices
no permissions	fastboot
da@xps15z:~/Desktop/ccc$ sudo fastboot devices
[sudo] password for da:
b2edb5	fastboot
da@xps15z:~/Desktop/ccc$ sudo fastboot oem unlock
...
OKAY [ 0.017s]
finished. total time: 0.017s
da@xps15z:~/Desktop/ccc$ sudo fastboot boot patched_boot.img
downloading 'boot.img'...
OKAY [ 0.512s]
booting...
OKAY [ 0.597s]
finished. total time: 1.110s
da@xps15z:~/Desktop/ccc$

I've followed steps. Cable is connected in all steps.

What is wrong? Please help me.
[Xiaomi Mi A1 Guides, News, & Discussion] msmjpr:
reboots to system

after these commands phone reboots to system (fastboot boot patched_boot.img)
[Xiaomi Mi A1 Guides, News, & Discussion] ltf_195:
I'm not sure why, but dont worry happen to me too, try to follow steps below:-
[Xiaomi Mi A1 Guides, News, & Discussion] akikara:
Boot loop happens just after applying fastboot boot patched_recovery.img. Afer power off, I can start my phone.
[Xiaomi Mi A1 Guides, News, & Discussion] flupke70:
After following the instructions to update I still have a problem, the update can't be installed.

I figure it might be caused by my hosts file that has been modified while using the magisk unified ad blocker as well as some tweaks for gcam. What should I do to update and keep all my settings?

I am in December patch + Oreo + magisk 15.3 rooted

Thanks !
[Xiaomi Mi A1 Guides, News, & Discussion] ltf_195:
Download ROM and follow the guide here http://en.miui.com/download-333.html
[Xiaomi Mi A1 Guides, News, & Discussion] flupke70:
Thanks mate, but I don't see the guide you are mentioning

Cheers
[Xiaomi Mi A1 Guides, News, & Discussion] ltf_195:
Click on "Flashing Guide" right beside "Download Full ROM"
[Xiaomi Mi A1 Guides, News, & Discussion] rooties:
i think is just a bit messy

Hello darling,

i read al this BIG THREAD and i find it a bit... MESSY(just a bit...)

Can i ask if u got time, to remake this guide STEP by STEP, with links,

1 to root

2 to unroot

with properly links stock and rooted,

So i think u can forget % of FAILURE PROCESS and have to answer less question, and i can do my root. :)

structure :

Title: Root/Unroot

FILES: link download

Procedure: all the steps
[Xiaomi Mi A1 Guides, News, & Discussion] flupke70:
Thanks a lot mate, worked perfectly !
[Xiaomi Mi A1 Guides, News, & Discussion] Soham Biswas:
Have a question. If i install kernel auditor on the stock rom and change screen saturation. And when i flash the stock rom using mi flash tool ..will i still get ota on the new flashed rom.?
[Xiaomi Mi A1 Guides, News, & Discussion] zorzgeo:
One question:

- Is there any newer update rolled out for A1 than Oreo/January?

TNX
[Xiaomi Mi A1 Guides, News, & Discussion] apache04:
gtfo.
[Xiaomi Mi A1 Guides, News, & Discussion] Jiji_waka:
Can I share this?

Enviado desde mi Mi A1 mediante Tapatalk
[Xiaomi Mi A1 Guides, News, & Discussion] :
Is TWRP included in patched boot.img?
[Xiaomi Mi A1 Guides, News, & Discussion] jashancheema:
Nope
[Xiaomi Mi A1 Guides, News, & Discussion] spdrosin:
Quick question: I want to root my phone for the first time, but I want to do a factory reset too.

Should I root first or the other war round?
[Xiaomi Mi A1 Guides, News, & Discussion] h2aroon:
I also have this same problem. I think patched_boot directly booting system without asking password. Maybe this is causing bootloop.
[Xiaomi Mi A1 Guides, News, & Discussion] :
Then how come do I have TWRP installed on my phone? I haven't flashed TWRP even once. I just flashed patched boot.img because I wanted to preserve OTA.

Now how can I go back to stock recovery?
[Xiaomi Mi A1 Guides, News, & Discussion] :
Did you flash the patched boot.img to the correct slot?

I mentioned the slot to which the patched boot.img should be flashed in the fastboot.

I had slot B active. So I entered in CMD:

fastboot boot_b patched_boot.img
[Xiaomi Mi A1 Guides, News, & Discussion] h2aroon:
I have rooted successfully with one video on YouTube . Maybe first I tried with old fastboot that's why it's got stuck on boot.
[Xiaomi Mi A1 Guides, News, & Discussion] :
The root is unstable for me. Sometimes when I reboot, it says Magisk not installed. After one more reboot, it shows that Magisk is installed. Anyone else having the same problem?

Any workaround for it?
[Xiaomi Mi A1 Guides, News, & Discussion] ronyriawan:
i have oreo installed and root using magisk, when the january security patched release i tried to follow the instruction to install january update patched, the step failed on step 1, it says "couldnt install system update", the i tried to uninstall magisk completly, and try to install january update again but still experiencing this error.

right now i installed back magisk to my oreo, and still waiting how to update to january patched

what should i do?
[Xiaomi Mi A1 Guides, News, & Discussion] sdfkjsdlfkkjdfs2:
You have edited the system files and don't pass safety net.

you can flash a January patch rom, (so you will be updated anyway) and restart from the beginning with unlocking, patching, and rooting your phone.
[Xiaomi Mi A1 Guides, News, & Discussion] urumii12:
I'm having same issue
[Xiaomi Mi A1 Guides, News, & Discussion] maximran:
Ok done rooting success but while installing selinux permissive module its giving me error