Saturday, July 25, 2015

How to Flash the Nexus 6 with a System Image

I had to do some research on how to do this myself, which took a little time, so hopefully I can save some people some time. Follow the below steps on how to install the ADB tool, and flash your Nexus 6 with any image of your choosing.


This is essentially like taking the Nexus 6 out of the box the first day you got it. Proceed with caution. Back up your stuff. I warned you.

1. Enable Developer Mode on the Nexus 6

If you haven't done this already, go to:
Settings > About Phone > Scroll to bottom > Tap on Build Number quickly until it says "You're a developer!"

2. Enable USB Debugging and OEM Unlocking

Settings > Developer Options > Turn ON
Developer Options > OEM unlocking > Turn ON
Developer Options > USB Debugging > Turn ON

2. Download 7-Zip File Manager

Install it, x86 or x64 doesn't matter, just pick one appropriate for your Windows operating system.

3. Download the Google USB Drivers

You'll need a device driver for your Nexus 6 for the Windows machine. It can be found here:

Extract the .ZIP file, and in the "usb_driver" folder, right click on "android_winusb" and select "Install." - Accept any prompts.

4. Download the ADB Tool (used for manipulating the phone via USB)

I'm hosting the tool on my Google Drive:

Originally obtained from xda-developers at:

Run the EXE, install the ADB tool, select YES for system-wide. Do NOT install the USB drivers, because you've already installed the Google official ones.

5. Download the Nexus System Image of your Choosing

Google hosts varying Nexus system images for their devices at:

Right now, I'm running Lollipop LMY47Z, the factory image for Android 5.1.1 on my Nexus 6. It's the stable release, with Android M coming in Q3/Q4.

6. Extract the .TGZ file you receive using 7-Zip.

I created a directory called C:\Shamu. The Nexus 6's internal name was Shamu at Google, so that's what I named the folder.

I extracted all of the TGZ contents using 7-Zip into this directory. It'll contain a .ZIP file too, which you'll need to extract the contents of. Make sure ALL of the contents are in one directory. I put everything:


All of this should be in the C:\Shamu directory.

7. Let the flashing begin

  1. Plug the Nexus 6 in via USB
  2. Open an command prompt in Windows. (Start > Run > CMD)
  3. Change directory to C:\adb (do this by issuing the "cd C:\adb" command.
  4. The command prompt should now say "C:\adb>"
  5. Issue the command "adb reboot bootloader"
  6. The phone will reboot into the bootloader, it'll look like a bunch of text.
  7. Issue the "fastboot oem unlock" command - this will reboot the phone, unlocking the bootloader. You'll see some text at the bottom turn yellow, saying the device is UNLOCKED.
  8. Now that the bootloader is unlocked, you need to issue the following commands in order to flash each image to the device...
    1. fastboot flash bootloader C:\Shamu\bootloader.img
    2. fastboot reboot-bootloader
    3. fastboot flash radio C:\Shamu\radio.img
    4. fastboot reboot-bootloader
    5. fastboot flash system C:\Shamu\system.img
    6. fastboot flash userdata C:\Shamu\userdata.img
    7. fastboot flash boot C:\Shamu\boot.img
    8. fastboot flash recovery C:\Shamu\recovery.img
    9. fastboot erase cache
    10. fastboot flash cache C:\Shamu\cache.img
  9. You've now completed all flashing, as well as erasing your device. Now it will have the factory image of your choosing on it. Don't forget to re-lock the bootloader when you're finished:
    1. fastboot oem lock
  10. You'll be back in the bootloader, with a locked bootloader at this point. All you need to do is issue:
    1. fastboot reboot
At this point, the phone will boot into the Android image of your choosing, and it'll be ready to be setup like a factory-fresh Nexus.


No comments:

Post a Comment

2016 Subaru WRX - Replacing the Starlink Head Unit

I've spent a lot of time and WAY too much money on this project, so I figured I might be able to help someone else out with their 2016+ ...