Tuesday, May 24, 2016

How to: Manually install an OTA update on your device


Sometimes it turns out that your device for some rson can't find the most recent OTA (Over The Air) update. However, there is a solution to apply OTA update manually, without being forced to wait for the update being downloaded and installed by your device.
Facts you need to know before continuing:This method has nothing to do with the "adb sideload" fture available on Android devices since Jelly Bn. It should work on every Android device.Rd about different software versions for the devices here. Keep in mind that theOTA update must match the software version on your device. ch original OTA update.zip package has 2 different software versions in its name - the version of the software that must be currently installed on your device and the version of the software that your device will run after the update. For example:OTA_M7_UL_JB43_SENSE55_MR__Europe_3.62.401.1-2.24.401.8_relse_338160gxmo5sd9337kadux.zip
As you can see, 2.24.401.8 is the software version you must currently have installed to be able to run the OTA and 3.62.401.1 is the version of the software expected after the update.You can't flash an OTA update on a different software version to that expected by the OTA update for two main rsons:Formal rson - the OTA update.zip package checks if your system is running the expected software version before it starts to install the update:assert(file_getprop("/system/build.prop", "ro.build.fingerprint") == "/_europe/m7:4.2.2/JDQ39/235216.8:user/relse-");This must match the following build fingerprint from the build.prop.If the versions don't match, the installation of the OTA package will becancelled.
ro.build.fingerprint=/_europe/m7:4.2.2/JDQ39/235216.8:user/relse-Technical rson - OTA update.zip packages usually containfor the target files. This way OTA update doesn't have to be 1GB size, even if it is supposed to update the whole OS to the newer version. files have an *.apk.p extension (f.g.Camera.apk.p) and ch file must match the target file (f.g. Camera.apk). To make it possible, OTA update.zip package checks the MD5 checksum of ch file on the system partition on your device:assert(apply__check("/system/app/Camera.apk","b3b79e40bad0b1bec5fb949ac5f8662f91bee714","5a5bf63e3d7c9de52a7d8d7a292e158263783844"));And finally, if the MD5 is correct it applies the .All these commands are stored in META-INF\com\google\android\updater-script of ch OTA update.zip package. If the MD5 is incorrect, or at lst one file is missing,the installation of the OTA package will becancelled.
assert(apply_("/system/app/Camera.apk", "-",
b3b79e40bad0b1bec5fb949ac5f8662f91bee714, 4229394,
5a5bf63e3d7c9de52a7d8d7a292e158263783844,
package_extract_file("/system/app/Camera.apk.p")));
Now you are rdy to manually apply the OTA update on your device. The method you'll use is based on Android stock recovery.
Make sure you have thestock (original) recovery flashed on your deviceMake sure you're running acompletely unmodified operating system. Additional files like Superuser.apk or su binary are allowed, you just can't have any system files changed or removed (due to the MD5 check)Make sure you have a rsonable amount of battery charge remainingMake sure the OTA update you're about to install matches the software version on your deviceCopy the OTA update.zip package to your device (internal storage preferred)Turn OFF the device (make sure fastboot mode is disabled in settings)Hold your volume down and power until the bootloader starts upUsing the volume , navigate down to RECOVERY and press powerYou are now instock recovery mode. You should see nothing more than a (sometimes spinning) Android with the red exclamation mark above it (an empty black screen is also possible). Wait for a few secondsFirst hold volume up, then (with volume up held down) press power button to enter the main recovery menu. This combination may vary from device to device. Try different combination if the above one doesn't work (might be all three all together too)Navigate down to "apply from phone storage" text and press power to confirmNavigate to the loion where you copied the OTA update.zip package and press power to confirmWait (sometimes you might need to follow further instructions on the screen) until the update process is finishedOnce system is booted you should see a confirmation about the successfully flashed update.Have any questions or comments? Feel free to share!Also, if you like this article, plse use media sharing buttons (Twitter, G+, Facebook) below this post!

No comments:

Post a Comment