How To Guide [GUIDE] Pixel 6 Pro "raven": Unlock Bootloader, Update, Root, Pass SafetyNet

Search This thread

V0latyle

Forum Moderator
Staff member
I do use AdAway so that explains that. But it was still under modules, so I think I did the right thing by uninstalling it before trying (and failing) to update.
I use Systemless Hosts for AdAway as well, and have never needed to disable it when updating. The module does not change anything in /system; instead, it "hijacks" where the kernel looks for the hosts file and redirects it to the custom hosts file managed by the ad blocker.

I also use Universal Safetynet Fix and MagiskHide Props Config; I haven't needed to disable either of these when updating.
 

sronweb

Senior Member
Jul 25, 2010
1,417
490
Sicily
Asus ZenPad 10
OnePlus 6T
I have a rooted and unlocked Pixel 6 Pro, with last alpha magisk and I'm going to install June's OTA update.
This is my first time I do it, so if I understand correctly would be just required to follow these steps?

  • Before you download the OTA, open Magisk, tap Uninstall, then Restore Images. If you have any Magisk modules that modify system, uninstall them now.
  • Take the OTA update when prompted. To check for updates manually, go to Settings > System > System Update > Check for Update
  • Allow the update to download and install. DO NOT REBOOT WHEN PROMPTED. Open Magisk, tap Install at the top, then Install to inactive slot. Magisk will then reboot your device

I see other users need to patch the update before but it should not be required with these steps?
Thanks
 
  • Like
Reactions: m_ben

V0latyle

Forum Moderator
Staff member
I have a rooted and unlocked Pixel 6 Pro, with last alpha magisk and I'm going to install June's OTA update.
This is my first time I do it, so if I understand correctly would be just required to follow these steps?

  • Before you download the OTA, open Magisk, tap Uninstall, then Restore Images. If you have any Magisk modules that modify system, uninstall them now.
  • Take the OTA update when prompted. To check for updates manually, go to Settings > System > System Update > Check for Update
  • Allow the update to download and install. DO NOT REBOOT WHEN PROMPTED. Open Magisk, tap Install at the top, then Install to inactive slot. Magisk will then reboot your device

I see other users need to patch the update before but it should not be required with these steps?
Thanks
What do you mean "patch the update before"? These instructions are correct; Android system downloads and unpacks the OTA, then installs it to the inactive slot; when the system reboots, it switches to the updated slot.

When you use "Install to inactive slot" in Magisk, it patches the boot image in the inactive slot. So, the idea is, you install the update, but before you reboot to the updated slot, you use Magisk to patch the new boot image, so you should seamlessly boot into the updated slot with root.
 

sronweb

Senior Member
Jul 25, 2010
1,417
490
Sicily
Asus ZenPad 10
OnePlus 6T
What do you mean "patch the update before"? These instructions are correct; Android system downloads and unpacks the OTA, then installs it to the inactive slot; when the system reboots, it switches to the updated slot.

When you use "Install to inactive slot" in Magisk, it patches the boot image in the inactive slot. So, the idea is, you install the update, but before you reboot to the updated slot, you use Magisk to patch the new boot image, so you should seamlessly boot into the updated slot with root.
Thank you for the reply. Now I understand what you mean, but something went wrong, in the last step, which is flashing of magisk, I have selected the canary version which was saved, and then, after flashing the phone stuck for while with Google logo. When I rebooted i see it shows that the device is corrupted.
I could reboot the device but actually I lost root, I'm checking if I can get it without wiping again from scratch the device....
If I try to flash Magisk.zip then I get the message "unsupported image format", I guess I messed up....
 

roirraW "edor" ehT

Forum Moderator
Staff member
Thank you for the reply. Now I understand what you mean, but something went wrong, in the last step, which is flashing of magisk, I have selected the canary version which was saved, and then, after flashing the phone stuck for while with Google logo. When I rebooted i see it shows that the device is corrupted.
I could reboot the device but actually I lost root, I'm checking if I can get it without wiping again from scratch the device....
If I try to flash Magisk.zip then I get the message "unsupported image format", I guess I messed up....
There have been many cases where users have gotten the corruption problem. Sometimes flashing an old boot.img (for example, from May) will fix it. If trying to flash the full firmware zip (with -w removed so it doesn't wipe your phone) doesn't help, you can always try Official Google Android Flash Tool (OEM Unlocking needs to be toggled on - you may not have to manually unlock the bootloader - the "site" will do that on its own).

Many, many others have found that site to fix things that even the full firmware zip didn't fix.
 

sronweb

Senior Member
Jul 25, 2010
1,417
490
Sicily
Asus ZenPad 10
OnePlus 6T
There have been many cases where users have gotten the corruption problem. Sometimes flashing an old boot.img (for example, from May) will fix it. If trying to flash the full firmware zip (with -w removed so it doesn't wipe your phone) doesn't help, you can always try Official Google Android Flash Tool (OEM Unlocking needs to be toggled on - you may not have to manually unlock the bootloader - the "site" will do that on its own).

Many, many others have found that site to fix things that even the full firmware zip didn't fix.
Thanks for the suggestion. I'm going to start flashing from Flash Tool and If I select June build, disabled Lock, then Flash
 

V0latyle

Forum Moderator
Staff member
Thanks for the suggestion. I'm going to start flashing from Flash Tool and If I select June build, disabled Lock, then Flash
Make sure you are following the instructions in the guide. Do not try to substitute your own ideas. The only way Magisk can be "flashed" is via a custom recovery such as TWRP, which to my knowledge has not been ported to Android 12 or the Pixel 6.

Also, if you're using an alpha version of Magisk, I suggest that you use the official Canary. Not all alphas have the necessary fixes and updates.
 

Lughnasadh

Senior Member
Mar 23, 2015
3,513
3,601
Google Nexus 5
Huawei Nexus 6P

roirraW "edor" ehT

Forum Moderator
Staff member
safetynet-fix v2.3.1 is released.

v2.3.1​

Latest

@kdrag0n
kdrag0n released this 3 hours ago
· 3 commits to master since this release
v2.3.1
f79e5cc

Changes​

Highlights​

  • Fixed fingerprint on OxygenOS/ColorOS 12 (@osm0sis)
  • Support for Magisk 24+ module updates (@benjibobs)
  • Restored support for Android 7

Other changes​

  • Spoofed OnePlus OEM unlock status for futureproofing (@osm0sis)
  • Minor code improvements
This version only supports Zygisk (Magisk 24 and newer).

Donate​

If you found this helpful, please consider supporting development with a recurring donation for rewards such as early access to updates, exclusive behind-the-scenes development news, and priority support. Alternatively, you can also buy me a coffee. All support is appreciated ❤️

Contributors​

osm0sis and benjibobs

Assets​

3
19 people reacted
👍12🎉4❤️10
0Join discussion
 

fil3s

Senior Member
Aug 30, 2014
1,506
358
43
bendigo
mobiledevices11.blogspot.com
HuskyDG bootloop saver now allows you to patch the boot.img

Magisk modules will remain if you update your system and patch boot.img again

If you have any incompatible modules, this will trigger your device to not boot. Patching boot with Husky DG bootloop saver will survive a system update

 

mcwups1

Senior Member
May 4, 2011
2,469
481
Google Pixel 6 Pro
Anyone been able to get V4A to work after June update? I keep getting a "No Driver Found" message and it DL's and reboots, but does it over and over.

TIA
 

punishermoose

Member
Nov 12, 2013
17
2
LG V20
Essential Phone
I just did the OTA sideload update method and I'm having an issue getting my P6P to boot from fastboot using the newly created patched boot.img. The boot sequence starts and the "G" spins up, progess bar is moving, but then it just goes back to the unlocked bootloader warning and then boots normally giving no root. After boot, opening Magisk Canary25101 only presents with "patch a file", which I already did to create the patched boot.img. I used the boot.img file found in the raven-sq3a.220605.009.b1-factory-157e2284.zip.

On another note
Anyone been able to get V4A to work after June update? I keep getting a "No Driver Found" message and it DL's and reboots, but does it over and over.

TIA
I would also like to know if this is a problem that others are having, otherwise rooting my phone is pointless; the only reason I bother is for V4A.
 
  • Like
Reactions: vibrantliker

Lughnasadh

Senior Member
Mar 23, 2015
3,513
3,601
Google Nexus 5
Huawei Nexus 6P
I just did the OTA sideload update method and I'm having an issue getting my P6P to boot from fastboot using the newly created patched boot.img. The boot sequence starts and the "G" spins up, progess bar is moving, but then it just goes back to the unlocked bootloader warning and then boots normally giving no root. After boot, opening Magisk Canary25101 only presents with "patch a file", which I already did to create the patched boot.img. I used the boot.img file found in the raven-sq3a.220605.009.b1-factory-157e2284.zip.

On another note

I would also like to know if this is a problem that others are having, otherwise rooting my phone is pointless; the only reason I bother is for V4A.
Do you have any Magisk mods that may need disabling and updating to be compatible with the Junes security patch? You can flash the patched image and then boot into safe mode and then reboot and that will disable all your mods. If you can boot up after this with the patched boot image you likely have a mod that needs updating.
 
  • Like
Reactions: roirraW "edor" ehT

punishermoose

Member
Nov 12, 2013
17
2
LG V20
Essential Phone
Do you have any Magisk mods that may need disabling and updating to be compatible with the Junes security patch? You can flash the patched image and then boot into safe mode and then reboot and that will disable all your mods. If you can boot up after this with the patched boot image you likely have a mod that needs updating.
I had usnf, acp, aml, v4a, systemless hosts (although I wasn't using adaway). All were disabled, and I can no longer see any of them through magisk, because it is not installed properly (no root).
 

punishermoose

Member
Nov 12, 2013
17
2
LG V20
Essential Phone
When you flashed the patched boot image in fastboot, are you using the latest Platform Tools?
Yes, I just downloaded the latest set before beginning the process today.

Also, just to make sure I have my head around this, conceptually; I m not actually "flashing" the patched boot image, just using it as a placeholder to kickstart my device, right? Otherwise booting would just fail and not fall back to the non-patched boot image. Please don't be offended, it seems like I'm learning this all over again and want to make sure I get it right.
 
Last edited:

Top Liked Posts

  • There are no posts matching your filters.
  • 4
    Folks, I'm going to ask that for further discussion of GPay/Wallet vs Magisk, please take it to this thread. The issues you are having are not isolated to the Pixel 6 / 6 Pro; many other users are having the same problems.

    Let's keep this thread on topic, please.
    4
    Why do you guys root your phone anymore ?
    I root my phone so I can back it up in order to restore stuff after sideloads go wrong like they just did. Some data doesn't get backed up otherwise.,
    4
    My bad. The articles I have seen the past couple of days stated that Google pay was being replaced by Google wallet every where except the US and I think Singapore. I presumed that the US was not getting wallet. I stand corrected. :)
    I believe some Wallet functions are limited in the US, such as being able to upload your driver's license. But, for payment, mine seems to work fine.
    3
    I did not find an A13 root specific thread, so posting here. For an already rooted phone on A12, Magisk 25101, I read that the process to flash A13 is the same. I even read that disabling verity ("flash vbmeta --disable-verity....) may no longer needed. I read something similar in John Wu's thread about disabling verity being a part of Magisk now.

    Is all of the above true?
    Is there any harm in manually disabling verity before first boot anyway?
    Along with SafetyNetFix 2.3.1, are there any new root issues on A13?

    Many thanks.
    Root process is the same for A13 as it is on A12.

    Disabling verity and/or verification is not required, but can be of help when unexpected things arise. I've had both disabled since I got the phone with no problems. If you are disabling them for the first time you will have to wipe (except if you just disable verity alone, then it's likely you won't have to wipe). If you want to keep them disabled you will have to disable with each monthly update. You won't have to wipe when updating unless you boot with them enabled and then want to disable. So disable before booting when doing monthly updates.

    Magisk does not disable verity and verification and no longer strips the avb key from fstab entries as it did before.
    3
    That just refers to a specific bug that cropped up on A13B2, Canary 24309, if I remember correctly, where it was required that verity and verification be disabled in order to avoid a bootloop. It was fixed in the next Canary.

    Appreciate the clarification!
  • 87
    If you are looking for my guide on a different Pixel, find it here:
    Update 6-20-22: Magisk 25.1 is recommended as this includes fixes for OTA updates, as well as support for the Android 13 beta.
    Discussion thread for migration to 24.0+.

    DO NOT use any version of Magisk lower than Canary 23016 as it does not yet incorporate the necessary fixes for Android 12 and your device.


    WARNING: YOU AND YOU ALONE ARE RESPONSIBLE FOR ANYTHING THAT HAPPENS TO YOUR DEVICE. THIS GUIDE IS WRITTEN WITH THE EXPRESS ASSUMPTION THAT YOU ARE FAMILIAR WITH ADB, MAGISK, ANDROID, AND ROOT. IT IS YOUR RESPONSIBILITY TO ENSURE YOU KNOW WHAT YOU ARE DOING.

    Prerequisites:


    Android Source - Setting up a device for development


    1. Follow these instructions to enable Developer Options and USB Debugging.
    2. Enable OEM Unlocking. If this option is grayed out, unlocking the bootloader is not possible.
    3. Connect your device to your PC, and open a command window in your Platform Tools folder.
    4. Ensure ADB sees your device:
      Code:
      adb devices
      If you don't see a device, make sure USB Debugging is enabled, reconnect the USB cable, or try a different USB cable.
      If you see "unauthorized", you need to authorize the connection on your device.
      If you see the device without "unauthorized", you're good to go.
    5. Reboot to bootloader:
      Code:
      adb reboot bootloader
    6. Unlock bootloader: THIS WILL WIPE YOUR DEVICE!
      Code:
      fastboot flashing unlock
      Select Continue on the device screen.

    1. Install Magisk on your device.
    2. Download the factory zip for your build.
    3. Inside the factory zip is the update zip: "device-image-buildnumber.zip". Open this, and extract boot.img
    4. Copy boot.img to your device.
    5. Patch boot.img with Magisk: "Install" > "Select and Patch a File"
    6. Copy the patched image back to your PC. It will be named "magisk_patched-23xxx_xxxxx.img". Rename this to "master root.img" and retain it for future updates.
    7. Reboot your device to bootloader.
    8. Flash the patched image:
      Code:
      fastboot flash boot <drag and drop master root.img here>
    9. Reboot to Android. Open Magisk to confirm root - under Magisk at the top, you should see "Installed: <Magisk build number>

    1. Before you download the OTA, open Magisk, tap Uninstall, then Restore Images. If you have any Magisk modules that modify system, uninstall them now.
    2. Take the OTA update when prompted. To check for updates manually, go to Settings > System > System Update > Check for Update
    3. Allow the update to download and install. DO NOT REBOOT WHEN PROMPTED. Open Magisk, tap Install at the top, then Install to inactive slot. Magisk will then reboot your device.
    4. You should now be updated with root.

    1. Download the OTA.
    2. Reboot to recovery and sideload the OTA:
      Code:
      adb reboot sideload
      Once in recovery:
      Code:
      adb sideload ota.zip
    3. When the OTA completes, you will be in recovery mode. Select "Reboot to system now".
    4. Allow system to boot and wait for the update to complete. You must let the system do this before proceeding.
    5. Reboot to bootloader.
    6. Boot the master root image (See note 1):
      Code:
      fastboot boot <drag and drop master root.img here>
      Note: If you prefer, you can download the factory zip and manually patch the new boot image, then flash it after the update. Do not flash an older boot image after updating.
    7. Your device should boot with root. Open Magisk, tap Install, and select Direct Install.
    8. Reboot your device. You should now be updated with root.
    Note: You can use Payload Dumper to extract the contents of the OTA if you want to manually patch the new boot image. However, I will not cover that in this guide.

    Please note that the factory update process expects an updated bootloader and radio. If these are not up to date, the update will fail.
    1. Download the factory zip and extract the contents.
    2. Reboot to bootloader.
    3. Compare bootloader versions between phone screen and bootloader.img build number
      Code:
      fastboot flash bootloader <drag and drop new bootloader.img here>
      If bootloader is updated, reboot to bootloader.
    4. Compare baseband versions between phone screen and radio.img build number
      Code:
      fastboot flash radio <drag and drop radio.img here>
      If radio is updated, reboot to bootloader.
    5. Apply update:
      Code:
      fastboot update --skip-reboot image-codename-buildnumber.zip
      When the update completes, the device will be in fastbootd. Reboot to bootloader.
    6. Boot the master root image (See note 1):
      Code:
      fastboot boot <drag and drop master root.img here>
      Note: If you prefer, you can manually patch the new boot image, then flash it after the update. Do not flash an older boot image after updating.
    7. Your device should boot with root. Open Magisk, tap Install, and select Direct Install.
    8. Reboot your device. You should now be updated with root.
    Note: If you prefer, you can update using the flash-all script included in the factory zip. You will have to copy the script, bootloader image, radio image, and update zip into the Platform Tools folder; you will then have to edit the script to remove the -w option so it doesn't wipe your device.
    The scripted commands should look like this:
    Code:
    fastboot flash bootloader <bootloader image name>
    fastboot reboot bootloader
    ping -n 5 127.0.0.1 > nul
    fastboot flash radio <radio image name>
    fastboot reboot bootloader
    ping -n 5 127.0.0.1 > nul
    fastboot update  --skip-reboot --slot=all <image-device-buildnumber.zip>
    Once this completes, you can reboot to bootloader and either boot your master patched image, or if you patched the new image, flash it at this time.

    PixelFlasher by @badabing2003 is an excellent tool that streamlines the update process - it even patches the boot image for you. Please note that root access is required to patch.
    1. Download PixelFlasher and the factory image. You do not need to extract the factory image.
    2. Open PixelFlasher. Point the Android Platform Tools directory (browse for your Platform Tools folder)
    3. Point the Factory Image directory to the factory image package you just downloaded.
    4. Connect your device via USB. Ensure it shows up under ADB Connected Devices.
    5. Click the button to the right of the factory image Browse button (looks like a meat grinder). This will extract the boot image from the factory package.
    6. When the boot image appears in the list, click on it and click Patch. A root request should pop up on your device; this is PixelFlasher requesting shell root access through ADB. Make sure you approve it.
    7. PixelFlasher will automatically copy the boot image to your device, patch it in Magisk, then copy it back to your PC. The patched image should now appear in the boot image list.
    8. Select the patched boot image, the desired flash mode (Keep Data), and click Flash Pixel Phone.
    9. Pixel Flasher will automatically update bootloader, radio, system, then finally flash the patched boot image.
    10. When your device boots, you should be updated with root.

    1. Follow the instructions on the Android Flash Tool to update your device. Make sure Lock Bootloader and Wipe Device are UNCHECKED.
    2. When the update completes, the device will be in fastbootd. Reboot to bootloader.
    3. Boot the master root image (See note 1):
      Code:
      fastboot boot <drag and drop master root.img here>
      Note: If you prefer, you can download the factory zip and manually patch the new boot image, then flash it after the update. Do not flash an older boot image after updating.
    4. Your device should boot with root. Open Magisk, tap Install, and select Direct Install.
    5. Reboot your device. You should now be updated with root.

    This is my configuration that is passing Safety Net. I will not provide instructions on how to accomplish this. Attempt at your own risk.

    Zygisk + DenyList enabled
    All subcomponents of these apps hidden under DenyList:
    • Google Play Store
    • GPay
    • Any banking/financial apps
    • Any DRM media apps
    Modules:
    To check SafetyNet status:
    I do not provide support for Magisk or modules. If you need help with Magisk, here is the Magisk General Support thread. For support specifically with Magisk v24+, see this thread.

    Points of note:
    • The boot image is NOT the bootloader image. Do not confuse the two - YOU are expected to know the difference. Flashing the wrong image to bootloader could brick your device.
    • While the Magisk app is used for patching the boot image, the app and the patch are separate. This is what you should see in Magisk for functioning root:
      screenshot_20211218-194517-png.5486339
    • "Installed" shows the version of patch in the boot image. If this says N/A, you do not have root access - the boot image is not patched, or you have a problem with Magisk.
    • "App" simply shows the version of the app itself.
    • If you do not have a patched master boot image, you will need to download the factory zip if you haven't already, extract the system update inside it, then patch boot.img.
    • If you prefer updating with the factory image, you can also extract and manually patch the boot image if desired.
    • Some Magisk modules, especially those that modify read only partitions like /system, may cause a boot loop after updating. As a general rule, disable these modules before updating. You are responsible for knowing what you have installed, and what modules to disable.


    Credits:
    Thanks to @ipdev , @kdrag0n , @Didgeridoohan , and last but not least, @topjohnwu for all their hard work!
    9
    Magisk Stable is now at version 24.1, so I will no longer be providing any Magisk updates.

    You can use any version of Magisk now - Stable, Beta, or Canary. as long as it is 23016 or newer.

    Once again, if you want to switch versions of Maagisk, it is HIGHLY RECOMMENDED that you "Complete Uninstall" within Magisk before installing the new version. Multiple instances of Magisk can break root.

    If you simply want to update Magisk, the best way to do so is from within the app.


    Once the February update is out, I will perform some testing with installing to inactive slot, and if it works, I will update this guide.

    Given the low activity on this thread, I will probably close it if everything goes well with the next update.

    Thank you all for your testing and contributions.
    8
    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.
    7
    Magisk Canary updated to 23019
    Changes:
    - [Zygisk] Skip loading modules into the Magisk app to prevent conflicts
    - [MagiskBoot] Change `zopfli` to a more reasonable config so it doesn't take forever
    - [General] Several `BusyBox` changes

    Preferred method of update is from within Magisk app.


    If installing for the first time, here is the APK Download
    7
    I just used this method, (same one described on Magisk website here https://topjohnwu.github.io/Magisk/ota.html) and it worked perfectly, both root and safetynet.
    Can someone explain to me why you see all kind of guide to update which are far more complicated than that ?
    Part of it is due to device differences - non A/B devices can't use seamless updates, so re-rooting is only possible by either patching the boot image directly, or by flashing Magisk in a custom recovery.

    Part of it is also due to user preferences. Some people, like me, prefer to update using the factory images, instead of OTA.

    And part of it is probably a bit of misinformation mixed in with anecdotes, where people who don't fully understand how the process works, but they declare that something has to be done a certain way because of what worked for them.

    I try to stick to the first two. I've spent a lot of time learning about how Android works, so I make a point of providing instructions that align with how everything is supposed to be done, while accommodating alternatives for those who want them.

    Are you 100% sure?

    Cause topjohnwu said that OTA patching from within Magisk was broken for Pixel devices.

    See here

    Notice the date of that post, 16 months ago. Magisk Canary 23017 re-incorporated the ability to install to inactive slots.

    I have been following the commits closely, so when 23017 was released, I announced it in my guides. Had you read back a couple pages, your question has been answered.

    If you don't believe me, check the commits here.