yashsingh1/xdaforums huggingface dataset:
[Magisk] ashrr:
Ha. I have backups of my apps+data so I was fine if I had to do a clean install, I just don't do full device backups often since I don't expect the things I do with my phone now to break them in a way I would need to restore from one.
[Magisk] zgfg:
Regarding to the recent discussion about systemless root - nothing new below but maybe useful to those new with the concept

One can go for making the system writable again:

https://xdaforums.com/t/script-android-10-universal-mount-system-read-write-r-w.4247311/

But it actually means that the system's filesystem must be expanded (to provide a space to write something there in future) - on the expense of your Data partition

It also brings additional complications to A/B SAR systems

Of course, that hard changes to the system may break OTA, or even worse (depending on the manufacturer/phone and their OTA practices) cause a risk to brick the phone while taking the OTA in future

Some people still cry "why I cannot write to my system" - probably because they are not familiar with the systemless concept (although the Magisk systemless root is around for two years, e.g. Huawei with EMUI 9.1/Android 9 already had their system read-only)

Magisk modules are (should be at least those from Repo) all systemless; when you enable Systemless hosts in Magisk, AdAway will systemlessly write to /system/etc /hosts file (or one can manually write to the corresponding hosts file overlay at /data/adb/modules/hosts/system/etc/hosts); and by following the Magisk documentation from Github one can easily make his own systemless changes (e.g., I always debloat my system the systemless manner) - hence IMO no real need for the old days with writable systems
[Magisk] J.Michael:
@dr4go I don't understand why you talk of whether the Recovery box is checked. I thought you had a Samsung device, and I thought the firmware came packaged as tar files, so I thought you would be telling Magisk to patch AP.tar. Magisk will modify boot, recovery, and vbmeta, and will produce magisk-patched-AP.tar -- you feed that to Odin, and all three get "flashed" (along with everything else in the tar, and everything in the other three tars you pass to Odin).

Are you seeing this zero-length boot.img in the magisk-patched-AP.tar?
[Magisk] dr4go:
Why I talk about the recovery box being checked? No offense, but please reread the posts. I found it pointless to talk about that, because I can't change the way of how Samsung's bootloader work.

I assume you know how it works, if not please inform yourself. Explanation: Magisk usually resides in the boot.img. But because those semi-modern devices (s10 series and some others) come with no initramfs, you need to patch the recovery (that is Magisk gets installed there). So you need to press a key combo to boot rooted (you often see people complain about that, because they don't know their devices and should not root at all: "help, I lost root!", etc.).

Yes.

This will he my last post about that, because I find it rather pointless to spam this huge thread even more with no added information. And obviously this talking won't anything help to fix this issue. I prefer to be quiet if I have nothing useful to say.
[Magisk] Iron_Overheat:
Under Magisk it's "Installed 22.1 (22100) | Ramdisk Yes | A/B Yes | SAR YES"

Under App it's "Latest 22.1 (22100) (20) | Installed 22.1 (22100) | Package com.topjohnwu.magisk"

It seems to be the same version except the App's Latest has an additional "(20)" over the Installed part.
[Magisk] xAutumn:
Hello! New user here. So I've been trying to update to latest Magisk version and it seems like I have an issue updating it through the app. Here's what it looks like as of now.

The app version is the same as latest, yet it gives me an update option. It also doesn't want to update Magisk itself. (log attached)

I use Xiaomi redmi note 7 (codename - lavender) with android 10 qkq.1.190910.002 with miui version 12.0.2.0(qfgruxm)

This is also my first time reporting a bug so if anything more is required please tell me what I need to provide.
[Magisk] zgfg:
You could have attached the screenshot but per description, it looks ok.

E.g., I have Canary 22002 (not Stable 22000 like you), Magisk properly imstalled and all ok - compare to my screenshot

If I understand correctly, you reported a crash while installing a Magisk module

If installing from Repo, take Download (instead of Install), it will download to your Download folder.

Then, take from Magisk app (again Modules tab, at the top), Install from storage and navigate to the Download folder and the downloaded module zip file

I.e., there was recently a bug that Magisk app was crashing when installing a module but by e.g. installing an already downloaded module zip file it worked fine (since I'm on Canary 22002, I don't know how is the case with your Stable 22000)

There was also another workaround. When taking Install, once Magisk app crashed, it was just enough to tap to the notification that module was downloaded - Magisk app would continue installinf the module

If still failing/crashing, try with another Magisk module (from Repo!) to make sure it wasn't an errant module
[Magisk] pndwal:
In addition to special patching requirements etc, some Sammy devices are type III, as are devices from other OEMs, and Magisk cannot be installed in boot partition on many (most?) of these since that cannot host a working ramdisk due to OEM's bootloader implementation.

Magisk must be installed in recovery partition (it has working ramdisk), and Recovery mode is selected to ensure patching recovery.img is done properly (as boot partition ramdisk and recovery partition ramdisk configurations differ significantly).

https://xdaforums.com/t/magisk-general-support-discussion.3432382/post-84818535

Incidentally, I think many are confusing Magisk Installed thru custom recovery (which ALWAYS results in Magisk in Boot) with Magisk in Recovery (something entirely different)! 😬 PW
[Magisk] zgfg:
I don't know what do you mean by 'corrupting' the system, but Magisk does not install (hence it does not affect and neither corrupt) the System, but to Boot partition (or in some cases Recovery or Randisk partitions)

Strictly speaking, those partitions are not System partition - whereas the term Systemless refers strictly to not making changes to the System partition itself

Hence if something goes wrong (bootlop or so), it was not due to Magisk affected or 'corrupted' the System partition - you could e.g. take a TWRP backup of the System (!) partition before and upon installing Magisk, and compare the back-ups
[Magisk] pndwal:
As it's Xiaomi, you can most likely use Magisk in Boot despite ramdisk = no, as you likely know.

Can you confirm:

1) You just boot device normally (no special Recovery key combination needed to boot to system with root).

2) You click Update, Clear Recovery mode box (if it's not already), Click Next, select Direct Install, click Let's Go... Reboot.

👍 PW
[Magisk] xAutumn:
I can boot into device normally.

Did what you mentioned in 2, it didn't update, previously I've ticked recovery mode box.
[Magisk] Iron_Overheat:
Installing the zip from storage was something I already tried but for some reason Internal Storage is showing as empty in my system (can't even access through MTP, only sdcard...). Even accessing thru root file explorer, /storage/emulated/0/ is empty... But on the settings app, under storage, it shows "Internal shared storage 11.02 GB used of 64.00 GB"... I have no idea why, before installing LineageOS 18.1 I could access internal storage... I already asked on my ROM's thread about this issue but nobody answered...
[Magisk] zgfg:
Do you properly see Internal storage from TWRP?

What about using a different file explorer, like MiXplorer (use the version for target SDK 29, NOT for target SDK 30)
[Magisk] op3tguy:
Okay, I'll try the boot.img first.

I'll try attaching the files again.

Hmmm, I attached and they appeared to upload but perhaps because this is my first post it won't "stick".
[Magisk] pndwal:
... So, you probably now have Magisk in Recovery ramdisk also (unless Direct Install w/ Recovery mode checked failed to complete). I'm interested if you can boot with root this way:

Booting any way, can you also Install CPU-Z from PlayStore, check System, Kernel Architecture. Is this 32 or 64 bit? 👍 PW
[Magisk] pndwal:
@zgfg

Did you ever get any info on that (Russian?) patched Magisk-R for RN7 from here:

https://xdaforums.com/t/install-magisk-on-android-11-r-100-functional.4162761/

It may help user above to know what issue is, but I don't want to recommend it as looks dubious...

I thought it may be related to R7A issues (apparent it's boot.img is 32 bit with a 'fake' 64 bit Ramdisk (placeholder)), but I doubt this after looking at specs... PW
[Magisk] J.Michael:
What I was trying to say was, if you give Magisk an AP.tar file, Magisk knows it's handling a tar file, Magisk extracts the boot, recovery, and vbmeta images, and Magisk modifies those three. The checkbox "Recovery" on the Magisk screen does not seem to apply, because in that case Magisk will always put Magisk in the recovery.img -- it makes changes to the boot.img and vbmeta.img to deal with signature checks, but the "installation" of Magisk is in the recovery.img.
[Magisk] zgfg:
No, but there was a similar (albeit different) Magisk zip fluctuating around for my Mi 9T, that turned out to be Magisk 20004 or something.

It was needed to patch the boot.img first by that (Magisk 20004), and then to re-patch by the latetest Magisk, otherwise it didn't work

However, it became obsolete when Magisk 21xxx was fixed

In the thread you mentioned the latest posts are from Dec 2020, hence I would assume that it similarly became obsolete when Magisk was fixed to properly patch boot images (for various Xiaomi phones)

However I don't know for that particular model and it's special CPU (maybe it's not Qualcomm like in the my Mi 9T but MTK or something - although, AFAIK, Magisk was also fixed for MTK chipsets around the beginning of 2021)

PS: I just checked on GSMArena, R7A has Qualcomm SDM439 Snapdragon 439 (not MTK)
[Magisk] pndwal:
Ta. Asked, since you asked about it in RN7 thread. User has RN7:

https://xdaforums.com/t/magisk-general-support-discussion.3432382/post-84820497

That's QCom 660. (R7A issue now seems unrelated as I said).

May be a new issue anyway, since user can't update from 22.0, but seems there's been something peculiar about that model...

@xAutumn, Suggest you Unroot completely (restore both clean boot / recovery (keep stock) images, uninstall modules and app), then try patching boot.img extracted from ROM using latest Magisk App and flashing this from PC (fastboot mode), and see if this fixes issue. This method is best practice for fresh install. PW
[Magisk] pndwal:
Are you sure? Because instructions in Samsung section are almost identical to general Patching Images section:

Ie. App will know to use Boot ramdisk protocol if unchecked (whether patching Magisk to discreet boot image (.img) or to boot image integrated in AP (.tar) firmware package), and Recovery ramdisk protocol if checked (whether patching Magisk to discreet recovery image (.img) or to recovery image integrated in AP (.tar) firmware package).

As I've mentioned, the two ramdisk types are different, and implemented differently (or only one type may be implemented) in bootloader. 🤠 PW
[Magisk] J.Michael:
I can't be sure of anything -- I haven't looked at Magisk's code. I thought I had tried patching a tar file both with and without checking Recovery, and had seen no difference in the three modified images. I might be misremembering.

I thought Samsung was the only case of firmware being packaged as a tar file. I thought all Samsungs had to have Magisk installed in recovery. I think the people who got TWRP working on the SM-T290 and SM-T295 have succeeded by patching the boot image.
[Magisk] pndwal:
Well, if flash in Custom Recovery is working, this confirms that Magisk in Boot works. It will necessarily work on the same device by patching .tar / flashing with Odin.

Patching Recovery can never be done from Custom Recovery and is only needed, for type III devices... It will usually work on others too...

But why would you?

To boot into System with Magisk root you HAVE to use key combination for Recovery, then, when the device vibrates with a splash screen, release all buttons EVERY TIME you boot device.

Nb. Unless you boot that way, root (if present) was actually installed as Magisk in Boot. 👍 PW
[Magisk] xAutumn:
I can boot into recovery mode holding power and volume up, no Idea how to boot into Magisk if thats what you mean. My architecture according to cpu-z js armv8l
[Magisk] voroxda:
I have upgraded from 22002 to 22100. Everything is fine. But in 22.1 I have no possibility to choice canary version. The user based url https://raw.githubusercontent.com/topjohnwu/magisk_files/canary/debug.json doesn't work. Is there a special mm apk for 22.1?
[Magisk] xAutumn:
My phone boots with root every time with no need to use key combination for recovery, just a simple reboot and root is always enabled.
[Magisk] zputnyq:
I'm not sure about .json file since I never switching update from stable to canary or beta, I usually just clean install it if I switch. But if you can't download it from .json file you can grab it directly from github.
[Magisk] pndwal:
Yes, I'm aware you have Magisk in boot ramdisk. I think you did from the beginning of this discussion. But since you said you did direct update with Recovery mode checked, I was curious whether that succeeded.

If it did, you will have a SECOND iteration of Magisk in recovery ramdisk. Booting to system with root using THAT Installation is done via Recovery booting, ie. recovery combination buttons (since Recovery has been 'hijacked' as a means of booting to System w/ root).

Whether you get recovery, or system w/ root, depends on when you RELEASE the recovery combination buttons, as noted above, and in John's official Installation Instruction page. PW
[Magisk] pndwal:
All later Magisk builds are a Stand Alone (no need for internet connection / json files to downgrade), single package solution, both debug (Canary) builds (from 21402):

https://xdaforums.com/t/magisk-general-support-discussion.3432382/post-84354959

and public (Stable/Beta) from 22.0:

https://topjohnwu.github.io/Magisk/releases/22000.html

For older stable builds, unless Installing .zip package from custom recovery you'd need hosted address of corresponding raw json file pasted in 'Custom Channel'. Older Canary Jsons won't work this way without editing and re-hosting as they always point to (common) address for LATEST Canary build rather than unique address.

But you can forget all that! 😆

All you need to do is click on Magisk Canary, under Downloads on Magisk main page on GitHub, and .apk will download! Just Install it.

FYI Canary builds, being 'bleeding edge' builds for debug purposes, are not considered Public builds, so Canary Channel won't appear in Magisk App (Settings) from Beta / Stable Public Releases. Debug builds contain all channels. 🤠 PW
[Magisk] J.Michael:
Not so.

I recognize what you say as the way it was described in Magisk/install.md when I was trying to install Magisk. I don't know if Magisk was changed between the time those notes were written and the version I installed, or if there's something special about some devices, but I routinely shut down and reboot and Magisk is active.

I'm sure Magisk is installed in recovery, because I had to struggle to boot almost-but-not-quite to recovery when I first installed. After repeatedly booting to no Magisk, I finally got the timing right and got "Magisk needs to do more setup."

What I have read in posts is that it's using the Reboot option on the Power button menu that boots without Magisk -- after doing that, you need the horrible almost-recovery boot sequence to regain Magisk.

TL;DR On at least some devices, with Magisk installed in recovery, complete shut down followed by power-on reboot will not lose Magisk active.
[Magisk] theraw22:
hello,

MOTO e4 won't boot anymore after i did the "direct install" when i got the notification of new release https://github.com/topjohnwu/Magisk/releases/tag/v22.0

Right after doing that i got no errors during installation so i clicked reboot from magisk manager after and phone won't turn on anymore its been like this for hours

i tried to uninstall magisk via "uninstall.zip" on TWRP but didn't help it still stuck on boot.

How to fix this without losing my data?!

thank you
[Magisk] zgfg:
IMO, its just a very obvious and very basic logic:

1) If you (not yourself) patch boot img, then Recovery mode must not be checked, and resulted magisk_patched.img must be flashed to Boot

2) If you patch recovery.img, then Recovery mode must be checked in, and resulted magisk_patched.img must be flashed to Recovery

1a) If you originally installed Magisk by (1) , then always update Magisk again by repeating (1), not (2).

Or if you opt for Direct update, then Recovery mode must not be checked in - like originally when it wasn't checked for (1)

2a) If you originally installed Magisk by (2), then always update Magisk again by repeating (2), not (1).

Or if you opt for Direct update, then Recovery mode must be checked in - like originally when it was checked for (2)

Sorry but any other combination for me is simply out of mind and asking for troubles, like:

- patching boot.img but with Recovery mode checked in

- flashing the patched recovery img but to Boot partition

- originally patching and flashing boot img but later forcing Recoveey mode while taking Direct update

- etc

One can experiment, nice, but please later don't cry why Magisk did not update, why bootloop, how to fix, and so on 🤓
[Magisk] Austinredstoner:
I did direct install in magisk for my moto g7 and I didn't even get a bootloop
[Magisk] RootedLee:
fixed for me on my phone (rig see below) with Magisk v22.1 - thank you @topjohnwu !!!
[Magisk] pndwal:
Thats interesting.

Seems we're discussing SM-T290 Tab-a-8-0-2019

Does does Magisk say ramdisk = no?

Seems to be mixed info. re. ramdisk in boot partition.

User in 'root' thread indicates Magisk can be installed to boot using .zip from TWRP after flashing a vendor fix.

Post in thread 'Root for SM-T290 (tab a 8.0 2019)' https://xdaforums.com/t/root-for-sm-t290-tab-a-8-0-2019.3965624/post-84814529

Other forums also indicate Magisk works in boot from zip Installation from TWRP.

Root Samsung Galaxy Tab A 8.0 SM-T290 and Install TWRP Recovery

Easy tutorial to Root Samsung Galaxy Tab A 8.0 SM-T290 on Android 10 One UI 2.0. For rooting, you have to flash TWRP Recovery 3.4.0 first through the guide.

www.androidweblog.com

But TWRP Dev says this device has no ramdisk in boot!

Post in thread '[RECOVERY][UNOFFICIAL] TWRP 3.4.0 for 2019 Galaxy Tab A 8.0 [SM-T290]' https://xdaforums.com/t/recovery-un...alaxy-tab-a-8-0-sm-t290.4197461/post-84819581

I'm suspecting that it does (/may) in fact work (at least it seems to have bootloader support for boot-ramdisk if added manually), and that having patched or direct installed Magisk at some stage with Recovery mode UNCHECKED, you (likewise) could have TWO instances of Magisk; one in boot-ramdisk and one in recovery-ramdisk. This would be another explanation for your ability to boot BOTH ways with root in system.

I intend to test this on my Xiaomi device some time too... Haven't yet. 😳 PW
[Magisk] pndwal:
Flash clean (unpatched) boot.img from archive for your ROM, ideally using PC / Fastboot. PW
[Magisk] J.L.C.:
Anyone else having problems with the April security update?

I'm on a Pixel 4xl and when I patch boot.img with the Magisk app (22102) and flash, my phone won't boot past "system is starting".

I can boot if I re-flash the stock boot.img, but then I don't have root.
[Magisk] Lughnasadh:
No problem on my Pixel 4 XL but I'm using the Stable channel so I have 22.1 installed. Did you disable any mods you might have that may need updating?
[Magisk] J.L.C.:
No modules installed, I'm going from a clean flash of the April update.
[Magisk] Lughnasadh:
Try stable.
[Magisk] pndwal:
Good result (so far)!

Got Regression label, getting attention... 👍

... all while John blissfully studies Rust / Kotlin and plays Toki tori with Apple Music drowning out the cries for help with a 'Smart' washing machine refusing to start because it identifies unlocked bootloader as 'Root' on a ThinQ ... 😛

😆 PW
[Magisk] J.L.C.:
Unfortunately, I get the same result with stable (22100), stuck on "phone is starting" after flashing.
[Magisk] J.Michael:
@pndwal Ramdisk = No
[Magisk] Austinredstoner:
For me ramdisk is yes I'm in luck but I don't think that matters doesn't it
[Magisk] dustofdeath:
For soem reason i cannot get past 20.4.

App is the v22 from git.

Direct install finishes, all successful, reboots - and installed version still shows 20.4.
[Magisk] Lamantin001:
Hi developers!

Today I wanted to update my magisk from the app from 22.0 to 22.1, but upon updating using direct install, my phone got into bootloop. After (or during) installing it just rebooted, but it always reboots into fastboot. It's a xiaomi pocophone f1 with latest stable miui global stock rom (12.0.3), unlocked bootloader, twrp recovery, with root of course by previous magisk install. I didn't have any modules installed from the app, so that couldn't make the problem, it was during updating the app. I can still access twrp. There, when I first wanted to reboot to system, before trying anything, it said "No os installed". Then I started googling, I tried uninstalling magisk, by downloading first v22.0 apk, renaming it to uninstall.zip, flashing, rebooting, same thing. Then tried again, and tried installing it back again, rebooting, same thing. Then tried uninstalling, flashing clean boot.img, rebooting, same thing. Then tried the same with 22.1 apk uninstaller. I tried all combinations of these solutions, none of them seemed to work. :/ Currently I still have the bootloop to fastboot.

Can you suggest any other solutions without losing all the data?
[Magisk] ineedroot69:
flash system.img you got same issue with this guy https://xdaforums.com/t/magisk-general-support-discussion.3432382/page-2261#post-84814787

or this https://www.didgeridoohan.com/magisk/MagiskUninstall
[Magisk] swieder711:
I am having a similar problem with Magisk 22.1 on my Pixel 3 XL with the April update. Phone boots fine with the stock boot.img. After "flashboot flash boot magisk_patched.img" then the phone gets stuck on the "G" screen. If I flash back to stock boot.img again then the phone boots, but no root.

Magisk was working fine on the Jan update.

Any suggestions?
[Magisk] Lamantin001:
Thanks! System.img flash solved the issue, but of course, magisk was gone, therefore miui overwrote custom recovery with stock, so I had to flash twrp from adb again, then flash magisk again in order to prevent the overwrite. I tried directly flashing v22.1 this time, but it didn't work. When I first started the phone, I clicked on magisk app to finish installation, but there was an error. So I uninstalled v22.1, and installed v22.0, now everything's back to where it was. Now i'll do a backup and never again update from magisk app :D