yashsingh1/xdaforums huggingface dataset:
[Google Pixel 6 Pro] ginfest:
So I went through the whole process again, still a size mismatch!

F:\platform-tools32>fastboot flash boot magisk_patched.img

Warning: skip copying boot image avb footer (boot partition size: 67108864, boot image size: 100663296).

Sending 'boot_a' (98304 KB) OKAY [ 2.227s]

Writing 'boot_a' FAILED (remote: 'failed to flash partition (boot_a)')

fastboot: error: Command failed

Repatched the boot image in Magisk but it still the same size as the original!

Any ideas why Magisk not patching the files correctly?

Magisk Canary 24.102(25) Platform tools 32
[Google Pixel 6 Pro] V0latyle:
The file size remains the same after patching.

This is an odd issue. Your boot image size appears correct. Did you have custom firmware flashed at any point?
[Google Pixel 6 Pro] Lughnasadh:
Make sure you have the latest drivers installed. Also try different cables/ports.
[Google Pixel 6 Pro] ginfest:
Thanks - I checked all the drivers are up to date and the cables are good.

The problem is Magisk is not patching the boot.img correctly - this is on the phone before I copy the patched boot.img back to the PC

Un-patched size is 101MB Magisk patched image is 101MB!

I believe it should be around 68MB after patching?
[Google Pixel 6 Pro] V0latyle:
Patching the boot image does not change the size. It should be 98,304KB before and after patching.
[Google Pixel 6 Pro] ginfest:
I tried a different version of Magisk (18) and still the same.

Dole anyone have a patched boot.img for Build SQ1D.220105.007 they can link me?
[Google Pixel 6 Pro] ginfest:
Thanks, that clears that up! Any idea why I get this error?

Warning: skip copying boot image avb footer (boot partition size: 67108864, boot image size: 100663296).
[Google Pixel 6 Pro] V0latyle:
Please read the instructions in the OP again - you CANNOT substitute a different version of Magisk. You MUST use Stable/Beta 24.0 and newer, or Canary 23016 and newer.

Patching does not change the size. Proper boot image size as shown above is 100,663,296 bytes, or 98,304 KB.
[Google Pixel 6 Pro] Lughnasadh:
Interesting. The boot image on the Pixel 5 seems larger than on the Pixel 6 Pro.
[Google Pixel 6 Pro] ginfest:
OK I'm on Canary 24.102, using a boot.img patched with that version and file sizes match.

Getting the same messaghe --

F:\platform-tools32>fastboot flash boot magisk_patched.img

Warning: skip copying boot image avb footer (boot partition size: 67108864, boot image size: 100663296).

Sending 'boot_a' (98304 KB) OKAY [ 2.210s]

Writing 'boot_a' FAILED (remote: 'failed to flash partition (boot_a)')

fastboot: error: Command failed

I'll re-download the Factory Image again and start over.
[Google Pixel 6 Pro] ginfest:
The stock boot.img in this Factory image" raven-sq1d.220105.007-factory-d8f6b8a4.zip" is 101MB(98MB)

After patching in Magisk Canary 24102 its the same size. but flashing gives the same error as above!

F:\platform-tools32>fastboot flash boot magisk_patched.img

Warning: skip copying boot image avb footer (boot partition size: 67108864, boot image size: 100663296).

Sending 'boot_a' (98304 KB) OKAY [ 2.210s]

Writing 'boot_a' FAILED (remote: 'failed to flash partition (boot_a)')

fastboot: error: Command failed

This is driving me crazy, should be simple!

Does anyone have a patched image I can try?
[Google Pixel 6 Pro] Lughnasadh:
The stock boot image is not 101MB. See my screenshot above.
[Google Pixel 6 Pro] V0latyle:
Try live booting the patched image:

fastboot boot <patched boot image>

If the device boots, check Magisk for root. If you have root, tap Install in the Magisk section, then Direct Install.

How did you update to the January firmware?

Also, I'm a bit concerned about this part:

You shouldn't be getting that message when flashing. Here's what it looks like for me:
[Google Pixel 6 Pro] jcp2:
I have the pixel 6 pro and my January factory boot image is 64.0 MB (67,108,864 bytes), my magisk patched boot image is 64.0 MB (67,108,864 bytes). Are you sure that you're using the proper boot image for your phone? IE.. pixel 6 is 'oriole' and pixel 6 pro is 'raven'. Ensure that you have downloaded the correct factory image for your specific model. I had no problems with my rooting.
[Google Pixel 6 Pro] ginfest:
Thanks. I have the Pixel 6 Pro also. It's weird - I downloaded the Raven image from the developers page three times!!

Factory Images for Nexus and Pixel Devices | Google Play services | Google for Developers

developers.google.com

12.0.0 (SQ1D.220105.007, Jan 2022)FlashLinkd8f6b8a4ff4865c9ebf08096a6263bfa4a3116e1fdd7f07770299055ec59fe26

I just figured it out!

This is what is inside!!!

"image-barbet-sq1a.220105.002" !!! The boot.img inside is 98MB!!

Google's link must be messed up! Someone please do a sanity check and let me know if I'm right.

Can you link me to patched boot.img?

Or does anyone have a link to Factory Image that isn't messed up?
[Google Pixel 6 Pro] cmh714:
it looks to me like you accidentally downloaded the 5a image along the way....the google link and download for raven is fine as best I can tell
[Google Pixel 6 Pro] RetroTech07:
We can't link you to a patched image if the one you flashed is for a different device.

Download the factory image and give it a go again...

https://dl.google.com/dl/android/aosp/raven-sq1d.220105.007-factory-d8f6b8a4.zip
[Google Pixel 6 Pro] V0latyle:
"Barbet" is the Pixel 5a. The P6 / P6 Pro boot images won't be the same size due to different architecture.

I'll see if I can download the factory image, then patch the boot image. Stand by...
[Google Pixel 6 Pro] ginfest:
Thank you. I must be crazy 'cause when I download the Raven Pixel 6 Pro image Developers Google website, it has the Barbet zip inside it!

OK progress, the link above has the correct files!!

Awesome, thanks. I'll try and patch now.
[Google Pixel 6 Pro] V0latyle:
Here is the January Raven boot image patched with Magisk Canary 24102.
[Google Pixel 6 Pro] ginfest:
Thanks for all the help guys and no I'm not crazy or stoned. For some reason every time I downloaded the Raven image from Google, it had the wrong zip inside! Weird, maybe a cache thing!

Anyway the link above from Retro worked and I patched and rooted.

V0latyle sorry you had the extra work to do before I got it sorted. Appreciate the file.

Thanks again all!
[Google Pixel 6 Pro] Rescue9:
Another way to do this rather than flashing the boot image from fastboot is simply to boot to the magisk patched image via "fastboot boot magisk_boot.img", let the phone boot, then do a direct install from the magisk itself.
[Google Pixel 6 Pro] fil3s:
You could try

.\fastboot boot <path to magiskimage>

then direct install 😕
[Google Pixel 6 Pro] Morgrain:
It's safe to update to feb, I used the OTA sideload method, root is still there, everything working fine.
[Google Pixel 6 Pro] aoaleman:
Factory image process here for February, worked smoothly. (y)
[Google Pixel 6 Pro] V0latyle:
Nice. I'm probably going to try the automatic OTA/install to inactive slot method on my Pixel 5. If it works, I'll update the guide.
[Google Pixel 6 Pro] Lycidias:
I think we'll need to do this
[Google Pixel 6 Pro] Morgrain:
There is one danger to that method.

If you deinstall Magisk and your device has not yet gotten the OTA (sometimes it can take days or weeks, even with manual prompting), you're f*ck*d.
[Google Pixel 6 Pro] V0latyle:
Please don't attempt to defeat the profanity filter.

You'd only need to restore the stock image when you know the OTA is available. And you wouldn't be screwed; you'd just need to get back to a PC and reflash the patched boot image.
[Google Pixel 6 Pro] Lughnasadh:
This method was successful for someone on Telegram 👍
[Google Pixel 6 Pro] Lycidias:
Didn't work for me, installation aborted. Gonna use factory install
[Google Pixel 6 Pro] Lughnasadh:
Strange. I've seen a few people now who said it worked for them.
[Google Pixel 6 Pro] WhoIsJohnGalt1979:
@Lughnasadh @V0latyle @gururoop Thank you for the very helpful instructions. Seamless transition to Feb from Jan without losing root and mods. I wasn't brave enough to try the inactive slot OTA update method, hopefully next month.

On a side note, is there a fastboot command to boot to safe mode from bootloader screen? Just asking.

Regards
[Google Pixel 6 Pro] V0latyle:
Not sure. fastboot continue instructs the bootloader to continue boot to system.

You have to restore the stock boot image first.
[Google Pixel 6 Pro] Lycidias:
I did, magisk asked me to do so
[Google Pixel 6 Pro] Lughnasadh:
Were you on a custom kernel? It won't work on a custom kernel because it could just be restoring the custom kernel's boot image depending on if you rooted or updated Magisk after installing a custom kernel, not the stock boot image, plus the other images that are now included in custom kernels will also need to be restored to stock as well.
[Google Pixel 6 Pro] RetroTech07:
I've learned to be safe than sorry and just restore whatever mods have been performed on the phone back to stock before updating to a new OS.

I decided to restore the stock kernel before flashing the OTA package and was fine. I'd rather not be stuck trying to undo a mess I created.
[Google Pixel 6 Pro] dilruk:
How did you restore it? Through the magisk app or manually flashed?
[Google Pixel 6 Pro] RetroTech07:
I manually flashed all the images in terminal.
[Google Pixel 6 Pro] fil3s:
Worked fine for me 👍 rooted on Feb security patch
[Google Pixel 6 Pro] dilruk:
What method did you follow?
[Google Pixel 6 Pro] fil3s:
I just used android flash tool, fastboot flashed the magisk boot image 😪
[Google Pixel 6 Pro] avid_droid:
Device build number.zip? I use payload dumper to extract payload.bin to get the boot.img like other phones right? I don't see what the direction says in my full zip??
[Google Pixel 6 Pro] summitfox:
I can also confirm that the Android flash tool works, and Fastboot flash magisk patched image for February update.
[Google Pixel 6 Pro] avid_droid:
The Android Dollhouse?
[Google Pixel 6 Pro] Bandsalat:
No, I hadn't. I only ran the Magisk uninstall routine.

I tried flashing stock boot image now, which results in the "Your device is corrupt." message being displayed and the phone then getting stuck on the Google splash screen.
[Google Pixel 6 Pro] flar2:
My update process is to remove vbmeta.img (in addition to removing the -w flag in the flash-all script) from the factory zip before I flash it in fastboot. Seems to have worked so far, ymmv.
[Google Pixel 6 Pro] V0latyle:
Try reflashing the factory image. If that doesn't work you will probably have to factory reset.
[Google Pixel 6 Pro] Utini:
But I want updates without having to clean wipe everytime? :S
[Google Pixel 6 Pro] Nekromantik:
I think we should remove some of the threads about rooting as there are 3 and people may get confused.
[Google Pixel 6 Pro] Bandsalat:
That's what I expect, which would be quite a bummer.

I'm curious, how do you folks do it?

John Wu thinks that hiding root will eventually be impossible and I think he's right. This means that e.g. gPay, banking apps, etc. stop working, rendering the phone practically useless, at least for me.

Without root I'm not aware of any effective way to transfer/backup most of app data. It baffles me that stock Android users apparently don't have a problem with starting all over whenever they buy a new phone. This is unthinkable in the iOS world.

Am I missing something?
[Google Pixel 6 Pro] V0latyle:
You don't have to. Just dirty flash the factory image with the disable options every time. Do not let the phone boot without verity and verification disabled, and do not take automatic system OTAs.

I suspect there may be some solution in the future for backing up user data. Any Android device has the ability to back up certain user information to the cloud, including what apps you had installed. Pixel devices back up most of your device, including text messages and photos.

As far as the future of root...John Wu said himself that due to his position on Android development, he could not continue to work on a scheme that actively blocks Android security solutions. Fortunately, we are able to get by with passive methods for the time being, but it is likely that you're correct - root will get harder to hide. Not impossible mind you...

And, it's not the end simply because the guy that initially built Magisk is now employed in a capacity that precludes him from working on certain things that would compromise Android security; Magisk is open source and there are many developers working on their own forks of Magisk that will continue to do everything they can for the root community.
[Google Pixel 6 Pro] Bandsalat:
It's certainly not because of him being employed by Google now and that's not what I meant. I quote him due to his expertise on the subject.

The fact that hiding root is still possible today is a result of Google so far only having taken a half-assed approach to preventing it. Whenever they really want to enforce it, they will just do it, and I think we're getting close to this time. There are very very limited options to successfully fake or circumvent HW KA.
[Google Pixel 6 Pro] Markelijk:
Thanks for your summary. If I'm not mistaken, you have to disable automatic OTA's via Settings > Developer Options > Automatic System Updates, right? That would be a 'step 3' in your guide I'm assuming.
[Google Pixel 6 Pro] Utini:
Yes, good point although OTA updates should fail on rooted devices anyway. So this is the (so far) final version:

0. Pre-requisites in Android Developer Settings

- OEM Unlock

- USB Debugging

1. Unlock Bootloader:

adb reboot-bootloader

fastboot flashing unlock

- Now the phone will be completely wiped

- Now the phone will reboot into Android

2. Root & also update + re-root:

- Download latest factory image and extract it

adb reboot-bootloader

fastboot devices #to check if device is detected

fastboot flash bootloader xxx.img #updating to latest bootloader from downloaded image

fastboot reboot-bootloader

fastboot flash radio xxx.img #updating to latest radio from downloaded image

fastboot reboot-bootloader

fastboot --disable-verity --disable-verification update xxx.zip #updating to latest version and (again) disabling verification.

- Now the phone will reboot into Android without being wiped

- Install latest canary Magisk

- Extract and copy boot.img from factory image to phone

- Patch boot.img with Magisk

- Copy patched boot.img to PC

adb reboot-bootloader

fastboot flash boot magisk_patched_boot.img

fastboot reboot

3. Disable automatic OTA updates

- Settings -> Developer Options -> Disable Automatic System Updates
[Google Pixel 6 Pro] roirraW "edor" ehT:
From memory, although that's certainly advisable and wise, you can just not let it update when it tells you there's an update available, but anyone please correct me if I'm wrong.

Edit: And what @Utini said, OTAs would ultimately fail on a rooted device anyway (with no particular harm).
[Google Pixel 6 Pro] roirraW "edor" ehT:
I would consider moving #3 up with #0 or between 0 and 1, anyway, since there's no reason not to go ahead and disable OTAs while in Developer settings already for the other two toggles.
[Google Pixel 6 Pro] Markelijk:
Oh really? That's good to know. I will however still choose to disable the setting, just to be sure :p
[Google Pixel 6 Pro] V0latyle:
I really don't think Google will actively try to prevent root. If that were true, why would they sell devices with unlockable bootloaders? Android was always meant to be open source, so even the code used for security functions is freely available. The only things you won't find are proprietary trade secrets - like whatever low level code they use for the Tensor and Titan M chips. Android itself, however, doesn't even need to be dissected or reverse engineered - you can download the actual source code. The point of the Pixel devices is a vanilla Android experience. There's very little proprietary code on our devices, if any, and Google isn't interested in the "walled garden" developer philosophy like you see with Apple products.
[Google Pixel 6 Pro] Bandsalat:
I never said they would try to prevent root. I agree that's unlikely.

But trying to prevent hiding the presence of root access, manipulated images, debug settings, etc.? Very much so
[Google Pixel 6 Pro] Jiggs82:
Hey guys I'm getting a frustrated and confused 😩 I just got my 6Pro coming from Pixel 5 and other pixels so I'm not a noob like that but I had took the Nov. OTA and then factory reset but for some reason the stock boot.img doesn't want to patch via magisk canary v23.0 , I didn't update the magisk to the latest version but it didn't matter on my Pixel 5 so can someone tell me what procedure/steps do I need to do in order to patch stock Nov. boot.img and get root via fastboot?

Thanks in advance
[Google Pixel 6 Pro] Lughnasadh:
You need to be on Canary 23.010 over later. The latest is 23.013 and I would use that.
[Google Pixel 6 Pro] Jiggs82:
Thanks that worked bro lol but another question how do I get gpay to work with this new magisk? Thanks
[Google Pixel 6 Pro] Lughnasadh:
Check out the safetynet, Magisk and MHPC threads. I don't use Gpay so can't directly answer you off the top of my head, but probably requires the latest safetynet fix mod (2.2).

https://xdaforums.com/t/working-safetynet-with-pixel-6-pro-android-12.4354149/
[Google Pixel 6 Pro] RetroTech07:
What? Just extract the boot.img from the full factory image. Why create extra steps for yourself?
[Google Pixel 6 Pro] avid_droid:
That's why. Cause I don't see it in there
[Google Pixel 6 Pro] avid_droid:
Maybe when I put it on my PC it'll be there....
[Google Pixel 6 Pro] s3axel:
No, don't think so - the OTA is flashed "as is", so no unpacking on the PC....

As you already correctly wrote you can get the boot.img via payload dumper, so that is a valid way. Less effort is probably just extracting from the factory image, as in there it isn't packaged like in the OTA. But both ways are just fine in the end ;)
[Google Pixel 6 Pro] avid_droid:
Yeah thank you for clarifying what my intention was haha. That's the only way I know how to get boot.img. Thank you
[Google Pixel 6 Pro] RetroTech07:
Because you're viewing the OTA file, not the factory image. Do you ever keep both the OTA and factory images on your PC?
[Google Pixel 6 Pro] avid_droid:
Negative. Only full OTA. I was actually referring to instructions in OP. It says to open device image build number zip for factory boot. That's where I got confused.
[Google Pixel 6 Pro] RetroTech07:
How can you say negative when you literally posted a screenshot with the OTA in the title of the file you were viewing??

Just open the factory image zip, open up the other zip file inside of it and extract the boot image.
[Google Pixel 6 Pro] avid_droid:
Dude you asked if I keep OTA and factory on my PC. That's what the "negative" comment was about. You know what? Nevermind. I don't have anything on my PC yet because I haven't gotten to my PC yet. I'm currently at work and just got my bootloader unlocked today. This whole thing was a simple question as to payload dump or extract the boot from a file that I clearly don't see on my phone after downloading the Factory zip. I'll just do the way I know how and leave it at that.
[Google Pixel 6 Pro] RetroTech07:
My bad dude, I was reading things too fast as I was going back and forth between other posts so I wasn't putting 2+2 together. Sorry if I came across as snappy, not my intention at all.

I suggest keeping both the OTA and full factory images in case you ever need them for a variety of reasons.
[Google Pixel 6 Pro] avid_droid:
Hahaha all good. As being a frequent flyer on XDA for years,it's expected haha. Rooting in a bit
[Google Pixel 6 Pro] V0latyle:
You CAN unpack the OTA using Payload Dumper.

Personally I just find it easier to use the factory image.

You missed the step where I specifically said to download the factory image. It's important to follow instructions to the letter.
[Google Pixel 6 Pro] andreipaval:
I did exactly the steps described there and updated via OTA without any issue.

Pixel 6 booted just fine after the update, at the first attempt, root was still there with all the configs like DenyList.

No PC was needed for this update.
[Google Pixel 6 Pro] avid_droid:
Thanks. I just did the payload dumper way as I will be flashing a kernel so I need the other files if kernels aren't to my liking. Rooted and fully set up and good to go
[Google Pixel 6 Pro] Lycidias:
I was on a custom kernel, that was my problem
[Google Pixel 6 Pro] Lughnasadh:
Yep. Those other images that come with custom kernels now (dtbo, vendor boot, etc.) also need to be restored to stock since Magisk only restores the stock boot image. And it also may be restoring the custom kernel's boot image instead of the stock boot image, depending.

@Homeboy76 You may want to put a cavaet in your guides about needing to be on stock kernel to be able to use the install to inactive slot or sideload method if you haven't already. 👍
[Google Pixel 6 Pro] s3axel:
That is a good and important point ! I could not update using the downloaded OTA image via sideload until as I was on a custom kernel (got an error 21 in ADB when sideloading).

I needed to flash back all modified images (vendor_boot, vendor_dlkm and dtbo - instructions e.g. here) to stock from the original January ROM and after that could finally sideload the february OTA.
[Google Pixel 6 Pro] Enddo:
I'm also having trouble installing the February OTA

my regular pixel 6 only has magisk installed, though. no custom kernel right now

I haven't tried via sideload. only using the built-in updater. but I assume the issue/error is the same?
[Google Pixel 6 Pro] pavelcheto:
For me the uninstall magisk didn't work. It says no images found. I am following the guide to sideload the OTA update. On step "6. Boot the master root image (See note 1): " - So now I have to download the full factory zip, extract the boot.img, copy it to the phone, patch it with magisk, copy it back to the pc and then boot it? So it is the same procedure as the initial root or am I missing something?
[Google Pixel 6 Pro] s3axel:
I would have thought that when being rooted you cannot install the OTA via system - you have to use one of the methods described in OP....
[Google Pixel 6 Pro] V0latyle:
Same procedure. If you're downloading the factory zip, just use the dirty flash factory image method so you don't have to waste bandwidth on the OTA.

Not true, you just have to restore the stock boot image in Magisk. Instructions in OP have been updated.
[Google Pixel 6 Pro] pavelcheto:
I do not understand then what is the point of the Update and Root OTA guide if I still have to download and patch the boot.img from the full factory zip?
[Google Pixel 6 Pro] V0latyle:
You shouldn't have to - either you're doing something wrong, or you're having a unique problem.

I have updated the OP with the procedure to follow for automatic OTAs.

For the time being, however, if you aren't having any luck with the OTA, just follow the factory image method. If you already have a patched boot image from a previous update, you don't have to patch the new one - just dirty flash the factory image, then live boot the old patched image to gain temporary root, and use Direct Install in Magisk to patch the new boot image.
[Google Pixel 6 Pro] pavelcheto:
I tried that. The phone didn't boot. There was a message that the data is corrupted and it cannot start. So I downloaded the full factory zip and got the up to date boot.img, patched, now it seems everything works.

Thanks for the information.
[Google Pixel 6 Pro] V0latyle:
Keep that new patched image.

I don't know what exact process you followed but a point of note: if the OTA process is interrupted, or if a different boot image is substituted, you'll have problems. If you either forget or have problems rooting during an automatic OTA, simply let it boot without root and "settle", maybe even reboot once more. At -that- point it should be safe to boot whatever image you want. If you interrupt the reboot process during OTA and try to substitute a different boot image than what it just flashed, the system will mark the boot as failed.