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

Search This thread
Hey guys,
i updated to Android 13 today, turned off all modules before flashing.Booted fine
After I re-activated some modules, also a Font Module, but its bootlooping now.
i tried to boot into safe mode, it starts and shows safemode, but after entering the pin code its just a black screen blinking, and instantly rebooting again.
it also boots into recovery where i can choose try again or factory reset.
Tried to flash the factory image again, but no success, at some point im in revocery, try again or factory reset.
Soemthing seems to be broken or corrupted.....
Any idea how to get it back without factory reset?
And i have to to factory reset, do i still have to patch the vendor image or was it vbmeta??

Mhh even flashing vbmeta doesnt help ****...

fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img is not necessary if i boot or flash the patched kernel correct?
 
Last edited:

Jeryhho

Senior Member
Dec 12, 2014
51
6
I have the latest magisk canary build, and the OTA update is not working. I restore images in magisk -> OTA install -> reboot -> bootloop. I am not installing the latest android because bootloop performed on all Android 12 builds. How can I install OTA without bootloop?
 

V0latyle

Forum Moderator
Staff member
Hey guys,
i updated to Android 13 today, turned off all modules before flashing.Booted fine
After I re-activated some modules, also a Font Module, but its bootlooping now.
i tried to boot into safe mode, it starts and shows safemode, but after entering the pin code its just a black screen blinking, and instantly rebooting again.
it also boots into recovery where i can choose try again or factory reset.
Tried to flash the factory image again, but no success, at some point im in revocery, try again or factory reset.
Soemthing seems to be broken or corrupted.....
Any idea how to get it back without factory reset?
Your bootloop appears to be caused by a Magisk module. Boot into Safe Mode by holding the Volume Down button after the unlocked bootloader warning appears. Magisk should detect safe mode and suspend modules. Disable them all, and enable one at a time followed by a reboot until you discover which module is causing the problem. Modules that change system function or appearance on Android 12 may not work correctly on Android 13. For more help, post in the Magisk General Support/Discussion thread.
And i have to to factory reset, do i still have to patch the vendor image or was it vbmeta??
Neither - factory reset only wipes /data and does not restore any images.
Mhh even flashing vbmeta doesnt help ****...
Because this appears to be a Magisk module issue. The stock (unpatched) boot image should boot but you won't have root.
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img is not necessary if i boot or flash the patched kernel correct?
No, not necessary.
 
  • Like
Reactions: tensux

V0latyle

Forum Moderator
Staff member
I have the latest magisk canary build, and the OTA update is not working. I restore images in magisk -> OTA install -> reboot -> bootloop. I am not installing the latest android because bootloop performed on all Android 12 builds. How can I install OTA without bootloop?
Restore images (unless you haven't re-rooted) and install the OTA normally. Do not attempt to patch the inactive slot. Let the system boot normally (without root) and finish the update including all optimizations. Then, you can download the factory package, and extract and patch the boot image.

Alternatively, since you would need to download the factory package anyway, just update that way. Pixel Flasher makes it much easier, although you'll need to start with root so that Pixel Flasher can patch the boot image.
 
  • Like
Reactions: Jeryhho
Your bootloop appears to be caused by a Magisk module. Boot into Safe Mode by holding the Volume Down button after the unlocked bootloader warning appears. Magisk should detect safe mode and suspend modules. Disable them all, and enable one at a time followed by a reboot until you discover which module is causing the problem. Modules that change system function or appearance on Android 12 may not work correctly on Android 13. For more help, post in the Magisk General Support/Discussion thread.

Neither - factory reset only wipes /data and does not restore any images.

Because this appears to be a Magisk module issue. The stock (unpatched) boot image should boot but you won't have root.

No, not necessary.
tried safemode already, phone boots up, but after entering the pin, no homescreen, phone just flickers and reboots....
have to go fresh i guess...
 

V0latyle

Forum Moderator
Staff member
tried safemode already, phone boots up, but after entering the pin, no homescreen, phone just flickers and reboots....
have to go fresh i guess...
Well, I'm trying to help.

What happens if you boot the stock boot image? If it's the same thing, you may have a different issue.
 
  • Like
Reactions: mbonus

V0latyle

Forum Moderator
Staff member
same result....
i did a clean flash now, after i just patch the patched A13 kernel and im good?
didnt know that the verity stuff isnt needed anymore, makes it more easy then
I was going to recommend sideloading the OTA (or dirty flashing the system image) to see if that fixes the stability issue. Most times, wiping your device shouldn't be necessary.

From this point, you just need to patch the A13 boot image. You can either flash it in bootloader, or if you want to be able to update via OTA, live boot it and perform Direct Install in Magisk.
 
  • Like
Reactions: pa.pn2
I was going to recommend sideloading the OTA (or dirty flashing the system image) to see if that fixes the stability issue. Most times, wiping your device shouldn't be necessary.

From this point, you just need to patch the A13 boot image. You can either flash it in bootloader, or if you want to be able to update via OTA, live boot it and perform Direct Install in Magisk.
i wrote with the creator of the font magisk module, its not compatible with A13 anymore, maybe it corrupted something...
 
  • Like
Reactions: V0latyle

gazdajezda

Senior Member
Apr 24, 2011
406
79
After install, A13 is perfectly root-able and all works ok as it should (adaway, safety net, banking apps)? Or last A12 will do fine? 10x
 

V0latyle

Forum Moderator
Staff member
After install, A13 is perfectly root-able and all works ok as it should (adaway, safety net, banking apps)? Or last A12 will do fine? 10x
Working great for me on my Pixel 5. Magisk 25201, with systemless hosts + AdAway. Using Displax mod USNF 2.3.1, passing SafetyNet, all my banking apps work including GPay/Wallet.
 

gazdajezda

Senior Member
Apr 24, 2011
406
79
Great 😀 Download factory image, patch boot.img, flash without -w and after that, flash patcjed boot.img - that's it, still?
 

squidbutt

Senior Member
May 30, 2008
406
14
suffolk
I used the ota that the phone sent me and before rebooting,went to magisk and patched inactive slot. Root retained with modules working. BCR 1.18 working also
 

Top Liked Posts

  • There are no posts matching your filters.
  • 3
    Thanks for easing my mind about this guys! So just a misunderstanding on my side. :)

    I was having some issues with applying an OTA update and keeping root through Magisk Manager and I thought that maybe for that to work both slots should have up-to-date, working firmware (and to test that I tried booting from them).

    Luckily I learned a lot from all this flashing, rooting, updating with adb, fastboot and PixelFlasher and I think that should I ever screw up a future update I should be able to recover without data loss pretty easy and quick now.
    1
    Not quite true...you just have to use bootctl to tell it to boot to the other slot. Simply setting the other slot active in bootloader short circuits the process.
    I was answering in the way that person was trying to do it without getting into more in depth details. I saw your earlier post.

    .........................
  • 47
    ⚠️⚠️⚠️WARNING! IF YOU ARE UPDATING TO ANDROID 13 FOR THE FIRST TIME, READ THIS FIRST! ⚠️⚠️⚠️

    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 <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.
    The application essentially automates the ADB interface to make updating and rooting much easier. However, it is STRONGLY recommended that you still learn the "basics" of using ADB.

    For instructions, downloads, and support, please refer to the PixelFlasher thread.

    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.

    SafetyNet has been deprecated for the new Play Integrity API. More information here.

    In a nutshell, Play Integrity uses the same mechanisms as SafetyNet for the BASIC and DEVICE verdicts, but uses the Trusted Execution Environment to validate those verdicts. TEE does not function on an unlocked bootloader, so legacy SafetyNet solutions will fail.

    However, @Displax has modified the original Universal SafetyNet Fix by kdrag0n; his mod is able to bypass TEE, meaning that the device will pass BASIC and DEVICE integrity.

    Mod available here. Do not use MagiskHide Props Config with this mod.

    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:
    • Universal SafetyNet Fix 2.3.1 Mod - XDA post
    To check SafetyNet status:
    To check Play Integrity 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!
    7
    Magisk Canary was updated to 23016 last night. This includes a fix for the vbmeta header issue, meaning that disabling verity/verification should no longer be required, and we should be able to root as we did before. This needs testing, make sure you back up your data and photos before you do this!

    Additionally, for the Pixel 6 and 6 Pro, fstab will now load from /system/etc which should fix the root issue many of you were having.

    Q: "If verity/verification are disabled, do I need to enable them now?"
    A: No. The only thing you have to do is update to Magisk 23016.
    Q: "Will enabling verity/verification wipe my data?"
    A: No.

    I will be updating the OP to reflect this.
    5
    Magisk 24306 (release notes) is now available on the canary channel, and I can confirm that the installation to the inactive slot OTA method is working for the April update.
    5
    Interesting. How did you command the reboot?

    When I tried to update this way on my wife's 5a, it bootlooped back to the original slot.
    I always follow these steps once I know the OTA is available:

    1. Open Magisk and select 'Uninstall Magisk -> Restore Images'
    2. Open Settings and Download/Install OTA *DO NOT REBOOT*
    3. Go back to Magisk and select 'Install -> Install to Inactive Slot (After OTA)' *DO NOT REBOOT*
    4. Go back to Settings and 'Reboot' to finalize the OTA
    5
    So, if I use this tool after rooting OTA updates will work and I'll still have root?

    Edit: And can you explain more clearly the process on how to do this?

    No, the tool does nothing to maintain root. It simply allows you to take the OTA. You will still need to reboot into fastboot and flash or boot from a patched boot image.

    The steps would be:
    1. Restore boot in the Magisk app
    2. Restore vbmeta in Vbmeta Patcher
    3. Take the OTA in System Updater
    4. Patch vbmeta in Vbmeta Patcher
    5. Patch the new boot image in the Magisk app and copy it to your computer
    6. Reboot into fastboot
    7. Boot from the new patched boot image
    8. Direct Install Magisk in the Magisk App
    As I noted the quote post, this process should be considered experimental until it has been more thoroughly tested. You should consider backing up any critical data before attempting it, in case something goes wrong.

    I'm working on another tool to make it a bit easier to acquire the new boot image in step 5, but that will likely be a few days. Hopefully we'll be able to install Magisk to the inactive slot on Pixel devices again in the future, which would consolidate steps 5-8.