Google released the latest Android O Developer Preview 1 for the Nexus 6P, Nexus 5X, Player, Google Pixel (XL), and the Pixel C. The preview isn’t all that stable at the moment but has been installed on several Google devices. Nexus users are eagerly waiting to root the latest AOSP firmware based on Android 8.0 O. Chainfire, a recognized Android developer, Twitted about gaining basic root access on Android O DP1 on the primary Nexus 6P device. However today, the developer has built a new SuperSU version 2.79 SR4 beta version that will root the Nexus 6P, Nexus 5X on latest Developer Preview.
Root access, however, may or may not work on the Nexus Player or the Google Pixel C because it has not been tested yet. Due to the A/B partition layout in the Google Pixel and Pixel XL, there has been some complication in rooting these two flagships. Root access on these two devices can be expected in the next few builds of SuperSU. The first thing we need is to unlock the bootloader which you must have already done while flashing the Android O DP1 factory images. Secondly, setting up latest TWRP is not a problem because it can be flashed seamlessly just like that on Nougat AOSP.
Some notes from the developer about the SuperSU 2.79 SR4:
Both the 5X and 6P suffer from a kernel panic (of yet unknown origin) if SuperSU’s daemon loads at early boot. Due to this, on ODP1 exec mode is skipped, and even the service launch is delayed. As a result, su.d scripts are executed too late in the boot process to hijack system services before they launch. While most of you are probably not going to run into that, some might, and it is thus worth noting. (Most seem to think you need some sort of framework rather than a few lines of script for that sort of mod…)
This kernel panic may be a kernel issue only Google can solve, or it may be possible to work-around on our end, it is too soon to say.
Pixel and Pixel XL
These devices have the new A/B partition layout, and something is going wrong with the code that handles this. This is most likely something I can solve with some more time and effort. This part of the code is just very tricky and time-consuming to debug, as logging isn’t operational yet at this stage of booting.
Just because an app can gain root access doesn’t mean it’ll work. While O still seems very similar to Nougat, some things have changed. The syntax of some commands has changed (try ‘ps -A’ now instead of ‘ps’ for example). As expected, SELinux rules have been tightened some more, and this always has the chance of breaking some root apps. The point is – just because an app doesn’t work doesn’t necessarily mean something in SuperSU is broken (it could be, though).
How to Root Android O Developer Preview on Nexus 6P/5X with SuperSU 2.79 SR4?
This is a preliminary root tested on Nexus 6P and Nexus 5X running on Android O DP1. Nexus Player and Pixel C may or may not work but you can still try it. There will be more SuperSU 2.79 SR4 builds coming our way for a stable root for the same. Chainfire clearly says the new Super User version works very well on 5X and 6P and you need to flash it via custom TWRP recovery. It won’t work on Google Pixel or Pixel XL at this moment.
Prerequisites to root Android O
1. Verify device for compatibility. Works only on Nexus 6P and Nexus 5X. Nexus Player and Pixel C needs testing.
2. Unlocked bootloader is required on the latest Android O DP1.
4. Flash latest SuperSU 2.79 SR4 (Download SuperSU-v2.79-SR4-20170323220017-ODP1-5X-6P.zip)
Android O Rooting instructions
Step 1: Make sure your Nexus device is running the latest Android O Developer Preview.
Step 2: Also, make sure the phone’s bootloader is unlocked and TWRP is setup.
Step 3: Now, download the latest SuperSU 2.79 SR4 and transfer the file to phone’s internal storage.
Step 4: Reboot into latest TWRP recovery.
Step 5: Tap on Backup and take a full Nandroid backup selecting all the partitions like System, Data, Boot, EFS, etc.
Step 6: Now, return to home screen and tap on Install and select the latest SuperSU-v2.79-SR4-20170323220017-ODP1-5X-6P.zip file from the storage.
Step 7: Reboot to system and start granting root access to all the root apps via SuperSU APK.
First boot may take some time. If it fails, you can factory reset the phone via TWRP or simply restore the previous backup. That’s it, enjoy root on the latest Android O Developer Preview with the latest SuperSU version.
Thanks to: Chainfire