Install 4.3 (OTA) on rooted Nexus 4 (CWM + stock rom, kernel) I'm running Android 4.2.2 on my Nexus 4. It is rooted, and I have ClockworkMod recovery installed, but rom and kernel are stock. I received the OTA update to 4.3, and would like to install it, but it failed. (With a message that CWM couldn't verify a signature. I remember that the previous OTA worked, and I think I had to re-root, but that was easy.)

How can I get the stock 4.3 update on my phone, while keeping root and CWM, and especially keeping all my data? Step-by-step instructions would be great.

Also, I'm curious, what is the technical reason that the update doesn't install?



Update: I found some instructions here, however they didn't work for me. I get the following error from CWM while applying update.zip:

Installing: /sdcard/0/update.zip
Finding update package...
Opening update package...
Installing update...

Warning no file_contextsVerifying current system...

assert failed: apply_patch_check("/system/bin/app_process", "76c3a9a7a6d400a9ff3e4db391327daa33aa0663", "2a221441bf06f2618aa6c35ae0cade13bd4f6e1b")
E:Error in /sdcard/0/update.zip
(Status 7)
Installation aborted.


Update 2:
I forgot that I tried out Xposed some time ago. Apparently this modified /system/bin/app_process. I removed it by starting Xposed Installer, and then selecting "Uninstall (restore app_process)" and (probably not neccessary), "Clean up (complete removal of the framework)". I did one complete reboot, and then rebooted into recovery mode to continue the update. But now it hangs because "build.prop" is modified (don't remember changing that). I wonder if there is a way to just flash the new OS files (not patches), overwriting any modifications, but keeping all settings and user files...
It sounds like the &quot;/system/bin/app_process&quot; has been modified and so it doesn't match the signature required. There are 2 ways to fix this, either get a copy of the stock file from another phone/rom or flash the factory image for 4.3
Edit: After reading &quot;update 2&quot; it sounds like you want the factory image option detailed below.
AndroidPolice has a step by step guide here. I've duplicated the steps in case that page dies:

Download the full occam factory image, which includes 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.
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:
Follow the excellent guide over here and make sure to omit step D10, which overwrites userdata. 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-mako-m9615a-cefwmazm-2.0.1700.84.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.

You will then need to re-root (there is no way to go from 4.2.2 to 4.3 keeping root at the moment) by following the steps in this thread (I won't link to the file itself as it is being updated as/when issues are found.).