Note: This is an adaptation of my Nexus 4 update/root post, so it has some duplicate content, but all the instructions and images are specific to the Galaxy Nexus.

Android 4.3 was officially unveiled and released two days ago to the Android Open Source Project. In a surprisingly timely fashion, Google also released both the factory images and OTAs to the Nexus 4, 7, 10, and the Galaxy Nexus.

[android43]

In this post, I will show you how to easily update your Galaxy Nexus to Android 4.3 JWR66V without losing data or needing root, whether because you are having trouble flashing the OTA, because one is simply not available to you yet (these notoriously take weeks to propagate to everyone), or because you're running something else and want to return to stock. You can root your Galaxy Nexus in the last step if you want.

[disclaimer1]

Prerequisites

In order to complete the steps below, you need to have the Android SDK installed. The SDK contains the latest version of adb and fastboot, which you will need for flashing. You will also need a MicroUSB cable to execute adb sideload, fastboot flash, and other commands. You don't need a USB cable if you're just planning to download the OTA zip directly to your device and flash it from recovery.

Note #1: You will not lose your data in either scenario. The first one is the same as applying the OTA. In the second one, we'll skip wiping data and upgrade just the bootloader, radio, kernel, and system images manually.

Note #2: You will be able to easily gain root in the last step.

Scenario 1

In this scenario, you're running Android 4.2.2 JDQ39 and haven't modified the system files, which basically means you can cleanly apply the OTA update without getting any errors. If you get errors and can't fix them or run a custom ROM, move on to Scenario 2.

In order to avoid repeating the steps, download the official JDQ39->JWR66V OTA zip from here for takju (Play Store variant with Google Wallet) and here for yakju (international variant without Google Wallet) and then adb sideload it by following my earlier guide here. If something fails, like it did for me, proceed to Scenario 2.

Note: To flash the update via adb sideload, you don't need to unlock the bootloader and have your data wiped if yours is still locked .

Note #2: When you get to recovery, you will probably see a No Command screen (first image below). At this point, press Volume Up while holding Power - the recovery menu will be displayed.

adb sideload is painless and fast

Scenario 2

Scenario 2 is what I would call plan B. You're here because the OTA failed, you screwed up your device and it's not booting, you're not on 4.2.2 JDQ39, or you're running a custom ROM. Don't worry - you won't lose data, even though the default factory image installation method (the bundled flash-all script) does wipe it.

The idea of this method is:

  1. Download the full takju factory image or yakju factory image, which include the full system, bootloader, recovery, kernel (boot.img), and radio. It's a clean slate for these components - they'll flash cleanly over anything you have now.
  2. Instead of using the bundled script called flash-all, you will unpack the tgz (tar/gz) archive, and then the zip contained within as well. This will put all the components into one folder:
    image
    image
  3. Follow the excellent guide over here and make sure to omit step D10, which overwrites userdata. While the guide is for the Nexus 4, it's very detailed and applies just as well to the Galaxy Nexus. Here are the commands you will be executing, for reference: adb reboot bootloader fastboot flash bootloader bootloader*.img fastboot reboot-bootloader fastboot flash radio radio-maguro-i9250xxlj1.img fastboot reboot-bootloader fastboot flash system system.img fastboot flash boot boot.img fastboot format cache fastboot reboot

Note: Instead of unpacking the image*.zip and flashing system and boot manually, you can actually do fastboot update image*.zip - this won't delete data (you would pass a -w flag if you wanted that to happen), but it will re-flash recovery back to stock if you were running a custom one. You can then flash it back, or just use the commands above instead. Either way, the result will be the same.

Bootloader in fastboot mode

Rooting

Rooting a Galaxy Nexus is very easy but requires an unlocked bootloader and a custom recovery. I recommend using TWRP.

  1. Flash TWRP from here (fastboot flash recovery FILENAME.img).
  2. Reboot into recovery (adb reboot recovery or hold Power+VolDn, then select Recovery).
  3. Flash SuperSU from this post. I've seen people complain that doing so via CWM doesn't work, but flashing through TWRP and selecting Fix Superuser Permissions at the end does the trick.
  4. You should be rooted.

Enjoy 4.3 and don't forget to see what's new!