After rooting G9+ & installing an unofficial LineageOS 18.1, root was lost & need help getting it back - Moto G9 Plus Questions & Answers

I decided to upgrade to the G9+ after finding a LineageOS ROM for the phone. Root via TWRP & Magisk worked without a hitch. Then I installed the LineageOS 18.1 ROM from here: https://www.getdroidtips.com/lineage-os-18-1-moto-g9-plus/
Next I went to install GApps via the Aroma setup, but found that TWRP was gone. There was some limited recovery from the ROM installation which didn't seem to be of any use, so I reflashed TWRP & then Magisk, but I didn't get root back.
The phone now has a working version of LineageOS, but I can't even get the Google crap I need.
When I try to flash something via TWRP I get an error saying there was a "Zip signature verification failure", so I can't even get back to stock ROM to try again. (I guess this error is related to not having root.)
(I installed TWRP & Magisk on another G9+ with stock ROM and everything seems as expected. The phone is rooted. I just want to get rid off all the Google software I can.)
Anyone got an idea how I can get root back?
------
And any reason why "ADB devices" doesn't list the attached phone? "Fastboot devices" works fine.

Have u tested lineage, is
everything working fine?

UsmanQ said:
Have u tested lineage, is
everything working fine?
Click to expand...
Click to collapse
Everything seems to be there, seems normal. Except root.

doktorspin said:
Everything seems to be there, seems normal. Except root.
Click to expand...
Click to collapse
doktorspin said:
Everything seems to be there, seems normal. Except root.
Click to expand...
Click to collapse
Have u tried superoot or something else instead of magisk?

Sapper Morton said:
The ROM that you're using is not meant to be daily driven, Erfan compiled that for experimental purposes, but that aside, there's a few things that you should take in consideration when using Lineage; It's not meant to be used with TWRP, that's why they ship their own recovery (Lineage Recovery). It's still possible to flash custom files with it (That doesn't match their original signature), you just need to skip a warning.
For Magisk, download the latest stable build from here: Download
(The .apk has the flashing script built-in, so just rename that to .zip).
One major difference from TWRP, is that Lineage Recovery doesn't support decrypting userdata, so the files must be flashed using ADB or USB OTG.
Use ADB Sideload as follows:adb sideload magisk.zip
As for me, I didn't unlocked my device yet, so if you could confirm me something: I need to know if I will lose my DRM certification, used for Netflix, Disney+, Prime Video and such.
Download Castro from Play Store, go to the DRM tab, and check the Widevine status, tell me if it remains L1, or if it downgraded to L3. That's what's holding me back from testing, or even compiling for this device.
Click to expand...
Click to collapse
Thanks for the response.
1. I'm using the Github Magisk 23.
2. Lineage Recovery is gone. I reflashed TWRP.
3. Attempting to use "ADB sideload Magisk-v23.0.zip" ADB responds "cannot read 'Magisk-v23.0.zip'"
4. I haven't got Play Store on the phone as I can't flash the aroma package (1.7GB) via TWRP.

UsmanQ said:
Have u tried superoot or something else instead of magisk?
Click to expand...
Click to collapse
I don't know anything about the other methods for getting root. I've always used Magisk.
(I'm working under the idea that as TWRP + Magisk works fine on one phone, they aren't the problem.)

Sapper Morton said:
The idea is to rollback to Lineage Recovery, you can even flash only the boot.img that it's inside the ROM flashable file, instead of reflashing the whole thing again. It's probably in payload.bin format, so you'll need a payload firmware extractor (Easily found on GitHub), in case you choose the first option.
• Aroma is not supported on Lineage Recovery, so I would recommend something smaller, like OpenGapps nano or stock.
Click to expand...
Click to collapse
<rant>
What sort of idiots build in a crap recovery when one has obviously already installed a functional recovery, needed in the process of gaining root and installing LineasgeOS? This unnecessary included recovery wasn't in previous versions of LOS I've used.
Yes, this is an unpleasant surprise and I'm ticked off. I'm an end user who wants a relatively de-Googled phone, but now to maybe get a functional recovery I have to extract stuff from a payload file, but to do that I have to install more crud so that I can run the tool that does the extracting.
And I need Aroma to be able to select what I must have from Google. My partner needs their voice tech. I could dump almost everything else and use Pico. </rant> Sorry.
Is there no way to wipe the slate clean, get rid of this Lineage, and start again?
(I don't understand how installing their recovery could ruin the functionality of another recovery.)

Sapper Morton said:
Download Castro from Play Store, go to the DRM tab, and check the Widevine status, tell me if it remains L1, or if it downgraded to L3. That's what's holding me back from testing, or even compiling for this device.
Click to expand...
Click to collapse
On the second G9+ which I rooted but left the stock ROM, I installed Castro and it indicates L3.

doktorspin said:
I decided to upgrade to the G9+ after finding a LineageOS ROM for the phone. Root via TWRP & Magisk worked without a hitch. Then I installed the LineageOS 18.1 ROM from here: https://www.getdroidtips.com/lineage-os-18-1-moto-g9-plus/
Next I went to install GApps via the Aroma setup, but found that TWRP was gone. There was some limited recovery from the ROM installation which didn't seem to be of any use, so I reflashed TWRP & then Magisk, but I didn't get root back.
The phone now has a working version of LineageOS, but I can't even get the Google crap I need.
When I try to flash something via TWRP I get an error saying there was a "Zip signature verification failure", so I can't even get back to stock ROM to try again. (I guess this error is related to not having root.)
(I installed TWRP & Magisk on another G9+ with stock ROM and everything seems as expected. The phone is rooted. I just want to get rid off all the Google software I can.)
Anyone got an idea how I can get root back?
------
And any reason why "ADB devices" doesn't list the attached phone? "Fastboot devices" works fine.
Click to expand...
Click to collapse
take a look at this group of telegram, here they can help you to return
Lolinet [English Only]
Our website: MIRRORS.LOLINET.COM Our channel: https://t.me/lolinetnews Please speak in English
t.me
Lineage is working fine, some details that will be fixed when releasing the new kernel

There is a method to root with magisk by patching the ramdisk its a way better rooting method then with twrp in fact magisk dev recommends this way of rooting if you have not tried this here is a magisk official link https://topjohnwu.github.io/Magisk/install.html
Hope This helped you bro

The ROM in the O.P. works.​
Folks, I actually made a number of mistakes in this process.
The major one was to muff the fastboot command for flashing TWRP. I had followed instructions which said to boot TWRP, which didn't install TWRP, just loaded it into phone memory. But...
The ROM cited in the O.P. doesn't seem to have any problems that I have noticed in my usage, which is basically as a hand computer, not as a phone.
LineageOS now overwrites recovery with its own recovery, which is pretty moronic, because the user has already had to install a recovery to root the device.
But fortunately, if you have your ADB/fastboot apps handy with TWRP in the same folder it's an easy fix.
You should already have this stuff, but use the following software:
sebastian3367HD has provided TWRP for G9+ users onsight here. I'll assume it's called "twrp.img".
Magisk-v23 here -- put it somewhere easy on your phone.
Also get GApps 11. I used core NikGapps here, select latest date, then the version of GApps you want. (The core version 82MB just gives you Play Store & support software.) Put it the same place on the phone you put Magisk.
Assuming you've flashed the O.P. LineageOS ROM, which overwrites trusty TWRP, put your phone in fastboot mode, either using
1. power button + volume down
until you get the droid image on its back, or get there with your phone on, sending
2. adb reboot bootloader
via the windows command shell.
You're now in fastboot mode. You can now flash TWRP back onto the phone. Note that the phone has two slots of memory, so that the phone can hold two operating systems. If you send
fastboot flash recovery twrp.img
it will be flashed to the current slot, either A or B. To be safe you should flash both:
fastboot flash recovery_a twrp.img
fastboot flash recovery_b twrp.img
That gives you the safety of having TWRP in both slots. (Incidentally, TWRP allows you to changes slots.) (Also remember if you reflash LineageOS you'll have to put TWRP back on if you want a decent recovery program.)
Use TRWP to Reboot to Recovery.
Now install Magisk using TWRP:
Spoiler: (You know this)
a) choose Install
b) if the bottom right button says Install Zip press it and it will change to Install Image
c) if you put Magisk on your external SD card Select Storage to choose the SD
d) find and select Magisk-v23.0.apk, then
e) swipe to flash.
Then install GApps, basically the same as for Magisk.
Reboot to System. You should be rooted now and should have Play Store (and whatever else you opted for).

M.Akram said:
There is a method to root with magisk by patching the ramdisk its a way better rooting method then with twrp in fact magisk dev recommends this way of rooting if you have not tried this here is a magisk official link https://topjohnwu.github.io/Magisk/install.html
Hope This helped you bro
Click to expand...
Click to collapse
Thanks for the info. My problem was simple to fix, using the right commands!

I haven't installed that rom because afaik the source tree isn't available anywhere which seems kind of fishy, if anyone knows where they are please let us know

Related

[Recovery][BKL][EMUI 8.x][Unofficial]TWRP 3.2.1-0 working recovery from View 10

Backup your stock recovery per this post. If you are too lazy, I can upload my backup from .104 build (C432) to Mega.
Download twrp_bkl_0.7.img from this post and place it in same directory with your ADB.
After successful backup as precaution disable any locks like pattern/PIN/password/fingerprint, reboot to bootloader (fastboot):
Code:
adb reboot bootloader
Then flash new TWRP recovery:
Code:
fastboot flash recovery_ramdisk twrp_bkl_0.7.img
After successful flash reboot device and immediately after confirming command below unplug USB cable and HOLD and keep holding VOLUME UP button, if you won't the new recovery will be overwritten by stock and you can try again.
Code:
fastboot reboot
Tested by myself on Honor 10 8.1.0.104 (C432) with unlocked bootloader and installed already Magisk 16.4 with Magisk manager 5.7.0, Magisk ramdisk persisted after installing TWRP recovery, system boots normal.
Next step after unlocking BL, installing Magisk, installing TWRP recovery -> flashing GSI AOSP, LOS or RR. Only reason I bothered with installing TWRP was that GSI image of LOS and RR don't include opengapps, only AOSP does, so without TWRP you can't have opengapps with these two GSI ROMS.
PeterMarkoff said:
Backup your stock recovery per this post. If you are too lazy, I can upload my backup from .104 build (C432) to Mega.
Download twrp_bkl_0.7.img from this post and place it in same directory with your ADB.
After successful backup as precaution disable any locks like pattern/PIN/password/fingerprint, reboot to bootloader (fastboot):
Code:
adb reboot bootloader
Then flash new TWRP recovery:
Code:
fastboot flash recovery_ramdisk twrp_bkl_0.7.img
After successful flash reboot device and immediately after confirming command below unplug USB cable and HOLD and keep holding VOLUME UP button, if you won't the new recovery will be overwritten by stock and you can try again.
Code:
fastboot reboot
Tested by myself on Honor 10 8.1.0.104 (C432) with unlocked bootloader and installed already Magisk 16.4 with Magisk manager 5.7.0, Magisk ramdisk persisted after installing TWRP recovery, system boots normal.
Next step after unlocking BL, installing Magisk, installing TWRP recovery -> flashing GSI AOSP, LOS or RR. Only reason I bothered with installing TWRP was that GSI image of LOS and RR don't include opengapps, only AOSP does, so without TWRP you can't have opengapps with these two GSI ROMS.
Click to expand...
Click to collapse
Nice work. ?
tried to install GSI RR OS, but ending in bootloop, also even after resizing system partition to maximum (TWRP / wipe / resize) opengapps still showing error 70 about insufficient space (which makes no sense, so they really seem to have wrong detection of A/B instead of A for Huawei/Honor devices), though these gzr gapps seem to install successfuly, now if I could figure out the damn bootloop
potential reasons for bootloop - previously installed magisk, wiped also system not only data/cache, installed through fastboot while TWRP there and not only stock recovery, ???
edit: i guess will try flash GSI through TWRP again, quite a waste time to wait each time like 9-10 minutes to find out it can't boot
edit 2: so even flashing through TWRP doesn't help, just stuck on android animation for 10 minutes and then it restarts (and even if you do fatory reset through huawei erecovery it doesnt change anything). maybe can try to restore everything and not wipe system before installing, just factory reset through TWRP (though I remember I read somewhere it's not reliable and it is better to do it through system, but I think that one wipe also internal storage which I wanna avoid)? back to rooted EMUI with TWRP for now, don't have time to try various combinations
edit 3: flashing over TWRP backup without wiping system doesn't help, so it seem it's gonna be magisk or replaced stock recovery i guess, otherwise no idea
BTW the lack of feedback here and trying from other users it's very depressing. they boasted million phone sales and i am the only one in the whole world trying to install TWRP and GSI ROM on this phone?
PeterMarkoff said:
BTW the lack of feedback here and trying from other users it's very depressing. they boasted million phone sales and i am the only one in the whole world trying to install TWRP and GSI ROM on this phone?
Click to expand...
Click to collapse
Don't be disappointed the lack of feedback from users is not many power users have got their hands on this model.
And also we are having different builds.
From the day one I am trying to rebrand my device but no success .
Once I have rebranded to EU I will try and let you know.
Did you flash open gapps nano package through twrp in gsi image?
Did it give you the same error?
tried just pico opengapps as on all phones i flash, that's the smallest, but always end up with error 70 not enough space despite resized system partition in TWRP and many GB available, the other unofficial GZR zero gapps build i mentioned seem to be flashed successful in TWRP, but in any case no luck with booting
PeterMarkoff said:
tried just pico opengapps as on all phones i flash, that's the smallest, but always end up with error 70 not enough space despite resized system partition in TWRP and many GB available, the other unofficial GZR zero gapps build i mentioned seem to be flashed successful in TWRP, but in any case no luck with booting
Click to expand...
Click to collapse
Did you format your phone before trying GSI ?
Try formatting phone and remove some system apps and then flash gapps it will mostly solve the problem.
PeterMarkoff said:
BTW the lack of feedback here and trying from other users it's very depressing. they boasted million phone sales and i am the only one in the whole world trying to install TWRP and GSI ROM on this phone?
Click to expand...
Click to collapse
Don't be upset – e.g. I didn't receive my Honor 10 yet. You won't be the only one for sure, you're just the first one to do it, which is super nice for others because it motivates them to do so as well!
Just wondering: does it make a difference for TWRP wether I own the 6gb or 4gb version?
miststudent2011 said:
Did you format your phone before trying GSI ?
Try formatting phone and remove some system apps and then flash gapps it will mostly solve the problem.
Click to expand...
Click to collapse
I did factory reset (data, both cache) and also wiped system partition, gapps would be the least issue, as I said that GZR should work, but my system doesn't boot, no matter how times I wipe everything through TWRP or stock recovery after flashing system.img, since they say it's normal to hang at first boot and then wipe and then it should boot, but it doesn't work for me. also of course tried to power off phone since some people said it helps to do it after flashing. what I haven't done it's fastboot -w which should be some better wipe. some people say also you should remove magisk ramdisk, though I forgot to back up original, backed up just stock recovery. and also I haven't tried to flash everything with stock recovery, though first flash I did was through fastboot anyway and not through TWRP and it didn't make difference
so last few things left to try:
- fastboot -w for total wipe of data (better than TWRP? though it should be same as Format data in TWRP which wipe everything including internal storage which I wanna avoid since backing up 15GB TWRP backup file it's kinda annoying and my system has problem to do it)
- flash with stock recovery (I have backup, no big deal)
- remove magisk ramdisk and flash with stock ramdisk (forgot to make backup, can't replace)
though I am tired of it for now, spend last night like 4 hours dealing with it until 2AM and I also need to take care of children
vollkornbaguette said:
Don't be upset – e.g. I didn't receive my Honor 10 yet. You won't be the only one for sure, you're just the first one to do it, which is super nice for others because it motivates them to do so as well!
Just wondering: does it make a difference for TWRP wether I own the 6gb or 4gb version?
Click to expand...
Click to collapse
I don't think RAM has something to do with anything, but that sounds like Chinese version since EU has always 4GB and only difference is storage, so you will have different ROM
PeterMarkoff said:
(...)
so last few things left to try:
- fastboot -w for total wipe of data (better than TWRP?)
- flash with stock recovery (I have backup, no big deal)
- remove magisk ramdisk and flash with stock ramdisk (forgot to make backup, can't replace)
Click to expand...
Click to collapse
So I just read more about the GSI/Treble stuff and it said somewhere that modifications like Magisk probably lead to problems with the GSI flash.
Which is why I would try to get rid of the magisk ramdisk first.
I'm not an expert in this at all but maybe this helps.
---
PeterMarkoff said:
I don't think RAM has something to do with anything, but that sounds like Chinese version since EU has always 4GB and only difference is storage, so you will have different ROM
Click to expand...
Click to collapse
Indeed I bought the chinese 6gb RAM Version (hope this won't turn out as a big mistake)
vollkornbaguette said:
So I just read more about the GSI/Treble stuff and it said somewhere that modifications like Magisk probably lead to problems with the GSI flash.
"Your device is free of any heavy modifications such as the
Click to expand...
Click to collapse
yeah, now if someone could extract for me from 0.104 firmware for C432 that stock ramdisk, because I have some problems with mega to download it and I just need the stock ramdisk, nothing else, I have stock recovery backup but forgot to make ramdisk backup
edit: completely forgot there is option to "Completely uninstall" in Magisk manager, so tried it though even after restart with magisk manager missing i could still use root apps, so not sure how exactly this "complete uninstall" works, but anyway giving it a try after this and wiping data, installed system.img again, again wiped, rebooted and as usual loading and loading and nothing, seem can't further continue without copy of stock ramdisk to flash, tried downloading the big update from mega to extract it but it always fail for me to download, same with trying to copy my TWRP backup because for sure ain't gonna doi fastboot -w and setting up everything from scratch in case even this doesn't help, if I knew it works for sure and it will load new system which I will have to set up then no problem, but in this case...
edit 2: tried to replace magisk ramdisk with ramdisk from Honor View 10 BKL09 (same as our working TWRP) but it seem I end up after flashing it, wiping and flashing system.img in TWRP/erecovery bootloop, it's not showing android booting logo like before (but hey at least no need to wait 10 minutes to find it's fail) and either go to huawei ercovery, if I perform factory reset there then it boots to TWRP, but can't boot anywhere else besides these two
pass
I requested this image. Recovery has been established. When I enter the recovery, it requires a password to decrypt the system partition, I enter it (the same after switching on the phone), but a message is displayed that the password is incorrect. help me please.
told you in OP disable all passwords before flashing
PeterMarkoff said:
yeah, now if someone could extract for me from 0.104 firmware for C432 that stock ramdisk, because I have some problems with mega to download it and I just need the stock ramdisk, nothing else, I have stock recovery backup but forgot to make ramdisk backup
edit: completely forgot there is option to "Completely uninstall" in Magisk manager, so tried it though even after restart with magisk manager missing i could still use root apps, so not sure how exactly this "complete uninstall" works, but anyway giving it a try after this and wiping data, installed system.img again, again wiped, rebooted and as usual loading and loading and nothing, seem can't further continue without copy of stock ramdisk to flash, tried downloading the big update from mega to extract it but it always fail for me to download, same with trying to copy my TWRP backup because for sure ain't gonna doi fastboot -w and setting up everything from scratch in case even this doesn't help, if I knew it works for sure and it will load new system which I will have to set up then no problem, but in this case...
edit 2: tried to replace magisk ramdisk with ramdisk from Honor View 10 BKL09 (same as our working TWRP) but it seem I end up after flashing it, wiping and flashing system.img in TWRP/erecovery bootloop, it's not showing android booting logo like before (but hey at least no need to wait 10 minutes to find it's fail) and either go to huawei ercovery, if I perform factory reset there then it boots to TWRP, but can't boot anywhere else besides these two
Click to expand...
Click to collapse
If you want, i have all the files of the C432 update but idk in wich .zip, folder the ramdisk is stored.
I can send on several clouds.
PeterMarkoff said:
told you in OP disable all passwords before flashing
Click to expand...
Click to collapse
Hey did you restore your device are you still struck at boot screen?
If yes try this method.
https://forum.xda-developers.com/huawei-p20/development/rebrand-huawei-p20-eml-l29-eml-l09-t3779283
How to GO back to stock emui(India) after i flash a treble rom? Do i need to backup using some tool?
PLease someone tell me
srharshajava said:
PLease someone tell me
Click to expand...
Click to collapse
The problem is currently we don't have full
ROM to revert to stock and if we brick our device there is no proper way to revert to stock.
Our model even doesn't have SD card support.
Just wait for some time for someone to provide proper way.
When i flash a treble rom, I have a bootloop. I returned back with eRecovery directly on the phone.
miststudent2011 said:
The problem is currently we don't have full
ROM to revert to stock and if we brick our device there is no proper way to revert to stock.
Our model even doesn't have SD card support.
Just wait for some time for someone to provide proper way.
Click to expand...
Click to collapse
We do have a way to download full ROM.
http://pro-teammt.ru/firmware-database/?firmware_model=COL-L29C432
1. Search here for your exact model (change numbers after C432 to find ROM for your phone) and search for your rom version (B104 or B120)
2. Double click on "filelist" on the same row as FullOTA-MF
3. From filelist link menu download update.zip file (it should be really big, like 2+GB)
3. Extract UPDATE.APP file somewhere (eg. Desktop)
4. In settings of HuaweiUpdateExtractor (link: https://forum.xda-developers.com/showthread.php?t=2433454) uncheck "verify header checksum" and open UPDATE.APP
5. Extract any img (Be it ramdisk.img, ramdisk_recovery.img or system.img) file that you need from UPDATE.APP via HuaweiUpdateExtractor
You just got whoole stock rom and img files that you can flash. Tested by myself with flashing back original ramdisk, ramdisk_recovery and system.img and everything worked well.

Help with Treble ROMs

I have the PRA-LX1 with already unlocked bootloader and got it rooted with TWRP + Magisk before the last OTA.
I'm not a beginner with rooting this phone but only got Problems with installing any Treble Rom (tried Lineage and Aosp) and every try ended with a bootloop I don't know what I'm doing wrong.
So please can anyone give me a step by step instruction?
Which Treble Rom is a good one and recommended for this phone?
Which TWRP do I need?
And how exactly do I flash them correctly? What do I wipe?
Sorry for this noob questions but I failed so many times with Treble and don't want to do the reinstall with erecovery for the 10000 time :crying:
Thanks
Try to install the stock recovery and ramdisk.
+1
I also have this problem. Wich TWRP works with treble roms? i tryed everything and everytime i get a boot loop.
Please help.
After I flashed a treble gsi, I need to flash stock recovery?
Atiqx said:
After I flashed a treble gsi, I need to flash stock recovery?
Click to expand...
Click to collapse
Yes. if u still get bootloop flash stock recovery and ramdisk first then flash gsi. make sure u factory reset on stock recovery after u flash gsi.
ppdr07 said:
Try to install the stock recovery and ramdisk.
Click to expand...
Click to collapse
ppdr07 said:
Yes. if u still get bootloop flash stock recovery and ramdisk first then flash gsi. make sure u factory reset on stock recovery after u flash gsi.
Click to expand...
Click to collapse
And which TWRP should I use for flashing?.. And how can I flash GSI with stock?
That makes no sense to me sorry
Flash via fsstboot. Stock recovery and ramdisk flash via fastboot. Im not using twrp so idk.
---------- Post added at 08:38 AM ---------- Previous post was at 08:37 AM ----------
U can see a tutorial at xda how to flash gsi without twrp. Google it.
ppdr07 said:
Flash via fsstboot. Stock recovery and ramdisk flash via fastboot. Im not using twrp so idk.
---------- Post added at 08:38 AM ---------- Previous post was at 08:37 AM ----------
U can see a tutorial at xda how to flash gsi without twrp. Google it.
Click to expand...
Click to collapse
I googled it, pretty much every source says that you require a custom recovery in order to flash a GSI or any custom ROM.
XDA XILFY said:
I googled it, pretty much every source says that you require a custom recovery in order to flash a GSI or any custom ROM.
Click to expand...
Click to collapse
https://www.xda-developers.com/flash-generic-system-image-project-treble-device/ u will find Flash GSI without TWRP
ppdr07 said:
https://www.xda-developers.com/flash-generic-system-image-project-treble-device/ u will find Flash GSI without TWRP
Click to expand...
Click to collapse
Oh, well that's pretty cool. Either way, I just tried flashing Official Resurrection Remix GSI with no luck. Stock recovery, attempted to flash through fastboot and it just gives me a bootloop, exactly like TWRP does. Followed the guide you linked to etc, just keeps rebooting.
XDA XILFY said:
Oh, well that's pretty cool. Either way, I just tried flashing Official Resurrection Remix GSI with no luck. Stock recovery, attempted to flash through fastboot and it just gives me a bootloop, exactly like TWRP does. Followed the guide you linked to etc, just keeps rebooting.
Click to expand...
Click to collapse
Go to openkirin.net/download download the rr beta 3
Atiqx said:
I have the PRA-LX1 with already unlocked bootloader and got it rooted with TWRP + Magisk before the last OTA.
I'm not a beginner with rooting this phone but only got Problems with installing any Treble Rom (tried Lineage and Aosp) and every try ended with a bootloop I don't know what I'm doing wrong.
So please can anyone give me a step by step instruction?
Which Treble Rom is a good one and recommended for this phone?
Which TWRP do I need?
And how exactly do I flash them correctly? What do I wipe?
Sorry for this noob questions but I failed so many times with Treble and don't want to do the reinstall with erecovery for the 10000 time :crying:
Thanks
Click to expand...
Click to collapse
Well, I finally got it all working.
You know the risks, don't blame me if something goes wrong, I did these exact steps to manage to root my phone without breaking it. C432, Dual SIM and PRA-LX1.
Have everything stock before following this short guide: Firmware, all stock recovery etc.
Installing the ROM and GApps
First, download necessary GSI files.
(Personally I got Official Oreo Resurrection Remix, here).
(Although you could find yourself using virtually any other GSI, I like the look and feel of RR, though I'll be changing my boot animation with root). Many people would probably recommend you to use something like an AOSP, or LOS which I was also considering on installing. They may also come bundled with GApps, which would negate the later need for installation or download of separate GApps.
This may include GAPPS but you should understand this from the GSI page, so for example on RR I had to download both the latest base ROM .img and the micro GApps.
So to do this I had to use the right architecture (For the P8 Lite 2017, this is ARMx64, do your good research, since my problem was getting this wrong with my PRA-LX1 (Mine was A-ONLY), this stands for the base ROM and GApps.
After this I actually didn't use TWRP as user @ppdr07 advised. I followed the guide he linked us to and did as so, without following the -u command, since it wasn't working for me (didn't affect anything, try it, if it doesn't work, just take that bit out).
The ROM ended up installing and posting through, everything set up perfectly.
After this I was like "Huh, so what now? How am I to flash GApps on this without TWRP?". I went for it and booted into fastboot where I flashed Askuccio's TWRP for hi6250 devices. At this point I worried that the ROM wouldn't post again - though it did, so from there I enabled dev options and switched on advanced power options just for ease of usage. From there I rebooted straight to recovery which posted fine, too.
At this point, you need to flash the GApps. Go for the one that the original GSI page recommends. Flash it to the System Image partition. Don't wipe anything. At this point I recommend that if you realise that you forgot to transfer any files to the SD card, you should do it from the system. It works better compared to the MTP on TWRP. Either way, that should work properly. Now, reboot the system, and it should work perfectly.
Enjoy, it took me months to get to this point lol
Rooting Your New ROM With Magisk
(Before installing this consider the other root options. I believe there's SuperSU and another possibly that I'm less aware of. Either way, in my opinion Magisk comes with the most benefits so I'll be helping you out with that).
After this I ended up flashing Magisk in order to use Snapchat and other apps similar to it. Firstly you'll want to set up Google stuff which has been newly added to the system, and then you'll want to go to chrome and download the Magisk Manager .apk from here. The main and most reliable place to get it is from the creator's project page found here, all main links stand out in the middle fairly well.
(Remember to enable downloading of unknown apps for Chrome in it's app settings, otherwise it won't download or install.)
If it still doesn't work at this point, I ended up holding down on the Magisk Manager link and pressing Download Link (or something to that effect). From this point just install it as you would any other out-of-store app.
Now, you'll need to download these two files from the Magisk page onto your computer: Stable Installer and Uninstaller. Next, while booted into Android, copy them over to either Internal or External storage and when it's done, reboot into TWRP again, either by advanced power menu or using the button commands for recovery. Personally, I think I need the power options with this phone.
In TWRP, simply go to Install, navigate to /externalsd/***[WHEREVER YOU PLACED YOUR MAGISK FILES]***, then install the Magisk installer .zip. If unchanged, the filename should be something like "Magisk-v17.1.zip". Install it, then give rebooting a go. Hopefully it'll post, if not, go back into TWRP and run the Uninstaller .zip, it's saved me a bunch of times.
Unblocking Apps That Say Something Like "Your Phone is Rooted or Modified, no access blah blah blah..."
(Snapchat is the example used here. It won't work upon login if you don't follow this step. Some apps don't work with this alone however, though somebody may have produced a separate guide or easily installable Magisk module with a solution for it. One that won't be fixed singularly with Magisk Hide is Google Pay).
After posting, if you need to unblock Snapchat or something, go to Magisk Manager (which should now be more green), open the top left context menu, tap on Magisk Hide, and search "snap" until you see the Snapchat logo pop up, then select it, then back out with the back button. It should stay selected in Magisk, and the app should now be usable and shouldn't give you any annoying errors, if not give it a reboot and see if it's solved.
Good luck!

Magisk v22.0 Patch Image - Magisk in Recover - Xiaomi Mi 9T (davinci) not being installed

Hopefully someone can help me out here:
I'm on Mi 9T (davinici) with xiaomi.eu-cROM 12.1.2 (Stable) and OrangeFox Beta R11.0 Recovery. Bootloader is obviously unlocked.
I followed the guide for Magisk v22.0 and installed the apk first, opened it and it says
"Ramdisk No"
Alright, so I have to patch the recovery.img.
In Orangefox Recovery I open the Terminal and extract recovery.img with
Code:
dd if=/dev/block/bootdevice/by-name/recovery of=/sdcard/recovery.img
Reboot to system and I chose "Install" in Magisk, "Recovery Mode" is already selected, click "Next" and I select the newly created file "recovery.img". Magisk does it's thing and I have "magisk_patched_cOdEy.img" in my Download folder which I pull with adb.
I reboot to fastboot mode and
Code:
fastboot flash recovery magisk_patched_cOdEy.img
which works w/o problems and reboot again.
But when I open Magisk it still says it's not installed.
So, I check the guide under Magisk in Recovery, where it gets really confusing, but from what I got is that I need to start the phone with recovery button combo (Power+VolUp for Mi 9T) pushed and release at splash screen so Magisk is activated. I try this multiple times since it's really hard with the timing (milliseconds too long it kicks me into fastboot mode. idk why).
Can someone figure out what went wrong/what I did wrong? Never had problems with earlier Magisk versions.
Follow up question: There's some warning about going back to stock recovery will brick your phone in installation. Does that include installing OrangeFox again? I'm 95% sure it doesn't, but would be nice to know before I do it.
Some Xiaomi devices have their bootloaders set up so that it will accept an initramfs that was manually added to the boot image. Therefore, on these devices you'll need to patch the boot image even though there's no ramdisk. Try that.
Didgeridoohan said:
Some Xiaomi devices have their bootloaders set up so that it will accept an initramfs that was manually added to the boot image. Therefore, on these devices you'll need to patch the boot image even though there's no ramdisk. Try that.
Click to expand...
Click to collapse
Can I reinstall OrangeFox or TWRP recovery then?
I'll report back, when I tried it.
edit: So this actually works and I was able to enter TWRP recovery again after flashing.
edit 2: Now WiFi is not working anymore. fml.
edit 3: For anyone stumbling over this thread. Nothing worked, I had to do a compelte wipe and then flash Magisk "the old way", by renaming the .apk into a .zip and flashing it in recovery. That did the trick without any probems and I'm rooted now after quite a hassle.
yeah, I stumbled upon it. And I'm having the same/a very similar issue. I was very happy with Magisk up to v22 when the problems began.
I'm still at DerpFest based on Android 9.0 (from 2019 ) and TWRP-3.4.0.0.I had Magisk running since it was 19.4, upgraded it multiple times already. So didn't think much about updating to 22. Then, it said the same: no ramdisk. Pitty. OK, so I went ahead and let Magisk patch the TWRP.img I still got on my phone and flashed the patched TWRP onto recovery. Upon booting, Magisk is there, but no wifi, no sound, no light sensor, ... LTE works, though .
Anyways, I just want to get my old setup back, so I thought, I just flash the original TWRP again. According to the Magisk documentation, if I don't press any button, it should boot to Android without Magisk. Well, it always boots into Android+Magisk disregarding that. If I flash the original TWRP.img back, I always end up in TWRP. So, the order is: boot.img -> magisk-modified-recovery.img -> (boot.img?) -> system. How can I get the behaviour Magisk advertises?
And yes, I tried uninstalling Magisk (via uninstall.zip meythod), which said it would uninstall, but actually didn't. I also flashed different boot images (a backup I had in TWRP, the original boot.img I've found in the DerpFest zip...) to no avail.
So, Immortal68, which of the many wipes one can do did result in the old behaviour? And: now that you have Magisk22, does it say "Ramdisk: yes" again?

Rooting Moto G6 with PPS29-118-15-11. What versions of noverity, twrp, magisk to use?

Hello forum, I have been trying to root my motorola G6..
After much struggle, getting stuck in a boot loop and other issues I finally have restored stock roms and now have build PPS29-118-15-11 installed. So at least the phone works again My bootloader is unlocked.
But I still want to root it.
I think I understand the procedure well enough, but I am unsure of the correct/best versions I need for the ROMS/boot, Magisk, and TWRP.
ROMS/boot:
I found a youtube with instructions for updating Android v9
But I haven't tried it as this recommends a boot img:
OPS27.104-15-10_no-verity_boot.img
OPS27.104-15-10_no-verity_boot.img | by dejello for Moto G6
Download GApps, Roms, Kernels, Themes, Firmware, and more. Free file hosting for all Android developers.
androidfilehost.com
I am reluctant to use the above as it looks to be a downgrade from my current version 29-118-15-11.
Also, I thought that the filename prefix "O" indicated oreo instead of "P" for pie? So would this be a version 8 file?
TWRP:
Similarly, I am not sure if I am using the right, or best TWRP version. I currently have twrp-v3.2.3-ali.img
I flash this (with fastboot) and it works but shortly after I encounter the "no command" error (when booting to recovery) and I have to redo it. I am NOT overwriting it with a stock recovery.img.
I have also run into the "encryption password" problem, where I am unable to provide one to decrypt the data partition. So I can't backup the data with twrp (something I really would like to do).
Magisk
I have Magisk-23-0.zip
But I saw a post from brunogroa that recommends installing Magisk 19 and updating it to 23 later. Is this something that is required or can I just install v23?
So, I am looking for the correct versions for ROM, Magisk and TWRP to use, given that I have installed PPS29-118-15-11
Any assistance will be greatly appreciated.
Well I finally have it I think. I noticed a comment in
[GUIDE][ROOT][Moto G6][ALI] TWRP, Root, and Magisk installation guide. by djello
"(you may not need a modified boot image for Magisk)"
When using PIE instead of OREO.
Being an optimist, I gave it a try and it worked... I installed Magisk and was able to verify root access using the Root Checker Basic App. Kept stock boot img.
This is probably not too amazing for the old hands but us newbies need a break every now and them
So in the end, all I had to do was:
(0) Unlock bootloader
(1) Install stock PPS29-118-15-11
Done earlier with another version of twrp.
Install TWRP 3.5.2
(2) fastboot flash recovery twrp-3.5.2_9-0-ali.img
(3) Use twrp to install Magisk
adb push Magisk-v23-0.zip /tmp
Boot phone into recovery and use twrp to install Magisk
(4) Boot the phone into System and verify Magisk is there and use Root Checker App to confirm I am now rooted.
Issues:
I noticed that a security update for
PPS29-118-15-11-5 failed to apply.
The phone boots into recovery mode and asks for the decrypt password. I don't know the password to decrypt data and how to proceed from here.
I suspect that if I flash the stock recovery img the security update might work. If anyone knows please comment ; I will research this also and maybe just try it.
pdpantages said:
Well I finally have it I think. I noticed a comment in
[GUIDE][ROOT][Moto G6][ALI] TWRP, Root, and Magisk installation guide. by djello
"(you may not need a modified boot image for Magisk)"
When using PIE instead of OREO.
Being an optimist, I gave it a try and it worked... I installed Magisk and was able to verify root access using the Root Checker Basic App. Kept stock boot img.
This is probably not too amazing for the old hands but us newbies need a break every now and them
So in the end, all I had to do was:
(0) Unlock bootloader
(1) Install stock PPS29-118-15-11
Done earlier with another version of twrp.
Install TWRP 3.5.2
(2) fastboot flash recovery twrp-3.5.2_9-0-ali.img
(3) Use twrp to install Magisk
adb push Magisk-v23-0.zip /tmp
Boot phone into recovery and use twrp to install Magisk
(4) Boot the phone into System and verify Magisk is there and use Root Checker App to confirm I am now rooted.
Issues:
I noticed that a security update for
PPS29-118-15-11-5 failed to apply.
The phone boots into recovery mode and asks for the decrypt password. I don't know the password to decrypt data and how to proceed from here.
I suspect that if I flash the stock recovery img the security update might work. If anyone knows please comment ; I will research this also and maybe just try it.
Click to expand...
Click to collapse
I am stuck in a similar position.
SOLVED IT!!! Followed all of the steps that you posted except I installed Magisk with the patch method because I couldn't get the zip file to push onto the device. Kept getting a read only error, maybe because it wasn't rooted?
Anyway, I am rooted now!!!

Magisk 25.2 severely breaks LineageOS 18.1 on Samsung Galaxy Tab S5e (SM-T725)

For some odd reason Magisk breaks auto-rotation and sets selinux to permissive on boot after updating to 25.2 (from 25.1).
This is not the first time Magisk messes up Selinux rules. I usuall solved this by making a fresh OS install already with patched boot and by installing the managing app afterwards.
However, this time autorotation stopped working for some reason. And when i try to uninstall Magisk using its app -- OS no longer boots, as if it fails to restore initial boot image.
This selinux problem began since v25.
I use latest official build of Lineage OS 18.1. I have TWRP installed, which i use to install LineageOS.
What am i doing wrong? Has anyone experienced such issues?
I posted the same problem here (did not notice/checked SELinux back then and sound is probably also not working), figured out that all sensors do not work, checked with "Sensor Test" app. I was already considering a separate thread, thus I'll continue here, because this issue definitely deserves a separate thread. Documentation is so scattered and sometimes so confusionly described, that it was hard to make sense of it all...
(Disclaimer: Although I have necessary experience with installing custom ROMs etc., everything stated below is at my own understanding ).
My device: Samsung Galaxy Tab S5e LTE
My goal was: TWRP, LineageOS and Magisk. How hard can it be?
Problems are that (most of the) Samsung devices do not have a "ramdisk" partition where Magisk is normally installed, also the increasingly complexity of encryption en integrity checks makes this more annoying.
First, let me retrace my steps, as far as I can.
When reading the TWRP page, we get a clue where to start: "You are therefore strongly advised to first root your device with Magisk and then pre-root a TWRP image before flashing it to recovery", this is because "Both TWRP and Magisk-rooted Android boot using the recovery kernel, with the device's hardware keys used to choose between TWRP and Android at boot time".
(Magisk "hijacks" part of the recovery partition, since the absence of a ramdisk partition.)
Spoiler: later on you learn this is not completely the case any more, but I would still recommend to hold on to this method, because the TWRP page also states that: "The usual path of installing TWRP prior to rooting is problematic on this device, because the Magisk installer does not support installation to recovery from TWRP. Furthermore, prior rooting of the device with Magisk carries the significant advantage of disabling various device protection mechanisms that you will otherwise need to take care of manually.", and it continues with more scary warnings...
1. Thus followed the Samsung section of the Magisk documentation to have the bootloader unlocked and Magisk installed, but stock firmware is still installed, no problem whatsoever.
Then decipher the already mentioned instruction: "...pre-root a TWRP image before flashing it to recovery". This apparently means that Magisk has to patch the TWRP image, just like as was done with the Samsung firmware.
2. Downloaded the *.tar file of TWRP, extracted the image, patched with Magisk and repacked to the *.tar file with 7-Zip in order to be able to flash it with Odin (see step 4).
*3. I do not recall when I installed the "VBMeta file", although this is instructed in the Lineage OS installation instructions, when following the TWRP instructions it says "...you can now jump to its own section", thus skipping it?? (I did it somewhere in the process...)
Unknown: whether it is still required to patch and flash VBmeta (to disable some verification process)...
4. Flash TWRP recovery, see YouTube video below. This video mentions the use of "multidisabler-samsung", which disables "FBE, proca, Vaultkeeper and auto-reflash of stock recovery on Samsung Pie devices". Current latest version was 3.1, downloaded from this XDA post, I think.
Just as in the YouTube video, I also was stuck at the Samsung logo. After booting into the stock firmware you can check if Magisk still works.
Not sure: "multidisabler-samsung" needed?
5. Install LineageOS (and GApps). The most straightforward step, just install LineageOS, read the instructions. Then install GApps (e.g., BiTGApps).
6. After booting (power and volume + button) and setting up LineageOS, a Magisk icon should be visible in the app drawer, click it and the Magisk app is installed, when opened, Magisk is setting up a few more things and reboots the tablet.
*******************************************************************************************
This is the point were you finally think you made it, but no, here the issues arise.
Issues thus being SELinux permissive status (Xandros Darkstorm), no sound and non-working sensors, thus "auto rotating" feature is not working.
At this point I started to regret my purchase...
In the search of a solution to the problem I stumbled upon the following familiar and solved Magisk issue #4911 (LineageOS 18.1 no sound and no sensors after booting with Magisk), which refers to issue #4394 (Magisk > 21.4 is difficult to install on LineageOS (18.1) with TWRP (Direct Install not enabled unless you use old zip)).
In short: this post mentioned patching the boot image instead of the recovery image.
*******************************************************************************************
I. I extracted "boot.img" from the LineageOS zip file, patched it via Magisk (ramdisk is added to the boot image) and replaced the "boot.img" in the zip file with 7-Zip.
II. Booted into TWRP, flashed an original TWRP image, so recovery is replaced. (Rebooted I guess.)
III. Then wiped previously LineageOS installation and, flashed the LineageOS zip file with patched boot image and GApps and rebooted to system.
IV. After setting up, install Magisk, let is do its thing.
V. I installed "Root Checker Basic" in order to check I gained root checker. It was a PASS! And checked with "Sensor Test" if all sensors worked, they did! And sound also worked .
Yay!
Clearly, all of this can be optimized. Some questions remain, what steps are really necessary and I am also still wondering how to apply a LineageOS update... Anyhow at least it is working.
What resolved
Xandros Darkstorm said:
For some odd reason Magisk breaks auto-rotation and sets selinux to permissive on boot after updating to 25.2 (from 25.1).
This is not the first time Magisk messes up Selinux rules. I usuall solved this by making a fresh OS install already with patched boot and by installing the managing app afterwards.
However, this time autorotation stopped working for some reason. And when i try to uninstall Magisk using its app -- OS no longer boots, as if it fails to restore initial boot image.
This selinux problem began since v25.
I use latest official build of Lineage OS 18.1. I have TWRP installed, which i use to install LineageOS.
What am i doing wrong? Has anyone experienced such issues?
Click to expand...
Click to collapse
What fixed this for me is after re-flashing stock in Odin to get everything working again, just rename the magisk apk to install.zip and flash that in twrp, and open the magisk app once booted, no other steps needed for install, no image patching or anything.
Might be worth seeing if this is the same issue or if there's a more fundamental problem with 25.2
Hi,
I stumbled upon this thread while searching for a way to install Magisk on a S5e.
Following the guide here: https://wiki.lineageos.org/devices/gts4lvwifi/install I already unlocked the bootloader, flashed vbmeta.tar with Odin, flashed lineage-19.1-20221114-recovery-gts4lvwifi.img with Odin and flashed lineage-19.1-20221114-nightly-gts4lvwifi-signed.zip with TWRP-recovery.
Lineage is working fine, but I would also like to use Magisk.
I understood, that the order I follwed is not the recommended order for having both Magisk and Lineage. At least, that is, what you described at the beginning of your post.
But as with your last part you mentioned, that there where issues with sensors, ...
And the solution was to
I. Replace recovery with a patched boot.img of Lineage zip and wipe a prev. Lineage installation
I guess, I might be able to stiull do that though I already have Lineage on the S5e (currently with Lineage/TWRP recovery), right?
I can patch the boot.img from within lineage-19.1-20221114-nightly-gts4lvwifi-signed.zip with Magisk app, right?
Or would I have to patch lineage-19.1-20221114-recovery-gts4lvwifi.img
Is there anything to consider, when zipping the image with the patched boot.img again?
Which TWRP image did you choose to be flashed at step II.?
Barium said:
I. I extracted "boot.img" from the LineageOS zip file, patched it via Magisk (ramdisk is added to the boot image) and replaced the "boot.img" in the zip file with 7-Zip.
II. Booted into TWRP, flashed an original TWRP image, so recovery is replaced. (Rebooted I guess.)
III. Then wiped previously LineageOS installation and, flashed the LineageOS zip file with patched boot image and GApps and rebooted to system.
IV. After setting up, install Magisk, let is do its thing.
V. I installed "Root Checker Basic" in order to check I gained root checker. It was a PASS! And checked with "Sensor Test" if all sensors worked, they did! And sound also worked .
Yay!
Clearly, all of this can be optimized. Some questions remain, what steps are really necessary and I am also still wondering how to apply a LineageOS update... Anyhow at least it is working.
Click to expand...
Click to collapse
Thanks
If this is also a solution, can you please let me know, if there is anyhting to consider, when flashing the stock (got it from SAMMOBILE)? Can the lineage-19.1-20221114-recovery-gts4lvwifi.img still be left on the tab?
After re-flashing the stock, I guess you flashed lineage again, right?
Or did you stay with the stock and just flashed magisk (after renaming the apk to zip)?
Thanks
TheTofu said:
What fixed this for me is after re-flashing stock in Odin to get everything working again, just rename the magisk apk to install.zip and flash that in twrp, and open the magisk app once booted, no other steps needed for install, no image patching or anything.
Click to expand...
Click to collapse
I dared patching the TWRP recover for S5e and flashed it via Odin (AP).
S5e boots up in Lineage, Magisk is working fine.
But when I power off the tablet or restart, Lineage Recovery shows up telling me, that my data would be corrupt.
My only options are to try again or to do a factory reset.
Only way out of this is to re-flash the above mentioned recovery image again.
So how do I get the Magisk patched TWRP recovery permanent?
I wiped system? and re-flashed Lineage via TWRP, got "original" TWRP Recovery for S5e Magisk permanent.
I have to admid, I tried several things and got lucky I did not break something.
I had nearly, what I wanted - TWRP, Lineage and Magisk, but there were issues with the sensors (no auto rotate).
Again I helped myself:
1) flashed the original, unpatched TWRP Recovery for S5e
2) flashed unpatched Lineage for S5e
3) flashed MindTheGapps
4) flashed Magisk-v25.2.apk
No bootloop, original TWRP permanent, Magisks working fine, no issues with sensors.
Tried steps 1, 2 and 4 with the Lineage Recovery and it worked too.

Categories

Resources