[RECOVERY][TWRP]Unofficial TWRP Recovery for Mi A2 - Xiaomi Mi A2 ROMs, Kernels, Recoveries, & Other De

Team Win Recovery Project 3.x, or TWRP3.x for short, is a custom recovery built with ease of use and customization in mind. Its a fully touch driven user interface no more volume rocker or power buttons to mash. The GUI is also fully XML driven and completely theme-able. You can change just about every aspect of the look and feel.
Code:
/*
* Your warranty is now void.
*
* We are not responsible for bricked devices, dead SD cards,
* thermonuclear war, or you getting fired because the alarm app failed. Please
* do some research if you have any concerns about features included in this ROM
* before flashing it! YOU are choosing to make these modifications, and if
* you point the finger at us for messing up your device, we will laugh at you.
*
*/
Download : TWRP For Jasmine
Source Device Tree: Device Tree For Building TWRP

Temporary using guide:
Download this TWRP,
fastboot boot TWRP.img
Flash installer zip
(NEED TWRP 1020 or later)
If you have better way,tell meThanks.

Reserved

is it work >?
TingyiChen said:
Temporary using guide:
Download this TWRP,
fastboot flash boot_b TWRP-3.2.3-jasmine-20180804.img
fastboot set_active b
then reboot and hold Volume Up to boot,you will enter TWRP
Go Back to System:
Activate Slot A at TWRP Reboot Menu and reboot
If you have better way,tell meThanks.
Click to expand...
Click to collapse
WILL THIS COMMAND ( fastboot boot twrp.img) work on this device for only boot into twrp >??

tnmsrkr said:
WILL THIS COMMAND ( fastboot boot twrp.img) work on this device for only boot into twrp >??
Click to expand...
Click to collapse
No,due to some AB special thing,directly fastboot boot twrp.img will cause a reboot on splash screen and brick ur data,only wipe data can enter system again

How can I install Magisk from the TWRP of Slot B in Slot A? When trying to install it detects Slot B and installs it in it.

TheXenons said:
How can I install Magisk from the TWRP of Slot B in Slot A? When trying to install it detects Slot B and installs it in it.
Click to expand...
Click to collapse
There should be a change slots option

I think you need bootctrl package to install TWRP to both slots. Also need to tell which slots are a & b. check any other device with ab slots, like Moto X4.
https://github.com/TeamWin/android_device_motorola_payton

TingyiChen said:
No,due to some AB special thing,directly fastboot boot twrp.img will cause a reboot on splash screen and brick ur data,only wipe data can enter system again
Click to expand...
Click to collapse
Really, I'm assuming A2 A/B is different to OnePlus 6 but what we do is fastboot boot twrp and then flash the official twrp and all is working. A bit weird it's different on A2.

munchy_cool said:
I think you need bootctrl package to install TWRP to both slots. Also need to tell which slots are a & b. check any other device with ab slots, like Moto X4.
https://github.com/TeamWin/android_device_motorola_payton
Click to expand...
Click to collapse
hmm maybe?Cuz I am not familiar with AB now..Still reading documentations...

Anybody has any idea on how to install supersu or magisk?

secosan said:
Anybody has any idea on how to install supersu or magisk?
Click to expand...
Click to collapse
For magisk or supersu you can use patched boot flashable trough fastboot command, with twrp i have really no idea if there are some flashable zip or similar

This recovery done nothing as it was installed on _b rather than _a, so it's not modifying _a partition. and if we flashed it on _a, it will get bootloop/asking to reset data, even we flashed lazypatcher. And our device get bootloop to on _b partition.
You can use this to root, just flash it on boot_a. It was made by magisk manager with patch boot image method. You still need to install magisk manager to get root.
Don't install magisk xposed or you will facing bootloop/asking to reset data. If that happen and you don't want to lose your data, flash twrp from this thread to boot_a, use magisk recovery manager to uninstall xposed module, and then flash magisk boot from me again to boot_a. reboot afterwards.
Magisk boot image on 9.6.9.0.ODIMIFE : https://drive.google.com/file/d/1sMFjQVLvj_cX_tht7-woSQQ4YlCF_i4i/view?usp=sharing

grzpra said:
This recovery done nothing as it was installed on _b rather than _a, so it's not modifying _a partition. and if we flashed it on _a, it will get bootloop/asking to reset data, even we flashed lazypatcher. And our device get bootloop to on _b partition.
You can use this to root, just flash it on boot_a. It was made by magisk manager with patch boot image method. You still need to install magisk manager to get root.
Don't install magisk xposed or you will facing bootloop/asking to reset data. If that happen and you don't want to lose your data, flash twrp from this thread to boot_a, use magisk recovery manager to uninstall xposed module, and then flash magisk boot from me again to boot_a. reboot afterwards.
Magisk boot image : https://drive.google.com/file/d/1sMFjQVLvj_cX_tht7-woSQQ4YlCF_i4i/view?usp=sharing
Click to expand...
Click to collapse
Which version of ROM do I need to have to flash the patched boot.img? Also, are the modules working?

emperor8696 said:
Which version of ROM do I need to have to flash the patched boot.img? Also, are the modules working?
Click to expand...
Click to collapse
my rom ver is 9.6.9.0.ODIMIFE, and the modules is working.

When should we expect official?

grzpra said:
Magisk boot image on 9.6.9.0.ODIMIFE : https://drive.google.com/file/d/1sMFjQVLvj_cX_tht7-woSQQ4YlCF_i4i/view?usp=sharing
Click to expand...
Click to collapse
Thank you, you saved my day. My Mi A2 (Global) finally has Root.
I tried with the howtos from the internet and installing different Magisk zip files through TWRP, nothing worked.
Is it possible to get a Magisk 16.7 boot image?

Roi Danton said:
Is it possible to get a Magisk 16.7 boot image?
Click to expand...
Click to collapse
I got it myself. With your image (from a older stock ROM) wifi did not work anymore.
If someone is interested, I got a patched boot.img from stock ROM V9.6.10.0.ODIMIFE and Magisk 16.7.

Roi Danton said:
Thank you, you saved my day. My Mi A2 (Global) finally has Root.
I tried with the howtos from the internet and installing different Magisk zip files through TWRP, nothing worked.
Is it possible to get a Magisk 16.7 boot image?
Click to expand...
Click to collapse
If your rom is updated, i can't. As mine were Mi6x not A2, but it work with cross flashing with a little modification (don't know if it from A2 to Mi6x).
You can patch it yourself with magisk manager, copy the boot image from fastboot rom to your phone, in magisk manager you need to choose install and then select patch boot image. You need to be on "unroot" condition, just flash the original boot.img rom first with fastboot.

grzpra said:
If your rom is updated, i can't. As mine were Mi6x not A2, but it work with cross flashing with a little modification (don't know if it from A2 to Mi6x).
You can patch it yourself with magisk manager, copy the boot image from fastboot rom to your phone, in magisk manager you need to choose install and then select patch boot image. You need to be on "unroot" condition, just flash the original boot.img rom first with fastboot.
Click to expand...
Click to collapse
Thank you. As I wrote here I have a patched boot.img for stock ROM V9.6.10.0.ODIMIFE and Magisk 16.7 - which works pretty good. With your boot.img I had the problem that wifi did not work anymore.
If someone needs the patched boot.img, get in contact with me.

Related

[GUIDE] Rooting your Essential PH-1

WARNING: Before attempting to root your device, do note that by unlocking your bootloader and modifying your device with root, ROMs, etc... you are 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.
Useful and important general information can be found in the second post here.
NOTES
1. If you flash the TWRP Installer when you've already got Magisk installed, your device will keep booting to the recovery. You should be able to fix this by just simply reflashing Magisk.
2. If you have TWRP installed via the TWRP Installer, you will not be able to install stock OTA updates. You will have to reflash the stock boot image for whatever build you're running beforehand.
3. The prebuilt TWRP image may not have touch functionality if you're using the September 2018 Update or newer. Patching the boot image, however, for these builds with the TWRP Installer will allow touch to work flawlessly. Here is a pre-patched September 2018 Boot Image with TWRP. It should also work with builds newer than September. Since it's based off the September 2018 update, I suggest not using this as your main boot image but rather just as a replacement for the pre-built TWRP image from the official TWRP thread.
4. Simple "flash and forget" boot images pre-patched with Magisk and TWRP are provided by @aer0zer0 and are available here. They are based on ianmacd's variant of Magisk. If you are running stock, you can flash these boot images to get root and TWRP instead of following the guide to patch it yourself. Here is January's.
If you don't care about TWRP and simply want to just root your device, you can just simply patch the boot image for your ROM with the Magisk Manager and flash it in fastboot with
Code:
fastboot flash boot patched_boot.img
The link to the boot images for most stock builds can be grabbed from my Google Drive link in the second post or from the back-to-stock zips.
REQUIREMENTS
An unlocked bootloader
Working adb and fastboot environment, along with knowledge on how they work.
The latest build of TWRP along with the TWRP Installer. Read Note 3 above beforehand.
1. Download the latest build of TWRP and the TWRP Installer. Transfer the TWRP Installer zip to your device.
2. Reboot your phone into fastboot. Once in fastboot, change your device's current slot using the command
Code:
fastboot set_active other
If the command above doesn't work for you, use fastboot getvar current-slot followed by fastboot -aX, replacing "X" with the slot opposite (a or b) from your current slot.
3. Once your device's current slot has been switched, flash the TWRP image you downloaded earlier using the command
Code:
fastboot flash boot twrp.img
Depending on your version of fastboot, the above command might not work either. In that case, you can enter the following command, replacing "X" with your current slot (a or b).
Code:
fastboot flash boot_X twrp.img
4. Once TWRP has been flashed, boot into the recovery.
5. Once you have booted into TWRP, simply flash the TWRP Installer zip.
6. Once you have finished flashing the TWRP Installer zip, boot to recovery on the OPPOSITE slot. You can do this from TWRP by going to "Reboot", then selecting the opposite of the current slot (if on A, select Slot B. If on B, select Slot A), then select "Recovery." You can also do this through fastboot by running the same command from step 2.
7. Once you have booted back into TWRP, simply flash the Magisk zip and you are now good to go! Feel free to flash anything else like kernels while you're at it.
8. Reboot. :good:
NOTE: TWRP WILL remain installed on your device so long as you reflash the installer zip after every update.
Important Information for the Essential PH-1 can be found here. Keep it bookmarked.
Tips on updating via OTA after rooting can be found here.
In the case that you mess something up on your device, you may find it helpful to revert back to stock with the unofficial factory images graciously provided by @invisiblek and @aer0zer0 over here.
Official TWRP XDA Thread for the Essential PH-1
Join the Essential PH-1 Discord Server! -- Lots of cool people here!
Join the Essential PH-1 Development Telegram Channel!
Stock Boot Images for most builds can be found at my Google Drive link here.
Have a Red Verity Warning when booting your device? Click here.
If the link to the boot.fix.red image isn't working, you can also find it here or in my Google Drive link in the first post.
Essential Phone (PH-1) Partition Layout
Dumping Boot Images
1. Find the current slot with
Code:
fastboot getvar current-slot
or
Code:
adb shell getprop ro.boot.slot_suffix
2. Switch to the opposite slot in Fastboot using the command
Code:
fastboot set_active other
3. Flash TWRP using the command
Code:
fastboot flash boot twrp.img
4. Now, boot into TWRP and use the following command from your PC, replacing X in "boot_X" with the original slot from step 1 (a or b). TRIPLE CHECK:
Code:
adb shell dd if=/dev/block/bootdevice/by-name/boot_X of=/sdcard/boot.img
5. Profit! Don't forget to switch back to the original partition with the same command from step 2!
extractTarFork() error when restoring data from a TWRP backup
1. Reinstall the ROM from which the backup is based on.
2. Wipe your data. You can do this from the recovery or from fastboot using the command
Code:
fastboot -w
3. Boot into the ROM. When going through the initial setup, use the EXACT same security setup as the one from your backup. For example, if you used a Fingerprint + Password in the backed up ROM, use the exact same combo along with the exact same password as well. There is no need to set up anything else, like accounts.
4. Flash, install, and reboot into TWRP. You should now be able to restore the data backup without any issues.
AFH mirrors for images:
Build NMJ32F
NMJ32F patched boot image
NMJ32F factory image
Build NMJ20D
NMJ20D patched boot image
NMJ20D factory image
TWRP (alpha v4)
Thanks for getting the latest boot image up so quickly.
Thanks for the detailed guide, it worked great!
Any idea how to install xposed sdk 25? I tried the adb sideload function and the Magsik Module but both failed. Any ideas?
how to install the NMJ32F ota update when you are already rooted on NMJ20D?
Tried adb sideload but cannot install obviously because boot-loader is unlocked and is rooted.
prgopala said:
how to install the NMJ32F ota update when you are already rooted on NMJ20D?
Tried adb sideload but cannot install obviously because boot-loader is unlocked and is rooted.
Click to expand...
Click to collapse
You need to flash the system and boot images from Invisiblek's stock ROM dump. You'll then be unrooted and will be able to accept the update.
Factory reset no longer required if your bootloader is already unlocked? Does TWRP read encypted storage now? Or is that still a problem?
@bmg1001 , good looks, here are more free XDA points to trade in for that pool table, lol.
gk1984 said:
Factory reset no longer required if your bootloader is already unlocked? Does TWRP read encypted storage now? Or is that still a problem?
Click to expand...
Click to collapse
As far as I know, TWRP still doesn't have decryption fully working just yet, but installing Magisk works fine without any factory resets.
prozo said:
Thanks for the detailed guide, it worked great!
Any idea how to install xposed sdk 25? I tried the adb sideload function and the Magsik Module but both failed. Any ideas?
Click to expand...
Click to collapse
Xposed works fine for me. Make sure you installed the correct Xposed Installer/Manager apk linked in the thread for the Xposed Module. Also, it may take a reboot or two for Xposed to fully activate.
Did anyone manage to disable encryption? I tried everything and failed
bmg1001 said:
Xposed works fine for me. Make sure you installed the correct Xposed Installer/Manager apk linked in the thread for the Xposed Module. Also, it may take a reboot or two for Xposed to fully activate.
Click to expand...
Click to collapse
Maybe I'm not gathering the information correctly, using the Magisk Module itself doesn't work, sideloading the zip file via the adb fastboot TWRP.img doesn't work either, using the actual Xposed APK installer doesn't work either. I rebooted the phone about 4 times before removing it entirely.
Any chance you can walk me through how you got it installed without the TWRP recovery fully installed?
prozo said:
Maybe I'm not gathering the information correctly, using the Magisk Module itself doesn't work, sideloading the zip file via the adb fastboot TWRP.img doesn't work either, using the actual Xposed APK installer doesn't work either. I rebooted the phone about 4 times before removing it entirely.
Any chance you can walk me through how you got it installed without the TWRP recovery fully installed?
Click to expand...
Click to collapse
All I did was install the Xposed APK and then the Xposed Magisk Module. After two reboots, the apk said everything was working. This is the apk I used: https://drive.google.com/file/d/16-OHpswcngp1KLtkWCBDwwl8AvFafR5H/view?usp=drivesdk
bmg1001 said:
All I did was install the Xposed APK and then the Xposed Magisk Module. After two reboots, everything was working. This is the apk I used: https://drive.google.com/file/d/16-OHpswcngp1KLtkWCBDwwl8AvFafR5H/view?usp=drivesdk
Click to expand...
Click to collapse
Thanks for replying so quickly I appreciate it, the file you linked keeps opening on my end and fails to install saying it's corrupt
prozo said:
Thanks for replying so quickly I appreciate it, the file you linked keeps opening on my end and fails to install saying it's corrupt
Click to expand...
Click to collapse
The apk should be the same one found here: https://forum.xda-developers.com/xposed/unofficial-systemless-xposed-t3388268
bmg1001 said:
All I did was install the Xposed APK and then the Xposed Magisk Module. After two reboots, the apk said everything was working. This is the apk I used: https://drive.google.com/file/d/16-OHpswcngp1KLtkWCBDwwl8AvFafR5H/view?usp=drivesdk
Click to expand...
Click to collapse
Alright I got it to work
So I didn't use the APK instead I downloaded the zip from the XDA thread that is specifically for Magisk Module and then added via the modules tab on the left side of the Magisk Module APK.
After I restarted I had the newly installed APK to download and install the proper version of Xposed 88.2 sdk25
Another restart and boom I got the active module notification in green.
Thanks man!
Thread for downloads can be found here:
https://www.google.com/amp/s/forum....ed/unofficial-systemless-xposed-t3388268/amp/
Thank you for this!
My PH-1 is arriving today. SooOoo excited!
spotmark said:
You need to flash the system and boot images from Invisiblek's stock ROM dump. You'll then be unrooted and will be able to accept the update.
Click to expand...
Click to collapse
Would using flashfire work to install the ota?
drocny87 said:
Would using flashfire work to install the ota?
Click to expand...
Click to collapse
Couldn't tell you. I just used TWRP to flash the system and boot, and then took the update, and then rerooted.

[Guide] How to Install TWRP & Root Essential PH-1(Method 2)

How to Install TWRP Recovery & Root Essential PH-1 (Windows/Mac/Linux)​​​
This is an alternate method on how install TWRP. This one might give you a better understanding of slots.
Another method can be found at below link. Use whatever is easier for you.
https://forum.xda-developers.com/essential-phone/how-to/guide-rooting-essential-ph-1-magisk-t3701976
Warning 1: If you can't do fastboot commands, do a flash all, root your device or flash TWRP/ROM, please do not ask for help here. If you cannot flash all back to stock, please stay stock for everyone's sake.
Warning 2: You might loose all your data. Make sure to backup your data.
Code:
/*
* Your warranty is now void.
*
* I am not responsible for bricked devices, dead SD cards,
* thermonuclear war, or you getting fired because the alarm app failed. Please
* do some research if you have any concerns about features included in this ROM
* before flashing it! YOU are choosing to make these modifications, and if
* you point the finger at me for messing up your device, I will laugh at you.
*/
Pre-Requisites
Make sure you have unlocked the bootloader.
Download and Install drivers (Windows) :- https://storage.googleapis.com/essential-static/Essential-PH1-WindowsDrivers.exe
Make sure to remove pin/password/pattern etc. Even though TWRP support decryption I personally suggest you remove it and can add it back later.
Make sure you are stock. If you are rooted, please install stock boot.img.
How to Boot into fastboot/bootloader mode
1. Reboot phone, and keep volume down pressed while device is rebooting until you see bootloader mode screen.
2. While phone is off, press volume down and then press power button. Keep holding both until you see bootloader mode screen.
How to Install
Steps
1. Download all the files listed in downloads section and place them inside one folder say ph-1.
2. Unzip fastboot and adb zip file (platform-tools). Rename twrp image file to twrp-mata.img. move twrp img file to platform-tools folder.
3. Connect phone to computer and copy below files to internal memory.
* TWRP Installer Zip
* Magisk Zip
Reboot device into bootloader mode.
4. Using command prompt/terminal navigate to folder where fastboot is.
Command Prompt
Code:
fastboot devices
Mac/Linux/Powershell
Code:
./fastboot devices
Make sure device is detected in fastboot mode.
5. Find current slot. Note this down some where.
Command Prompt
Code:
fastboot getvar current-slot
Mac/Linux/Powershell
Code:
./fastboot getvar current-slot
6. If you get current slot as
* A - we will flash twrp to slot B
* B - we will flash twrp to slot A
7. Flash TWRP to slot opposite of what we found out in Step 5.
Command Prompt
Code:
fastboot flash boot_slot twrp-mata.img
Mac/Linux/Powershell
Code:
./fastboot flash boot_slot twrp-mata.img
So, if your current slot was a, you will use boot_b above. If current slot was b, you will use boot_a above.
8. Set slot where we flashed TWRP as active.
Command Prompt
Code:
fastboot --set-active=slot
Mac/Linux/Powershell
Code:
./fastboot --set-active=slot
So, if your current slot was a, you will use --set-active=b above. If current slot was b, you will use --set-active=a above.
9. Use volume rockers till you see recovery option. Then press power button to select. You should now boot into TWRP.
If the touchscreen doesn't function, skip to instructions in post 2 below.
Now, flash TWRP installer zip file.
Once zip is flashed and has patched both slots. Go back to home screen.
Reboot.
On this screen select the slot which we had noted down in step 5.
Then reboot into system. You should now boot into Android.
10. To root. Boot back into bootloader mode. Go into TWRP recovery. Flash magisk zip. reboot.
Support :
1) Search. Search, search, search. If you make the effort of reading atleast 5 pages back, most if not all your questions will be answered. I personally, will ignore any questions, if I know they have been answered in the last 5 pages. Not being rude, but please read.
2) If you can't find answers in last 5 pages, ask here, be respectful and have a good time.
Video Guide
Downloads :
Latest ADB & Fastboot Zip File :- https://developer.android.com/studio/releases/platform-tools
TWRP for Essential Phone (need both .img and zip file) :- https://forum.xda-developers.com/es...official-twrp-3-2-3-0-essential-ph-1-t3840931
Magisk :- https://forum.xda-developers.com/apps/magisk/official-magisk-v7-universal-systemless-t3473445
Going Back to Stock :- https://forum.xda-developers.com/essential-phone/development/stock-7-1-1-nmj20d-t3701681
If you flashed September Android 9.0 Pie Back to Stock (BTS) it flashes to both slots. In that case, if touch is not working please refer post 2.
Credits
@Dees_Troy for TWRP
@aer0zer0 for back to stock (BTS)
@topjohnwu for Magisk
@munchy_cool for this guide
reserved
Common Issues
Thanks to @starcms for helping with the instructions.
No touch in TWRP in Step 9.
Keep your phone connected to computer. Open command prompt/terminal/powershell.
Now we are going to install TWRP installer zip.
Command Pormpt
Code:
adb shell twrp install path/to/zip
So, let's say you have twrp installer zip (named
twrp-installer-mata-3.2.3-0.zip) in root of internal memory.
Code:
adb shell twrp install /sdcard/
twrp-installer-mata-3.2.3-0.zip
This should flash TWRP to both slots. Now, you can reboot using
Code:
adb reboot bootloader
and go back into TWRP. Check if touch is working and then set your slot to one noted in step 5.
If touch is not working use fastboot (step 8) to change the slot to that noted in Step 5..
Now boot back into TWRP using volume rockers and proceed to Step 10 (flashing Magisk zip)
Terminal/Powershell users please add ./ before the adb.
reserved 002
reserved 002
Nice write-up. I would also maybe add (to your discretion ofc) that if you flash the latest P BTS, it flashes to both slots, making touch unusable in twrp and will need to follow your addendum.
aer0zer0 said:
Nice write-up. I would also maybe add (to your discretion ofc) that if you flash the latest P BTS, it flashes to both slots, making touch unusable in twrp and will need to follow your addendum.
Click to expand...
Click to collapse
Done. Thanks for the advice :highfive:
Uh I...have a new problem. I use "adb shell twrp install" to install twrp-installer-mata-3.2.3-0.zip and it seem to work...but later I flash the stockboot and flash magisk. Than I cant boot into the system. It reboot itself to the stock recovery when it finished booted. And told me cant start up the system and two options down below "try again" "factory reset"
Is my stockboot file is incorrect?
YunolexDDP said:
Uh I...have a new problem. I use "adb shell twrp install" to install twrp-installer-mata-3.2.3-0.zip and it seem to work...but later I flash the stockboot and flash magisk. Than I cant boot into the system. It reboot itself to the stock recovery when it finished booted. And told me cant start up the system and two options down below "try again" "factory reset"
Is my stockboot file is incorrect?
Click to expand...
Click to collapse
recovery is part of boot image. if you flash stock boot, twrp is removed.
munchy_cool said:
recovery is part of boot image. if you flash stock boot, twrp is removed.
Click to expand...
Click to collapse
Yeah i know but now i wonder where goes wrong with my phone
Seem my English is not very good so....I dont know how to search the key word
So..I wonder if you have seem this situation before.
YunolexDDP said:
Yeah i know but now i wonder where goes wrong with my phone
Seem my English is not very good so....I dont know how to search the key word
So..I wonder if you have seem this situation before.
Click to expand...
Click to collapse
after installing twrp zip, if you instal stock boot or new kernel it will remove twrp.
you have to flash twrp zip after installing new kernel.
to root, boot into android once after instalinh twrp zip.
then boot back into twrp, and flash magisk zip.
munchy_cool said:
after installing twrp zip, if you instal stock boot or new kernel it will remove twrp.
you have to flash twrp zip after installing new kernel.
to root, boot into android once after instalinh twrp zip.
then boot back into twrp, and flash magisk zip.
Click to expand...
Click to collapse
I am pretty close it. Now i have my twrp install in one slot and the system can boot from another slot but uh..
do I need to flash stock boot before I flash magisk?
cus now I still cant boot the system from twrp..
the official website said "use the devices as normal" hmm..
I need to change the slot if i want to boot the system. Is that normal?
YunolexDDP said:
I am pretty close it. Now i have my twrp install in one slot and the system can boot from another slot but uh..
do I need to flash stock boot before I flash magisk?
cus now I still cant boot the system from twrp..
the official website said "use the devices as normal" hmm..
I need to change the slot if i want to boot the system. Is that normal?
Click to expand...
Click to collapse
NO you don't need to flash stock boot to instal Magisk.
yes, you need to change slot to boot system.
all of this is mentioned in first post.
i have a question, is there a way to just boot into TWRP to just flash magisk? without flashing TWRP itself? i want to recive OTAs still and all i want is just magisk installed, i tried the ,ethod of patching the boot.img but that was a huge fail please help!!!
DeimosPhobos said:
i have a question, is there a way to just boot into TWRP to just flash magisk? without flashing TWRP itself? i want to recive OTAs still and all i want is just magisk installed, i tried the ,ethod of patching the boot.img but that was a huge fail please help!!!
Click to expand...
Click to collapse
No.
We don't have fastboot boot
aer0zer0 said:
No.
We don't have fastboot boot
Click to expand...
Click to collapse
Ahhhh ok,
I figured out the patched boot image method, although when I tried to make my own patched boot IMG, it didn't work, I found a Reddit thread where someone had done it, I used theirs and it worked....although the command was supposed to be fastboot flash boot patched_boot.img and Everytime I did that it sent it to B, but failed on the write, they yelled at me saying that's the command and it should work lol, but I had to actually put fastboot flash boot_b patched_boot.img....the damn A/B partition stuff confuses me Alot lol
DeimosPhobos said:
Ahhhh ok,
I figured out the patched boot image method, although when I tried to make my own patched boot IMG, it didn't work, I found a Reddit thread where someone had done it, I used theirs and it worked....although the command was supposed to be fastboot flash boot patched_boot.img and Everytime I did that it sent it to B, but failed on the write, they yelled at me saying that's the command and it should work lol, but I had to actually put fastboot flash boot_b patched_boot.img....the damn A/B partition stuff confuses me Alot lol
Click to expand...
Click to collapse
sometimes older fastboot versions dont work well with Essential.
for ab slots, if you are want to flash magisk pre-rooted boot.img
just do
fastboot gervar current-slot (say you get a)
and then flash boot.img to current slot.
fastboot flash boot_a nameofboot.img
munchy_cool said:
sometimes older fastboot versions dont work well with Essential.
for ab slots, if you are want to flash magisk pre-rooted boot.img
just do
fastboot gervar current-slot (say you get a)
and then flash boot.img to current slot.
fastboot flash boot_a nameofboot.img
Click to expand...
Click to collapse
essential's driver package for windows doesnt require _a,_b unless you are being specific
fastboot flash boot whatever will work and flash to the current slot if your using essentials (which is an older version) if your using a newer version from google or minimal, it gives the __a or b error trying to append an extra underscore
aer0zer0 said:
essential's driver package for windows doesnt require _a,_b unless you are being specific
fastboot flash boot whatever will work and flash to the current slot if your using essentials (which is an older version) if your using a newer version from google or minimal, it gives the __a or b error trying to append an extra underscore
Click to expand...
Click to collapse
true, but not everyone is on Windows :highfive:
munchy_cool said:
true, but not everyone is on Windows :highfive:
Click to expand...
Click to collapse
Poor Linux folks ?
aer0zer0 said:
Poor Linux folks
Click to expand...
Click to collapse
lol.
Essential is the only phone to give me issues with fastboot though.
munchy_cool said:
lol.
Essential is the only phone to give me issues with fastboot though.
Click to expand...
Click to collapse
Tell me about it, lol.
---------- Post added at 12:00 PM ---------- Previous post was at 11:46 AM ----------
aer0zer0 said:
Tell me about it, lol.
Click to expand...
Click to collapse
Never seen a phone so finicky. I've also got the holy Grail cable that I don't let out of my sight. I've often wondered what makes it so finicky, and I come from a long line of HTC and motos

Guide for installing TWRP on OOS 11 Open Beta(Upto closed release 11)

Backup first, that's a must as always.
If coming from OOS 10 base -
1. Flash OOS 11 OB1/hotfix, after its completion do not reboot
2. Install official/unofficial twrp recovery image to ramdisk from advance menu in TWRP
3. Reboot to recovery
4.a. install magisk(optional) and reboot
4.b. repeat 1 and 2, reboot again then, 4.a.
If already on OOS 11 OB1/hotfix-
1. Flash the attached boot.img from bootloader
2. Reboot to recovery from bootloader itself(booting to system at this point will result in bootloop)
3. Follow the process as mentioned for OOS 10
Thx to Soft_M for boot image
NOTE: Above method is not compatible with OB2
OB2,OB3, closed release users directly flash official latest TWRP zip
NOTE: Installing TWRP on OB3 with any given method will cause safety net to fail
man thanks, that saved me from a bootloop from magisk...
Does this work with the HOTFIX build for OB1?
sw1tchback said:
Does this work with the HOTFIX build for OB1?
Click to expand...
Click to collapse
Yes it does, actually I tested this method on hotfix
Whats your widevine status on OOS11? Mine is l3 on unlocked bootloader.
parthrathore said:
Whats your widevine status on OOS11? Mine is l3 on unlocked bootloader.
Click to expand...
Click to collapse
For unlocked bootloader, l3 always
So you have tested official TWRP 3.5.2-9.0 on OOS Open Beta 2 and it works fine? Interesting
CrysisLTU said:
So you have tested official TWRP 3.5.2-9.0 on OOS Open Beta 2 and it works fine? Interesting
Click to expand...
Click to collapse
I confirm
I flashed oos beta2 and try to boot into twrp image through bootloader.but got to crushdump screen
What do I need to do on Beta 2 to get magisk and twrp installed? Currently none of them installed, magisk patched boot.img causes loop
romanuks said:
What do I need to do on Beta 2 to get magisk and twrp installed? Currently none of them installed, magisk patched boot.img causes loop
Click to expand...
Click to collapse
you can follow these steps:
1. install magisk app
2. boot patched boot img with magisk from another thread https://forum.xda-developers.com/t/...beta-1-for-oneplus-6-6t.4304161/post-85408313 through bootloader
3. patch boot image via magisk(if magisk ask you to allow reboot when you first time open it,don't allow it).
4. reboot your phone.you are good to go.
megaslx said:
you can follow these steps:
1. install magisk app
2. boot patched boot img with magisk from another thread https://forum.xda-developers.com/t/...beta-1-for-oneplus-6-6t.4304161/post-85408313 through bootloader
3. patch boot image via magisk(if magisk ask you to allow reboot when you first time open it,don't allow it).
4. reboot your phone.you are good to go.
Click to expand...
Click to collapse
Patching magisk from bootloader leads me to a bootloop though
megaslx said:
you can follow these steps:
1. install magisk app
2. boot patched boot img with magisk from another thread https://forum.xda-developers.com/t/...beta-1-for-oneplus-6-6t.4304161/post-85408313 through bootloader
3. patch boot image via magisk(if magisk ask you to allow reboot when you first time open it,don't allow it).
4. reboot your phone.you are good to go.
Click to expand...
Click to collapse
flash the above attached image and reboot to recovery directly, then follow the given procedure
voske15 said:
flash the above attached image and reboot to recovery directly, then follow the given procedure
Click to expand...
Click to collapse
so,on ob2 and 3, the pure twrp img will boot into crush dump,but patched boot partition won't?
megaslx said:
so,on ob2 and 3, the pure twrp img will boot into crush dump,but patched boot partition won't?
Click to expand...
Click to collapse
After testing it out, seems that is the case
edit: deleted
I had OB3 than I tried to "fastboot boot" latest TWRP to use PixelExperience. I got the QUALCOM message.
So I did the stupid thing to "fastboot flash boot" the latest TWRP. Now I'm bricked.
I will try to flash this one and see what happens. I was trying @mauronofrio unbrick guide, but it goes only until 10.3.8.
Julianocas said:
I had OB3 than I tried to "fastboot boot" latest TWRP to use PixelExperience. I got the QUALCOM message.
So I did the stupid thing to "fastboot flash boot" the latest TWRP. Now I'm bricked.
I will try to flash this one and see what happens. I was trying @mauronofrio unbrick guide, but it goes only until 10.3.8.
Click to expand...
Click to collapse
It worked. I've manage to get into TWRP and flash the stock O11. Thanks.
any actual guide to get twrp working on B3?
TheUndertaker21 said:
any actual guide to get twrp working on B3?
Click to expand...
Click to collapse
Just use FKM to flash a twrp and magisk. it should freakinglish work.

LZMA (Elementalx), TWRP, Magisk -> change LOS 18.1 recovery to TWRP in order to get root access,

So, backround is, I want to use AFWall+, which requires root, which I would like to use Magisk for.
In order to get Magisk I need TWRP, I learned so far.
I run LOS 18.1 and I used the lineage recovery/fastboot to flash it (according to the offical LOS-guide).
Changing the recovery is not the easiest thing for me.
Found this thread: https://forum.xda-developers.com/t/from-lineage-recovery-to-twrp-recovery.4253669/
but this seems to be very Samsung specific using Odin (I use a Pixel 4)
I also tried this guide: https://www.droidwin.com/boot-into-recovery-from-fastboot-mode/
but this just "deleted" my OS.
This is why I will be asking a few questions prior starting a new attempt, so please bear with my incompetence
At TWRP I read, I have to install a LZMA ramdisk kernel in order to get TWRP (https://twrp.me/google/googlepixel4.html).
I would go for elementalx, assuming it does support lzma.
From here things are getting tricky for me.
TWRPs guide tells me to get the kernel first, at Elementalx I get the instructions to use TWRP to install
It does say however its not neccessary to install TWRP permanently, but I would like to, because no matter what I want to do with my phone it requires TWRP. So I would like to change the recovery permanently.
The easiest way to do all of this seems to be this guide: https://elementalx.org/how-to-install/
But that will not change my recovery permanently...
What I would do (using a videoguide, because you know, I'm a noobish newbie):
1. Download TWRP img + zip, Magisk zip, Elementalx zip to my fastboot folder
2. Copy the Zips of TWRP, Magisk and Elementalx to my device
3. On my PC -> in the fastboot folder I run cmd as administrator
4. boot into bootloader
5. using cmd -> fastboot boot twrp.img
6. using TWRP -> flash the custom kernel
7. using TWRP -> flash TWRP
8. check if TWRP was proper installed: in TWRP -> boot -> recovery
hopefully the recovery was replaced
9. using TWRP - > flash Magisk
10. reboot
Would anyone please tell me if this will work?
Is there anything I need to do to avoid horrible things to happen?
This is not a request to blame something that could happen on someone afterwards. I just want to minimize the risk...
You can just flash the kernel from fastboot no twrp needed. Just fastboot flash boot boot.img.
You can have magisk patch a boot image then flash it from fastboot as mentioned above.
Usually its just recommended to fastboot boot twrp.img instead of flashing it to the actual device incase you want to revert back and install an OTA.
You can also just download the magisk apk from the device to patch the boot image, flash kernel from fastboot, then reboot with root and have magisk finish doing what it needs to do.
Thank you.
TWRP got stuck booting: I see the logo, "teamwin" and the version used 3.5.2_10-0
Everything was up to date, I'll try it again with an older version of TWRP.
Well, I dont know how to boot into LOS. It just froze on the mentioned screen.
Has anyone a idea what to do?
CodyF86 said:
You can just flash the kernel from fastboot no twrp needed. Just fastboot flash boot boot.img.
You can have magisk patch a boot image then flash it from fastboot as mentioned above.
Usually its just recommended to fastboot boot twrp.img instead of flashing it to the actual device incase you want to revert back and install an OTA.
You can also just download the magisk apk from the device to patch the boot image, flash kernel from fastboot, then reboot with root and have magisk finish doing what it needs to do.
Click to expand...
Click to collapse
Ok, I tried it my way - it wont work (of course). Maybe TWRP is still not supported for Android 11.
Now I'll try it your way (thx again).
In order to flash the kernel, I'll have to unzip the elementalx file, I assume. And boot the avaible image, which is called "dtbo.img".
I'll give this a go...
CodyF86 said:
You can just flash the kernel from fastboot no twrp needed. Just fastboot flash boot boot.img.
You can have magisk patch a boot image then flash it from fastboot as mentioned above.
Usually its just recommended to fastboot boot twrp.img instead of flashing it to the actual device incase you want to revert back and install an OTA.
You can also just download the magisk apk from the device to patch the boot image, flash kernel from fastboot, then reboot with root and have magisk finish doing what it needs to do.
Click to expand...
Click to collapse
fastboot flash boot boot.img did not work. I renamed the file to boot.img (did not mention this before).
Tried it twice, but nothing worked afterwards, not even recovery and I was not able to turn the device off.
Had to flash LOS again.
I also tried flashing the kernel using sideload while flashing the rom again.
Sideload did work, BUT the wifi was not working at all.
I dont want to bother you, but might there be another way?
I might have found something:
[VERY EASY GUIDE] ADB/FASTBOOT/RECOVORY *FULL GUIDE* for flashing ROMs, Kernels, APKs
Keep in mind bootloader unlock will not work if you have done the latest OTA update without previously using supercid. See bootloader unlock guide below for more details. This procedure is designed to be EXTREMELY EASY and for people using...
forum.xda-developers.com
uppon2 said:
That is all. Keep in mind things like wifi might not work if you forget to flash the kernel modules! - Just be sure it is always a 2 step process.
Click to expand...
Click to collapse
This is what I am experiencing when using sideload. It does install the kernel, but wifi wont work. I guess I do need a working (permanently or temporarly) recovery.
caraman said:
I might have found something:
[VERY EASY GUIDE] ADB/FASTBOOT/RECOVORY *FULL GUIDE* for flashing ROMs, Kernels, APKs
Keep in mind bootloader unlock will not work if you have done the latest OTA update without previously using supercid. See bootloader unlock guide below for more details. This procedure is designed to be EXTREMELY EASY and for people using...
forum.xda-developers.com
This is what I am experiencing when using sideload. It does install the kernel, but wifi wont work. I guess I do need a working (permanently or temporarly) recovery.
Click to expand...
Click to collapse
Wifi is usually a kernel module that gets loaded through an init script on boot. It's possible to build the wifi module built-in to the kernel, which makes it so it doesn't have to load separately through an init script.
So if youre not using the stock kernel you'd have to ask whoever makes the kernel you are using.
caraman said:
So, backround is, I want to use AFWall+, which requires root, which I would like to use Magisk for.
In order to get Magisk I need TWRP, I learned so far.
I run LOS 18.1 and I used the lineage recovery/fastboot to flash it (according to the offical LOS-guide).
Changing the recovery is not the easiest thing for me.
Found this thread: https://forum.xda-developers.com/t/from-lineage-recovery-to-twrp-recovery.4253669/
but this seems to be very Samsung specific using Odin (I use a Pixel 4)
I also tried this guide: https://www.droidwin.com/boot-into-recovery-from-fastboot-mode/
but this just "deleted" my OS.
This is why I will be asking a few questions prior starting a new attempt, so please bear with my incompetence
At TWRP I read, I have to install a LZMA ramdisk kernel in order to get TWRP (https://twrp.me/google/googlepixel4.html).
I would go for elementalx, assuming it does support lzma.
From here things are getting tricky for me.
TWRPs guide tells me to get the kernel first, at Elementalx I get the instructions to use TWRP to install
It does say however its not neccessary to install TWRP permanently, but I would like to, because no matter what I want to do with my phone it requires TWRP. So I would like to change the recovery permanently.
The easiest way to do all of this seems to be this guide: https://elementalx.org/how-to-install/
But that will not change my recovery permanently...
What I would do (using a videoguide, because you know, I'm a noobish newbie):
1. Download TWRP img + zip, Magisk zip, Elementalx zip to my fastboot folder
2. Copy the Zips of TWRP, Magisk and Elementalx to my device
3. On my PC -> in the fastboot folder I run cmd as administrator
4. boot into bootloader
5. using cmd -> fastboot boot twrp.img
6. using TWRP -> flash the custom kernel
7. using TWRP -> flash TWRP
8. check if TWRP was proper installed: in TWRP -> boot -> recovery
hopefully the recovery was replaced
9. using TWRP - > flash Magisk
10. reboot
Would anyone please tell me if this will work?
Is there anything I need to do to avoid horrible things to happen?
This is not a request to blame something that could happen on someone afterwards. I just want to minimize the risk...
Click to expand...
Click to collapse
Magisk should not be that complicated. All the hard work has been done and can be found in Magisk documentation. There are install instructions for just about any type device and if there is LOS for your device I'm sure it is covered. The latest Magisk is not TWRP flashable the same way as it used to be and newer devices often don't have ramdisk in boot image and root is achieved thru recovery instead. You referenced several threads and guides but no indication of Magisk instructions. Read the Magisk installation instructions for your device type, they're not just suggestions, they work.

[Help!] Can't root my OnePlus 7 Pro

Hi,
with the latest Magisk update I noticed the missing Magisk Hide and SafetyNet fix. So I decided to go back to Magisk 23. After a few unsuccessful attempts, I don't know what happened but now my phone is no longer rooted. So I tried some usual methods to re-root the device but nothing to do, still no root
I have used boot.img patching way with Magisk but when I send ADB command "fastboot flash boot magisk_patched.img", it seems to work fine but after reboot there is no root
So I tried the other method by booting the device with patched boot.img using ADB ("fastboot boot magisk_patched.img") then I open Magisk Manager but in the installation section there is no "direct install" option as it should be.
I also tried flashing Magisk.zip via TWRP as I did long ago and TWRP seems to do the job well but after rebooting again no root...
Any suggestions?
even though you don't have root, i suggest flashing the stock boot.img and then rebooting to be really sure that root has been removed. and then flash the magisk patched boot.img.
are you using the latest adb and fastboot? you can get the latest from here. https://developer.android.com/studio/releases/platform-tools
fyi, i just updated to magisk 24.1 and enabled zygisk. i'm using @kdrag0n's universal safetynet fix. google pay works. i don't have any other apps that i need to hide magisk from.
altwu said:
fyi, i just updated to magisk 24.1 and enabled zygisk. i'm using @kdrag0n's universal safetynet fix. google pay works. i don't have any other apps that i need to hide magisk from.
Click to expand...
Click to collapse
How did you get this to work? I am on the latest OP7P OOS (11.0.5), and I haven't been able to get my phone rooted, even though I installed the boot.img I patched using Magisk v24.1.
¿GotJazz? said:
How did you get this to work? I am on the latest OP7P OOS (11.0.5), and I haven't been able to get my phone rooted, even though I installed the boot.img I patched using Magisk v24.1.
Click to expand...
Click to collapse
i'm running 11.0.5.1.GM21AA. i was already rooted with magisk v23, so i updated the magisk app to 24.1, and did a direct install to update root to 24.1.
but for any os upgrades, i download the firmware zip from my phone to my pc before installing. i extract the boot.img from the zip with payload dumper, patch it with magisk, and then flash it via fastboot. this way i know for sure that i'm using the correct boot.img. if you need the firmware zip to extract the boot.img from, you can use the oxygen updater app to download it.
did you use the stock boot.img for patching?
altwu said:
i'm running 11.0.5.1.GM21AA. i was already rooted with magisk v23, so i updated the magisk app to 24.1, and did a direct install to update root to 24.1.
but for any os upgrades, i download the firmware zip from my phone to my pc before installing. i extract the boot.img from the zip with payload dumper, patch it with magisk, and then flash it via fastboot. this way i know for sure that i'm using the correct boot.img. if you need the firmware zip to extract the boot.img from, you can use the oxygen updater app to download it.
did you use the stock boot.img for patching?
Click to expand...
Click to collapse
Yes, I used the stock boot.img that I extracted from the 11.0.5.1 file that was downloaded as the normal OTA update from OnePlus. I patched that boot image with Magisk v24.1 that was already installed on my OP7P.
Then, I flashed that Magisk patched boot.img using fastboot onto both A and B slots (I switched slots by booting into TWRP 3.6, since I didn't see a way to switch slots with the now-loaded OnePlus Recovery Mode).
When I rebooted through the patched image, the phone came up (which is good!), but Magisk says that I don't have root (which is bad!). I haven't figured out how to fix that.
Could you PM me your patched boot.img? I could try flashing that to see if my OP7P acts any differently.
Thanks!
OK, I'm 100% positive that Magisk v24.1 patched my OP7P OOS 11.0.5.1 boot.img properly.
I extracted the 11.0.5.1 boot.img file from the OTA image that was in my .Ota folder from my phone. I extracted boot.img from the payload.bin file using two different methods of payload-dumper. Both boot.img files had the same SHA-512 checksums, so they were identical.
I also downloaded a copy of the Magisk v24.1 patched boot.img from the intenet and compared it to my Magisk v24.1 patched boot.img file. Again, the SHA-512 checksums matched for the two patched files, so I am sure that I have a properly patched boot.img file.
Note that my OP7P has loaded the full OOS 11.0.5.1 Stock image, so I currently have the OOS Recovery Mode and I do not have TWRP Recovery Mode.
Maybe I am doing something else wrong during my installation that is keeping me from getting root?
Here is the process I followed with my patched boot.img file:
I boot into Fastboot Mode
In Fastboot Mode, I go into TWRP Recovery Mode by typing: fastboot boot twrp-3.6.0_11-0-guacamole.img
After rebooting into TWRP Recovery, I installed the 11.0.5.1 OTA by doing an Install > Browse to the .Ota folder for the OTA .Zip file.
After the OOS 11.5.0.1 OTA installed, I rebooted back to Fastboot Mode (before booting normally) by selecting: Reboot > Slot A > Home > Reboot > Bootloader
Once I am back into Fastboot Mode, I type: fastboot flash boot magisk_patched_boot.img
In Fastboot Mode, I type: fastboot reboot
After I have rebooted back to normal mode, Magisk v24.1 is already installed and I don't do any updates to that. When opening Magisk, my screen flashes a couple of times before giving me a Toast pop-up that Magisk was denied Super User access. When I look at the Magisk App screen, it says that the App is installed, but that Magisk is not installed.
Are there any steps that I am missing?
Well, I finally got OOS 11.0.5.1 rooted with Magisk v24.1.
I ended up wiping my data and installing a fresh install of OOS 11.0.5.1 (Not sure if this is necessary, but I skrood up along the way and had to wipe as a result).
The one thing that was different this time around was that I disabled encryption/lock before flashing the Magisk-v24.1 patched boot image. I suspect that was what helped me make it to the finish line this time.
Good luck out there!
¿GJ?
i'm glad to hear that you got it figured out. sorry for not responding sooner with a patched boot image.
i don't use twrp, so my method of upgrading and patching is different than yours.
my only guess as to why you were having trouble before is maybe you were flashing the magisk patched boot image to the wrong slot. if you run into a similar problem in the future, you can try flashing the magisk patched boot image to both slots. but it's a moot point now. enjoy your finally rooted phone!
altwu said:
i'm glad to hear that you got it figured out. sorry for not responding sooner with a patched boot image.
i don't use twrp, so my method of upgrading and patching is different than yours.
my only guess as to why you were having trouble before is maybe you were flashing the magisk patched boot image to the wrong slot. if you run into a similar problem in the future, you can try flashing the magisk patched boot image to both slots. but it's a moot point now. enjoy your finally rooted phone!
Click to expand...
Click to collapse
Hey, @altwu - I used TWRP to switch between slots when flashing the Magisk patched boot images. I had patched both slots (as best as I could tell)
If you don't use TWRP, how did you switch between slots prior to flashing the patched boot images?
¿GotJazz? said:
Hey, @altwu - I used TWRP to switch between slots when flashing the Magisk patched boot images. I had patched both slots (as best as I could tell)
If you don't use TWRP, how did you switch between slots prior to flashing the patched boot images?
Click to expand...
Click to collapse
you can use fastboot to switch slots.
fastboot --set-active=a or b
i don't know if it's necessary, but i reboot the bootloader with "fastboot reboot bootloader" after switching slots.
i've never tried this, but you can also specify what slot when running fastboot flash, like "fastboot flash boot magisk_patched.img --slot a".
check out "fastboot help" to see the different options.
i haven't had to play around with slots though. when an update is available, i'll download the zip to a computer and then go through the normal update process via the os. after the update is done, the phone reboots and the correct active slot is set.
Thanks for the feedback, @altwu.
I am having issues getting my SMS notification sound working on my fresh(er) 11.0.5.1 installation. I haven't seen anybody respond back yet, and I am beginning to suspect it's just a problem on my OP7P. If I don't see anybody responding back by tomorrow, I'll assume it's "just me".
I am thinking about doing a total wipe again to see if it will clear up the issue I am seeing. I will end up trying your installation route this time to see if it helps at all.

Categories

Resources