Official OTA Update Links and OTA updating modified systems

Breadcrust

Senior Member
Dec 13, 2013
128
142
0
Bolton
Don't forget to thank me and Radii it means a lot to us! :D
Upon discovering the reason people being given an error trying to flash OTAs in my TWRP recovery image I decided I would come up with a work around while I work out a way to fix it.

The following solution is group work between me and Radii.


If you came here just for OTA links then click HERE

Click below spoiler if you haven't installed TWRP on your device and you want to OTA update and then install TWRP.
First you need to download the version you would like, in theory you could backdate although this hasn't been tested and it may misbehave. For example the latest version as of 16/10/2015, build number cm-12.1-YOG4PAS38J.

On the spread sheet you will need two files, the fastboot and the signed. In the fastboot ZIP there is a file called recovery.img. Copy this to your android SDK platform tools folder. Now with the signed ZIP you either copy that to the same folder (platform-tools). Put your phone into fastboot mode and type.

Code:
fastboot -i 0x2b4c boot recovery.img
Or the name of the recovery if you renamed it.

Your phone will boot into Cyanogen OS Recovery. From there click Apply Update (Top option) and click ADB Sideload. Then type,

Code:
adb sideload cm-12.1-YOG4PAS38J-ham-signed.zip
Or whatever you renamed it to.

Reboot and you're done! Now you'll need to install TWRP to flash things like SuperSU and Xposed.

To install TWRP you need to download the latest TWRP image from HERE move that to platform-tools and type (with your phone in fastboot mode/bootloader mode of course)

Code:
fastboot -i 0x2b4c flash recovery "recovery.img"
Changing the name in the quotations to the name of the recovery and removing the quotes.



Click below spoiler if you have installed TWRP on your device and you want to OTA update and restore/preserve TWRP
Do the same as above, I have discovered it's impossible to preserve because Cyanogen will auto-write it's own recovery to the recovery parition.


Nerdy stuff

If you're wondering why you can't OTA without going through all this then it's because Cyanogen OS will do checks to see if the System has been r/w mounted. If so then it will stop all OTAs from installing. Simple when you think about it.

FAQ

  • Q: Why isn't TWRP still installed after installing the OTA? A: Because Cyanogen OS will write over the recovery partition with Cyanogen Recovery
  • Q: Will I lose all my data? A: Don't wipe and no, you can dirty flash to preserve data.
 
Last edited:

othe01

Member
Sep 17, 2015
48
13
0
Thanks for your work, really appreciated.

However, it sucks a bit that we have tons of work just for the OTA updates if we want root, i guess we should annoy Cyanogen to add a Superuser option to CyanogenOS...
 

Breadcrust

Senior Member
Dec 13, 2013
128
142
0
Bolton
Thanks for your work, really appreciated.

However, it sucks a bit that we have tons of work just for the OTA updates if we want root, i guess we should annoy Cyanogen to add a Superuser option to CyanogenOS...
It's designed to be shipped with devices like Samsung or LG's ROMs they'll never add that option.

Sent from my Z1 using Tapatalk
 

othe01

Member
Sep 17, 2015
48
13
0

othe01

Member
Sep 17, 2015
48
13
0
Breadcrust,
did you try this method used for oneplus one phones with CyanogenOS?

https://forums.oneplus.net/threads/flashable-zip-cm12-enable-integrated-superuser.297089/
https://github.com/julian-klode/bacon-superuser/

From what i´ve read OTA updates are working with it and all we need to do is update the recovery after installing a new ota, the script on github creates the patched boot files automatically, we just have to change the config to use the ZUK files.

All theory tho...as i don´t have my phone yet.
 

Breadcrust

Senior Member
Dec 13, 2013
128
142
0
Bolton
Breadcrust,
did you try this method used for oneplus one phones with CyanogenOS?

https://forums.oneplus.net/threads/flashable-zip-cm12-enable-integrated-superuser.297089/
https://github.com/julian-klode/bacon-superuser/

From what i´ve read OTA updates are working with it and all we need to do is update the recovery after installing a new ota, the script on github creates the patched boot files automatically, we just have to change the config to use the ZUK files.

All theory tho...as i don´t have my phone yet.
I'll look into it at sunrise it currently 3:23AM here so can't do it now

P.s thanks for waking me :3

Sent from my Z1 using Tapatalk
 

SkandaH

XDA Portal Supporter
Jun 8, 2013
968
2,557
133
@othe01

No COS device allows you to flash incremental OTA if your /system partition is modified. Your quoted package puts compatible su binary in /system & flashes boot-debuggable kernel so that root can be achieved from both app & ADB. It has nothing to do with OTA. Your only choice is to get the signed zip & flash it manually.
@Breadcrust

It would be nice to put incremental OTA zip links too. My posts regarding OTA links also contain them.

:highfive:
 

othe01

Member
Sep 17, 2015
48
13
0
@othe01

No COS device allows you to flash incremental OTA if your /system partition is modified. Your quoted package puts compatible su binary in /system & flashes boot-debuggable kernel so that root can be achieved from both app & ADB. It has nothing to do with OTA. Your only choice is to get the signed zip & flash it manually.

@Breadcrust

It would be nice to put incremental OTA zip links too. My posts regarding OTA links also contain them.

:highfive:
sounded different here: [FLASHABLE ZIP] [CM12] Enable integrated superuser
But is prolly just a misunderstanding from my side.

How exactly does CyanogenOS check if System is modified and can´t we patch the check with an xposed module?
 
Last edited:

SkandaH

XDA Portal Supporter
Jun 8, 2013
968
2,557
133
@othe01

He must used the signed zip to update. Regarding OTA faliure, I've discussed the issue here: http://forums.yuplaygod.com/index.php?threads/15124/

You need to registered in the forum to read, so I've uploaded a PDF of the same: https://drive.google.com/file/d/0B9zZIJPXbMsubkFBYmZ4eGtMQjQ/view?usp=sharing

I personally own OnePlus One & YU Yureka so already have a good experience with these things.

The whole procedure is clearly explained - no 'Xposed' module can bypass it. You can, in theory, deploy a file based OTA (I've already requested it through YU developers) instead of block based OTA or patch the update-binary to return always true (unmodified) value while checking the state of partitions.

:good:
 
Last edited:
  • Like
Reactions: othe01

aaswar

Senior Member
Sep 14, 2007
135
39
0
Brusseles
@Breadcrust can you please help me if you can, I have problem flashing any ota (increments or full), it return error " this package is for device:Z1 this device is k9", all ota was installed directly till unlocked bootloader and root .
 

aaswar

Senior Member
Sep 14, 2007
135
39
0
Brusseles
@Breadcrust
for clarification:
-isn't "cm-12.1-YOG4PAS38J-ham-signed-fastboot.zip" is the same as "cm-12.1-YOG4PAS38J-ham-signed.zip", but with the recovery image include, can sideload this file using the same process you mentioned?
-if the phone is rooted, boot with the COS recovery and sideload the "cm-12.1-YOG4PAS38J-ham-signed.zip" will not work as the system partition is already been modified by the root process, am I right?
 

radii

Senior Member
Oct 2, 2006
162
27
0
@Breadcrust
for clarification:
-isn't "cm-12.1-YOG4PAS38J-ham-signed-fastboot.zip" is the same as "cm-12.1-YOG4PAS38J-ham-signed.zip", but with the recovery image include, can sideload this file using the same process you mentioned?
-if the phone is rooted, boot with the COS recovery and sideload the "cm-12.1-YOG4PAS38J-ham-signed.zip" will not work as the system partition is already been modified by the root process, am I right?
re: above
if using cos recovery and sideload via abd or from file the full signed version , and your have root, it will work, root will be lost though.
fastboot zip has recovery signed doesn't. you need to flash recovery extracted from the fastboot zip and then flash the signed full zip using cos either using abd or sideload file onto system
 

taitai

Member
Jul 7, 2008
18
1
0
I flash the rom, but when I insert CDMA SIM into slot one, there is no signal
and there is no option to choose band from the menu.
would you please instruct on how to get CMDA works?