If you are loving the new Android M Developer Preview 2 with build number MPZ79M on your Nexus 9 device, you might love it even more once it’s hacked open with root access. Root access is the only way you can begin installing those marvelous root-requiring apps and custom ROMs, so let’s check out how it’s done.
- Be running the latest Android M MPZ79M Developer preview 2 software update.
- Use the Google Nexus 9 only. You can root Nexus 5 and Nexus 6 on the same build using the respective links.
BEFORE WE BEGIN
- Download the Google USB Drivers  on the computer so you can connect the nexus device to the same computer without any worries.
- Unlock the Developer Options and then enter it from the Settings and enable the USB Debugging Mode if you haven’t already.
- The guide is for Windows operating systems only.
- You are voiding the warranty on the Nexus 9 by continuing.
HOW TO ROOT THE GOOGLE NEXUS 9 RUNNING ANDROID M MPZ79M DEVELOPER PREVIEW 2
- Download the Android SDK tool from the developer’s website here .
- Set up the ADB and Fastboot  on the Windows-based computer.
- Download Fastboot for Windows here .
- Download the TWRP here  and move the recovery to the same folder as fastboot on the computer.
- Download the ElementalX kernel here  to the computer and transfer it over to the internal nexus storage (SD card).
- Download the SuperSU here  to the computer.
- Copy and paste the SuperSU over to the internal storage SD card on your device.
- Completely switch off the Nexus by holding down the Power key for 10 seconds.
- Reboot it in Fastboot/Bootloader Mode ( Volume Down and Power keys together).
- Open the same folder where you have fastboot and the custom recovery.
- Right-click the mouse and hold Shift in the folder on an empty space and choose to open the command window.
- Type your first command:
fastboot flash recovery twrp-22.214.171.124-flounder.img
- Choose to load the recovery mode from the fastboot menu on the device’s display.
- Your device is now booting in the recovery mode.
- Point to the “Install’ option in the menu and browse for the ElementalX toolkit, followed by the SuperSU. You must install them one at a time.
- Once you are done, head back to the main recovery menu and reboot the system.
You now have the root access to the latest Android M and are ready to install custom ROMs.