[REF][How To] Return to STOCK Recovery (IF rooted) and sideload OTA

Search This thread

.Memphis.

New member
Mar 8, 2008
2
0
I had similar problem to those mentioned -i'm starting from an unlocked rooted 1053 de. I flashed back to stock recovery, then it kept 'almost' updating but reverting to 4.4.4. I was really dreading a clean reset, so on a whim I decided to go ahead and mfastboot the system to clean it up. After that, smooth sailing. I'm guessing that ANY difference from the stock system file will make the OTA error out. I have never used Xposed, but did have adblock which I think made minor additions to the system folder. anyway, this worked for me so i wanted to share. good luck!

thanks, flashing stock system.img did the trick in the end, finally on 5.1.
 

KidJoe

Inactive Recognized Contributor
Aug 23, 2008
3,211
1,561
Thorndale/Romansville, PA
What is complete stock???

Sent from my XT1052
Well, like you flashed TWRP, rooted, and only installed apps like Root Explorer, Wifi Tether For Root, etc.. things that use root access, but do NOT make any changes... Apps like that don't cause the OTA's pre-flash validation checks to fail.

While BigTinCan's Adfree changes the hosts file, it too does not cause interfere with what the pre-flash validation checks.

Once you start doing things like installing Xposed, Busybox, using Xposed modules, modifying your build.prop, DELETING "bloat", mixing parts of roms or flashing the leaks, etc.. you are no longer completely stock, or close enough to stock and the pre-flash validations will fail causing the OTA to not install... In those situations, just flashing stock recovery (what the OP is about) will NOT be enough... Hence the thread in my signature about preparing to take the OTA...

that is why these last few posters in this thread are having issues, because they vary enough from stock which will cause more than just Stock Recovery to be flashed in order to take the OTA.
 

ajsonofgod

Senior Member
Mar 18, 2015
263
24
30
Bhopal
Well, like you flashed TWRP, rooted, and only installed apps like Root Explorer, Wifi Tether For Root, etc.. things that use root access, but do NOT make any changes... Apps like that don't cause the OTA's pre-flash validation checks to fail.

While BigTinCan's Adfree changes the hosts file, it too does not cause interfere with what the pre-flash validation checks.

Once you start doing things like installing Xposed, Busybox, using Xposed modules, modifying your build.prop, DELETING "bloat", mixing parts of roms or flashing the leaks, etc.. you are no longer completely stock, or close enough to stock and the pre-flash validations will fail causing the OTA to not install... In those situations, just flashing stock recovery (what the OP is about) will NOT be enough... Hence the thread in my signature about preparing to take the OTA...

that is why these last few posters in this thread are having issues, because they vary enough from stock which will cause more than just Stock Recovery to be flashed in order to take the OTA.

Thanks for the info... And can you provide the instructions to get complete stock to receive ota?

Sent from my XT1052
 

KidJoe

Inactive Recognized Contributor
Aug 23, 2008
3,211
1,561
Thorndale/Romansville, PA

newbiemoder

New member
Jul 3, 2015
1
0
Hey! I have a 2013 moto x (not the developer edition). I just want to ask whether the recovery.img file of the moto x dev edition will work in the non dev edition moto x ???
 

ajsonofgod

Senior Member
Mar 18, 2015
263
24
30
Bhopal
What ROM is on you phone to start with? On your phone go App Drawer -> Settings -> About.. tell me the Android Version, System Version and Build Number. Also what model X do you have?

213.44.1.ghost_row.Retail.en.US is an XT1053 4.4.4 update file for the XT1053 if I'm not mistaken. It is meant to be applied to a 4.4.3 stock rom, and it might apply to a 4.4.2 stock rom..

The OTA file will fail its pre-flash validation checks if you are not on the intended stock rom.
/system/etc/install-recovery.sh has unexpected contents
i am getting this when i tried to sideload lollipop ota on my moto x XT1052,
android version: 4.4.4
System version: 212.44.26.ghost_row.AsiaRetail.en.03
Bulid no. : KXA21.12-L1.26

what should i do?

---------- Post added at 09:18 AM ---------- Previous post was at 08:56 AM ----------

/system/etc/install-recovery.sh has unexpected contents
i am getting this when i tried to sideload lollipop ota on my moto x XT1052,
android version: 4.4.4
System version: 212.44.26.ghost_row.AsiaRetail.en.03
Bulid no. : KXA21.12-L1.26

what should i do?
Dont bother... I've got the solution by myself.

and for everyone else:

i went to /system/etc/
there i found install-recovery_original.sh and install-recovery.sh
i just renamed install-recovery.sh to install-recovery-2.sh
and install-recovery_original.sh to install-recovery.sh
and its done!!!

now i am on Lollipop...:laugh::good::cool::D
 

bryan.gayagoy

Member
Jul 11, 2015
16
3
Request for original install-recovery.sh

First of all, I would like to express my sincerest thanks to XDA and all the generous developers out there. I am not a developer but have been benefiting from all the guides, roms, and apps since my galaxy nexus, nexus 4, nexus 5, and now my moto x.

For my particular concern, I would like to address it to Sir "Ajsonofgod" since I am encountering the same error as described below but the problem is I can no longer find the original install-recovery.sh. I might not have backed it up when I rooted my Moto X and flashed a custom recovery. If it is not to much to ask sir, may I ask if you can provide me a copy of your original install-recovery.sh since we have the same model of Moto X and also running on the same firmware. Thanks in advance sir.

/system/etc/install-recovery.sh has unexpected contents
i am getting this when i tried to sideload lollipop ota on my moto x XT1052,
android version: 4.4.4
System version: 212.44.26.ghost_row.AsiaRetail.en.03
Bulid no. : KXA21.12-L1.26

what should i do?

---------- Post added at 09:18 AM ---------- Previous post was at 08:56 AM ----------


Dont bother... I've got the solution by myself.

and for everyone else:

i went to /system/etc/
there i found install-recovery_original.sh and install-recovery.sh
i just renamed install-recovery.sh to install-recovery-2.sh
and install-recovery_original.sh to install-recovery.sh
and its done!!!

now i am on Lollipop...:laugh::good::cool::D
 

ajsonofgod

Senior Member
Mar 18, 2015
263
24
30
Bhopal
For my particular concern, I would like to address it to Sir "Ajsonofgod" since I am encountering the same error as described below but the problem is I can no longer find the original install-recovery.sh. I might not have backed it up when I rooted my Moto X and flashed a custom recovery. If it is not to much to ask sir, may I ask if you can provide me a copy of your original install-recovery.sh since we have the same model of Moto X and also running on the same firmware. Thanks in advance sir.

here is the link for the file from my google drive:
https://drive.google.com/file/d/0B45dOHQNtoKLRkd6UnQ3TkhMSFk/view?usp=sharing

just put it in /system/etc and then rename it to install-recovery.sh
i hope this might help.:)
reply with results. :good:
 
Last edited:
  • Like
Reactions: bryan.gayagoy

ComputeRescue

Member
Dec 9, 2011
18
0
Google Pixel 3 XL
Thanks, I needed the refreasher; my VZN XT1060 is sporting Android 5.1;
view
 

bryan.gayagoy

Member
Jul 11, 2015
16
3
Moto X XT1052 Asia Retail Stagefright OTA

Good day to all. First, I would like to thank all as I was able to run 5.1 by following this thread.

Today, I was able to capture the OTA.zip file (only 8.9 MB) for the stagefright update but wasnt able to update my Moto X since it is rooted and running custom recovery. For anyone interested with the file, just PM me for me to send it through your email since I cannot post yet the link of my google drive for this particular file.

Thanks.

Bryan
 

vivekswaraj

New member
Jun 27, 2017
1
0
Good day to all. First, I would like to thank all as I was able to run 5.1 by following this thread.

Today, I was able to capture the OTA.zip file (only 8.9 MB) for the stagefright update but wasnt able to update my Moto X since it is rooted and running custom recovery. For anyone interested with the file, just PM me for me to send it through your email since I cannot post yet the link of my google drive for this particular file.

Thanks.

Bryan
I want stock recovery image for my Moto x play.. please send me
 

Top Liked Posts

  • There are no posts matching your filters.
  • 19
    By now, with all the OTA's, unless you are brand new to the 2013 X, you know you have to have stock recovery on your phone for an OTA Update or Soak Test to install, and your system can't be modified too much or it will fail the pre-flash validation checks built into the OTA.zip. (i.e. there is a manifest file that checks for specific files and their check sums before it will flash the ota).

    If you have an unlocked bootloader, and rooted by flashing a 3rd party recovery (like TWRP, CWM, Philz, etc) and installing SuperSU, you likely didn't put stock recovery back on your phone.

    IF you are close enough to stock (like I am... stock, unlocked, rooted, with adfree, wifi tether for root, greenify, Quick boot, and a few other apps that require root), you can just flash stock recovery and take the OTA.

    The steps in this post help you do that, or get ready to do that, in case you are not near your PC when an OTA comes, of if you just don't want to use your PC.

    NOTE: If you have changed too much of stock that the OTA fails, please see -> [FAQ] How to prepare for and take an OTA update (All Carriers)

    NOTE: the following worked when updating 4.4 to 4.4.2, and 4.4.2 to 4.4.4 on my VZW Dev Edition X. Since Lollipop has not yet been released for my phone, I can't test this yet.

    Note: If you have flashed your phone with another carrier's ROM, or have only flashed "parts" of your phone, these steps may not work!! Or they may cause you to brick!
    NOTE: If your Bootloader version does NOT match the one for your phone's software version, taking an OTA could brick your phone!

    You must have an Unlocked Bootloader and be rooted for these steps to work:

    Obtain the STOCK Moto Recovery image, and TWRP image, for your phone:

    1. On you phone, go App Drawer -> Settings... Make note of what is listed under System Version, and Android Version.
    2. Visit one of the sites listed in -> http://xdaforums.com/moto-x/general/info-tip-web-sites-official-leaked-roms-t2923347 and obtain the EXACT same ROM/SBF file that is currently on your phone. Download the ZIP to your PC.
    3. Unzip or extract the RECOVERY.IMG file from the SBF ZIP file.
    4. Download the latest TWRP Recovery from -> http://teamw.in/project/twrp2/234 (under the Download-Fastboot heading)
    5. the latest SuperSU from -> http://download.chainfire.eu/supersu or the latest CWM / TWRP / MobileODIN installable ZIP from http://xdaforums.com/showthread.php?t=1538053

    Flashing Recovery
    1. Place your stock recovery.img, the latest TWRP img, and the latest SuperSU.zip in your phone's DOWNLOAD folder.
    2. Install Rashr.
    3. On your phone, launch Rashr.
    4. Scroll down and select other from storage
    5. Browse and select your stock recovery
    6. When it completes, pick the option to reboot to stock recovery.
    7. Your device should reboot and display the Motorola logo and then the Android in distress (logo with Exclamation mark)
      Press and hold the VOL UP key for 10-15 seconds. While still holding the VOL UP key tap and release the POWER key. You should be in Stock recovery now.
    8. Reboot your phone as normal.
    To reflash TWRP or other custom recovery, as long as you are still rooted, you can repeat the same steps, selecting your custom recovery in step 5.

    How to SIDE LOAD an OTA.ZIP via this process

    If your carrier has started the push of the OTA ZIP for your phone, but you haven't received it, and you've found the correct OTA ZIP posted online and would like to flash it, the following steps can be used...
    1. Download the OTA ZIP file (usually named as BLUR_XXX.XXX.XXX.zip, where XXX.XXX.XXX is the build number the ZIP will update) to your phone's /SDCard
    2. Perform steps 1-7 under Flashing Recovery above to flash STOCK recovery onto your phone, and reboot into Stock Recovery.
    3. Use the Vol Down key to scroll to Apply Update From SDCard, and press the Power key to select.
    4. Use Vol Down key to scroll to your OTA zip file, and press Power to select.
    5. The install will begin by verifying the update package, then verifying files on your phone match.
    6. If the install fails, it will be reported on the screen, along with why. (usually because you have modified system files, or are not on the correct ROM version). You need to fix these errors and try again.
    7. If verifications are successful, the patching process steps will begin. This may take several minutes.
    8. Your phone should report Script Succeeded and Install from sdcard Complete.
    9. Ensure Reboot System Now is highlighted, and press the Power key to reboot the phone.
    10. The initial reboot may take longer than a regular reboot.
      Note: You will see Android Is Upgrading or Optimizing screen during the boot process, that is normal.
    11. After the update install process is complete, use Rashr to flash TWRP (again, other from storage and pick your TWRP). When prompted, reboot into recovery (so twrp sticks). When in TWRP, select reboot to system.
    If you lost root, reboot into TWRP recovery and install SuperSU.zip

    How to Root with unlocked bootloader...

    If you unlocked your bootload by getting the code from Moto, after taking the OTA you may root by following ->http://xdaforums.com/moto-x/general/how-to-how-to-root-5-1-unlocked-t3140217 NOTE: while the thread is titled for 5.1, it works on older Android versions as well.
    3
    Thanks for the info... And can you provide the instructions to get complete stock to receive ota?

    Sent from my XT1052
    Sure, already posted the link in this thread, plus its in my signature...

    [FAQ] How to prepare for and take an OTA update (All Carriers) Hint: Post 1 explains some background and whys.. Post 2 has the hows..
    2
    What is complete stock???

    Sent from my XT1052
    Well, like you flashed TWRP, rooted, and only installed apps like Root Explorer, Wifi Tether For Root, etc.. things that use root access, but do NOT make any changes... Apps like that don't cause the OTA's pre-flash validation checks to fail.

    While BigTinCan's Adfree changes the hosts file, it too does not cause interfere with what the pre-flash validation checks.

    Once you start doing things like installing Xposed, Busybox, using Xposed modules, modifying your build.prop, DELETING "bloat", mixing parts of roms or flashing the leaks, etc.. you are no longer completely stock, or close enough to stock and the pre-flash validations will fail causing the OTA to not install... In those situations, just flashing stock recovery (what the OP is about) will NOT be enough... Hence the thread in my signature about preparing to take the OTA...

    that is why these last few posters in this thread are having issues, because they vary enough from stock which will cause more than just Stock Recovery to be flashed in order to take the OTA.
    2
    update fails? then try mfastboot system.img ...

    I had similar problem to those mentioned -i'm starting from an unlocked rooted 1053 de. I flashed back to stock recovery, then it kept 'almost' updating but reverting to 4.4.4. I was really dreading a clean reset, so on a whim I decided to go ahead and mfastboot the system to clean it up. After that, smooth sailing. I'm guessing that ANY difference from the stock system file will make the OTA error out. I have never used Xposed, but did have adblock which I think made minor additions to the system folder. anyway, this worked for me so i wanted to share. good luck!
    2
    Do I need to uninstall xPosed & GravityBox before I sideload L ? I guess, Kitkat version of xposed worn't work in L anyway.
    As explained elsewhere... Xposed makes changes to /system which cause OTA updates to fail their pre-flash validation checks.

    It is recommended to boot to TWRP and install /SDcard/Android/data/de.robv.android.xposed.installer/files/Xposed-Disable-Recovery.zip then uninstall XPosed.

    You will also need to undo any changes to /system or other parts the the OTA tries to validate before installing, or else it will fail.

    You are correct that a newer version of Xposed is needed.

    You may also want to wait on trying the 5.0.2 Leaks because if they are an early limited early test version, rather than a soak which is nearly ready to be pushed to all, you could be stuck on this version until an SBF leaks.