[Q] re-enable OTA updates Nexus 7 - Nexus 7 Q&A, Help & Troubleshooting

Hi all,
I have a nexus 7 running Android 4.1.2 stock w/ root. Some months ago, I disabled the OTA update notification - but I can't seem to remember how!
I want to now re-enable OTA updates so that I can update to the latest android version, and not lose my installed apps.
I've searched the device for FOTAKill.apk inside /system/app, and its not found
I've also searched for frozen / hidden apps using Titanium Backup Pro... nothing
When I enter Settings -> About Tablet -> System Updates... it says I'm up to date... but I'm not, considering I'm running 4.1.2.
Any help or pointers in re-enabling OTA is appreciated!!

- make a full nandroid backup.
- using fastboot, flash the system.img file from the 4.2.2 factory image to the system partition.
- using your custom recovery, reflash a SuperSU root kit bundle.
- using the custom recovery, wipe cache and dalvik-cache.
If you don't like the result, restore the nandroid backup and proceed in a different fashion. It will probably break things like stickmount and any other changes that you caused in /system.
Note the above method is for use by lazy and sloppy users. A better approach is to make TiBu backups of only your market apps, bite the bullet, and start from scratch with a flash & (new) configuration of a pure stock ROM. In any case, every conceivable procedure should start with making a full nandroid backup and getting it copied to a safe place off the tablet.
I will also say that unless odd problems crop up, the portions of the factory install procedure (using fastboot) that deal with erasure or flashing of the userdata partition should be skipped, as these steps completely wipe your /data storage - including your /sdcard area in /data/media/0 and any CWM/TWRP nandroid backups!
It's not really clear why these steps would be needed unless the /data ext4 filesystem in the userdata partition got corrupted somehow. A more sly approach would be to use the custom recovery's "factory reset" procedure to clean up /data - either before or after flashing the factory ROM - and completely skip anything that touches the userdata partition in the factory install instructions.
good luck

Related

4.2.2 update

I am on stock, but rooted, nexus 7 4.2.2. I got notification of the software update sometime last week. I decided I would update. First, of course, I made a full nandoid backup, and titannium backup of all my apps and data. I downloaded rootkeeper and using rootkeeper "unrooted" and set about updating.
The Nexus rebooted, and entered the custom recovery mode (I think it is Amon RA) and then the update failed.
How can I update? What are your thoughts on the update? If I should avoid updating, how can I get rid of the software upgrade nag?
wiredwrx said:
I am on stock, but rooted, nexus 7 4.2.2. I got notification of the software update sometime last week. I decided I would update. First, of course, I made a full nandoid backup, and titannium backup of all my apps and data. I downloaded rootkeeper and using rootkeeper "unrooted" and set about updating.
The Nexus rebooted, and entered the custom recovery mode (I think it is Amon RA) and then the update failed.
How can I update? What are your thoughts on the update? If I should avoid updating, how can I get rid of the software upgrade nag?
Click to expand...
Click to collapse
You would need stock Android recovery for it to work I believe, so if you have a custom recovery, that is why it failed.
RMarkwald said:
You would need stock Android recovery for it to work I believe, so if you have a custom recovery, that is why it failed.
Click to expand...
Click to collapse
Thanks. I will look into that. Any thoughts on the update?
wiredwrx said:
Thanks. I will look into that. Any thoughts on the update?
Click to expand...
Click to collapse
You'd have to get stock Android recovery on there somehow, but if you're doing the official update and you removed any /system/app apps with Titanium Backup or anything, it'll also fail. If you flashed a custom kernel, it'll fail as well. Official updates run system checks to see that the stock files are all there and the correct versions.
You could backup everything you want to save on internal sd card (pictures/music etc), and flash the official factory Google images via fastboot. Or flash custom recovery and flash a 4.2.2 ROM. Either way, you'll have to wipe everything so you'll loose apps and app data, which you'll have to re-install again.
wiredwrx said:
The Nexus rebooted, and entered the custom recovery mode (I think it is Amon RA) and then the update failed.
Click to expand...
Click to collapse
The reason it failed is given in the recovery log file located at /cache/recovery/recovery.log
In general, OTAs are meant for 100% stock devices. When someone attempts an OTA on a rooted device, it can fail for hundreds of independent reasons - usually files in /system that got altered or removed by various root-privileged apps. (Sometimes it is not apparent to the end user that their root-using apps have even made such changes). In the current JOP40D -> JDQ39 OTA, the boot partition is also checked, so the OTA will certainly fail if you are using a custom kernel (in addition to any issues with modified files in /system).
Sounds like you are a person who makes Nandroid backups; good for you. If you have a Nandroid backup taken immediately after rooting (before any of these changes took place), it is possible that you could replace the altered files (by pulling the unaltered versions out of the old Nandroid Backups). Unfortunately, it is hard to know how much work this will be**, because during the initial check sequence that the OTA performs, it halts on the first error encountered. There could be only a single altered file causing trouble, several, or many.
** If you use TWRP recovery, the system (& data) image backups are tar files - you don't even need to restore an old backup to retrieve files from other backups.
As you mentioned TiBu, it sounds like your are farmiliar with all this stuff already. Rather than hand-patching your existing ROM, perhaps the right thing to do is to
- Make your TiBu & Nandroid Backups of your current ROM
- Install 4.2.2 factory image & Re-Root
- Make a Nandroid Backup of this (vanilla stock) ROM before you even boot it
- Boot it and restore your Market Apps. (I'm not a big fan of restoring System Apps or their data).
good luck
bftb0 said:
The reason it failed is given in the recovery log file located at /cache/recovery/recovery.log
In general, OTAs are meant for 100% stock devices. When someone attempts an OTA on a rooted device, it can fail for hundreds of independent reasons - usually files in /system that got altered or removed by various root-privileged apps. (Sometimes it is not apparent to the end user that their root-using apps have even made such changes). In the current JOP40D -> JDQ39 OTA, the boot partition is also checked, so the OTA will certainly fail if you are using a custom kernel (in addition to any issues with modified files in /system).
Sounds like you are a person who makes Nandroid backups; good for you. If you have a Nandroid backup taken immediately after rooting (before any of these changes took place), it is possible that you could replace the altered files (by pulling the unaltered versions out of the old Nandroid Backups). Unfortunately, it is hard to know how much work this will be**, because during the initial check sequence that the OTA performs, it halts on the first error encountered. There could be only a single altered file causing trouble, several, or many.
** If you use TWRP recovery, the system (& data) image backups are tar files - you don't even need to restore an old backup to retrieve files from other backups.
As you mentioned TiBu, it sounds like your are farmiliar with all this stuff already. Rather than hand-patching your existing ROM, perhaps the right thing to do is to
- Make your TiBu & Nandroid Backups of your current ROM
- Install 4.2.2 factory image & Re-Root
- Make a Nandroid Backup of this (vanilla stock) ROM before you even boot it
- Boot it and restore your Market Apps. (I'm not a big fan of restoring System Apps or their data).
good luck
Click to expand...
Click to collapse
Thanks for the detailed breakdown. I may just update with your instructions. Are you aware of a way to suppress the nag screen.

[Q] N7 Factory Reset: Have to Unlock and Root again?

Ok, I come from the Apple world where you have to restore the iPhone / iPad first to update to the latest iOS then re-jailbreak.
With the N7, if I wanted to upgrade to a newer version of Android (currently on 4.2.2, so whatever comes next), would I have to re-flash the N7 to stock 4.2.2 then re-unlock and re-root it?
What if I just want to do a factory reset to start over? Do I have to re-flash stock 4.2.2 then re-unlock and re-root in that case too?
Synomenon said:
Ok, I come from the Apple world where you have to restore the iPhone / iPad first to update to the latest iOS then re-jailbreak.
With the N7, if I wanted to upgrade to a newer version of Android (currently on 4.2.2, so whatever comes next), would I have to re-flash the N7 to stock 4.2.2 then re-unlock and re-root it?
What if I just want to do a factory reset to start over? Do I have to re-flash stock 4.2.2 then re-unlock and re-root in that case too?
Click to expand...
Click to collapse
To do an official ota yes. There are stock odexed/deodexed ROMs you can flash in the dev forums without having to go through that though.
Sent from my Paranoid 3.0 Nexus7 running M-Kernel mr1
Locking/unlocking of the boot loader is completely independent from other "rooting" activity. Under normal circumstances, it is only unlocked once and then left that way.
In Android, there are 5 principal partitions: recovery, boot, system, data, and cache. In pure stock devices, it is intended that recovery, boot, and the system partition are always used in a read-only fashion by the end user. All user changes, customizations, settings, and data are recorded into the data (sometimes also called "userdata") partition. (The cache partition is used for temporary/transient stuff)
So, the Android "factory reset" is not precisely what you are thinking of - it is a procedure which erases only the cache and data partitions. IT RESTORES NOTHING - IT ONLY DELETES.
So, if a device "rooter" comes along and alters the boot/recovery/system partition, those changes stay on the tablet/phone even when a "factory reset" procedure is performed. THOSE CHANGES CAN BREAK THE SUCCESSFUL INSTALL OF AN OTA BUNDLE, so, yes - it is generally cleaner to install a pure stock ROM for the purposes of performing an OTA upgrade... at which point you need to re-root and re-customize ( not including the boot loader unlock step).
One more thing, too: because the Nexus 7 has no physical SD card, it has an "emulated" SD card which is stored in the /data (userdata) partition. When the "stock recovery" performs a "factory reset", it erases EVERYTHING in /data - including this psuedo SD card! The newer versions of the CWM or TWRP custom recoveries define "factory reset" a little differently - they erase everything except what is stored in the /data/media/ folder - the location of the emulated SD card (usually /data/media/0). This is important to understand, as your backups will be stored in there.
HTH
PS There is no need for you to "hurry up and install an OTA" if you are using a well supported custom ROM - generally after a few weeks a ROM dev will rebase their ROM onto the new release, and you can simply "dirty flash" the replacement ROM over the top of the existing ROM. That will save you some effort if you just wait a little.
So I just unlocked and rooted my N7 last night.
Since it is unlocked and rooted, do I have to do anything different if I want or have to perform a factory reset (using the hardware buttons to go into recovery mode and use the "wipe data/factory reset" option)?
If I do this factory reset, it stays unlocked right? Does it stay rooted too?
Synomenon said:
If I do this factory reset, it stays unlocked right? Does it stay rooted too?
Click to expand...
Click to collapse
Yes and Yes.
PS. The most important skill set you can develop right now is making backups using the custom recovery. You should be 100% comfortable using the backup/restore menus of the custom recovery ... and almost as important knowing where they are stored so you can get copies of them off the tablet for safe keeping.
Thank You!
bftb0 said:
Locking/unlocking of the boot loader is completely independent from other "rooting" activity. Under normal circumstances, it is only unlocked once and then left that way.
In Android, there are 5 principal partitions: recovery, boot, system, data, and cache. In pure stock devices, it is intended that recovery, boot, and the system partition are always used in a read-only fashion by the end user. All user changes, customizations, settings, and data are recorded into the data (sometimes also called "userdata") partition. (The cache partition is used for temporary/transient stuff)
So, the Android "factory reset" is not precisely what you are thinking of - it is a procedure which erases only the cache and data partitions. IT RESTORES NOTHING - IT ONLY DELETES.
So, if a device "rooter" comes along and alters the boot/recovery/system partition, those changes stay on the tablet/phone even when a "factory reset" procedure is performed. THOSE CHANGES CAN BREAK THE SUCCESSFUL INSTALL OF AN OTA BUNDLE, so, yes - it is generally cleaner to install a pure stock ROM for the purposes of performing an OTA upgrade... at which point you need to re-root and re-customize ( not including the boot loader unlock step).
One more thing, too: because the Nexus 7 has no physical SD card, it has an "emulated" SD card which is stored in the /data (userdata) partition. When the "stock recovery" performs a "factory reset", it erases EVERYTHING in /data - including this psuedo SD card! The newer versions of the CWM or TWRP custom recoveries define "factory reset" a little differently - they erase everything except what is stored in the /data/media/ folder - the location of the emulated SD card (usually /data/media/0). This is important to understand, as your backups will be stored in there.
HTH
PS There is no need for you to "hurry up and install an OTA" if you are using a well supported custom ROM - generally after a few weeks a ROM dev will rebase their ROM onto the new release, and you can simply "dirty flash" the replacement ROM over the top of the existing ROM. That will save you some effort if you just wait a little.
Click to expand...
Click to collapse
Thank you bftb0:good::good:

[Q] Bootloop after low-battery auto-shutdown

Hey guys,
So my N7 had gone into this auto-shutdown phase before. But in the past I always managed to fix it. This time however it's different. I get stuck in bootloop.
I've left it on charge for about 1hour+, still bootloop. Reflashed ROM, still bootloop. I'm hoping I don't need to full wipe or restore the factory image to solve it, so I'm hoping there is another solution.
Thanks.
Poor Man's TiBu after bootloop occurs
TU;DBR (Toolkit Users Don't Bother Reading)
Bootloops are generally caused by stuff that lives in the /data partition, not in the /system partition.
So, if you did a dirty flash of the ROM that won't change anything.
If your /data filesystem is healthy (can be mounted by the recovery), make a nandroid backup using TWRP and pull it off the tablet.
The TWRP <partition>.ext.win backup files are just .tar images, so there is always the possibility of recovering your market apps & data with a little bit or learning and effort on your part. But no kidding, it's not for the faint of heart. The basic outline of the idea is to:
- nandroid & get copy off tablet for safety sake
- manually delete everything in /data excepting /data/media, /data/app, and /data/data
- go in to /data/data and manually delete all folders not associated with your market apps ( stuff like com.android.* or com.google.*)
- go into /data/app and delete any .apks which are updates to system apps (gmail, etc) [*1]
- nandroid backup again - call this "nandroid2"
- boot OS and configure minimally.
- boot back into TWRP
- (manually using tar? [**2]) restore the TWRP data backup (data.ext.win) without wiping
- perform "fix permissions" in TWRP
- boot up and profit
Note that "manually" here means using the command line (via adb shell to custom recovery).
If something goes wrong with this procedure, you can always restore the first nandroid backup (the bootlooping condition) and iterate until you get things right. (That right there shows you what freedoms you get by making backups.)
If you read this far you can see that what this process does is very similar to what TiBu does - except you are doing it *after* a boot loop has occurred.
[*1] optional - might not be needed
[**2] it might be possible to just "dirty flash" the data partition from the "nandroid2" backup rather than futzing around with tar at the command line. The reason I wrote this step as shown above is because I wasn't sure if a nandroid restore to /data automatically does a factory reset of /data or whether it will allow "dirty overwrites". Note also that TWRP allows you to selectively backup/restore partitions, so you don't need to involve /system or the boot partition in any of this.
good luck

Restoring after wipe clean from 4.2.2 to 4.3 via Titanium BU

Sorry guys may I ask a question relative to restoring apps via TiBU?
Before flashing stock 4.3 I had updated TiBU and backed up my apk's+data
Wiped everything to have a clean slate for TRIM to work perfectly and I've started to restore my apps.
TIBU takes forever to install a single apk, actually never ends.
Reboot.....
If I try to install apk from the market and then restore only the data from TiBU the app crashes.
After that I cannot reinstall the app anymore even from the play store.
Is there a way to overcome this?
Thanks
PS: I have already tried the solution Menu/Preferences/backup folder location
PS2: Nexus 4 - built JWR66Y - FRANCO r178
vagos696 said:
Sorry guys may I ask a question relative to restoring apps via TiBU?
Before flashing stock 4.3 I had updated TiBU and backed up my apk's+data
Wiped everything to have a clean slate for TRIM to work perfectly and I've started to restore my apps.
TIBU takes forever to install a single apk, actually never ends.
Reboot.....
If I try to install apk from the market and then restore only the data from TiBU the app crashes.
After that I cannot reinstall the app anymore even from the play store.
Is there a way to overcome this?
Thanks
PS: I have already tried the solution Menu/Preferences/backup folder location
PS2: Nexus 4 - built JWR66Y - FRANCO r178
Click to expand...
Click to collapse
I don't trust TiBU. its a real mess for me. I for one backup my ANDROID folder, and flash all apps through recovery. and then copy back the Android folder on SDCARD.
How did you root your 4.3 image? Many custom kernels break root on 4.3. Try re-flashing SuperSU or re-flash ROM and stick to the stock kernel.
via Nexus Toolkit. I'm still rooted even after applied Franco, but I'll revert back to stock kernel just to check your possibility.
Even the saved TiBU apk's are not getting installed.
How can I re-install the broken apps which were affected from TiBU? As I mentioned even fresh installation from the play store is not processed.
I was hoping to avoid re-flashing and re-rooting from scratch.
Nope even with stock kernel I face the same problems. Any suggestions?
I guess there's something wrong with your /data partition. I'd either start over with flashing the factory image or at least format /data (not wipe, really format). Don't forget to backup your internal sdcard content first, it will be deleted with both methods.
Also I'd recommend not using a toolkit for flashing the factory image and rooting. It's easy enough using fastboot and a custom recovery. This way you'll be on the safe side, not missing any errors etc.
Make sure your TiBU directory is set to storage/emulated/legacy/TitaniumBackup, not storage/emulated/0/TitaniumBackup.
It worked for me, anyway. Well, after having to perform a factory reset, as it screwed up the UUIDs, that is
Thanks for the suggestion. You were right my path was storage/emulated/0/TitaniumBackup.
I revert it to the suggested one but I have the same issue.
Factory reset, start from scratch, initial path storage/emulated/legacy/TitaniumBackup
The same problem which also end up destroying the fresh apk as well.
Hopeless
Tell us exactly what you're doing. Which ROM / image, software, versions, procedure, all the details. Maybe something other well ring a bell.
As already quoted
1. Before updating to 4.3, I updated TiBU to the latest version and kept backup of the apps+data
2. Clean flash of stock 4.3 ROM (JWR66Y) via Nexus Toolkit
3. Root (Busybox, SU etc)
4. Flashing Franco Kernel r178
5. Installation of TiBU
6. Try to restore - PROBLEM
Plan B:
1. Factory Data Reset
2. BusyBox gone but still have root access
3. Stock ROM - Stock Kernel - Rooted
4. Install TiBU
5. Restoring - PROBLEM
Description of the PROBLEM:
I cannot restore apk's is getting into a loop and never ends.
I can restore data to an installed apk, but then the app crashes
I cannot re-install the (restored) app via playstore, I get "unknown error code during installation -24-"
Current situation
1. Factory Data Reset again
2. Franco r178
3. No restores via TiBU
Don't shoot me, but it still sounds like the TiBu 4.3 ROM backup folder path problem. Here's what I do and what works for me:
1. Open TiBu
2. Click on "Menu"
3. Click on "Preferences"
4. Click on "Backup folder location"
5. Click on "DETECT!"
6. Click on "Whole device"
7. Choose "/storage/emulated/legacy/TitaniumBackup"
8. Click on "Use the current folder"
9. TiBu will now ask if it should move the other backups to the new folder, say no.
10. Exit the preferences with the back key
11. TiBu will now reload with the new preferences
Now restoring should work if the path is the problem.
About loosing root with a custom kernel on 4.3 ROMs:
If you lose root by flashing a custom kernel it may still seem like root is active, i.e. the root frontend app will still be there and ask for root permissions etc. Try the following to ensure that TiBu is running with full root privileges: Uninstall some unimportant system application (some Gapp for example, like Google Currents - backup first if you need it). If uninstalling gets cancelled with a message like "Can't find the apk file", it's likely that root doesn't work properly.
Come on man, I hate to give up
Thanks for the inspiration but unfortunately:
1. I can unistall, backup and restore properly Google Currents (hence proper root)
2. Back up folder was set properly also by verifying your steps (2-10)
And again if I try to restore an old app (not the data) it gets to the familiar loop.
Ok. I'd now flash the full factory image, thus resetting every partition (backup internal sdcard first). Please try without a toolkit to be safe. You need the drivers installed (your toolkit should already have taken care of that) and have adb and fastboot ready. There are batch/shell scripts included in the factory image which invoke the fastboot commands in one step.
Next flash a custom recovery with fastboot and use it to flash SuperSU for root access.
Refrain from flashing a custom kernel now and try if you can successfully restore with TiBu at this point.
If you can, the problem was either one of your partitions/filesystems f_cked up or the toolkit doing something wrong.

TWRP 3.1.1-0 - help me understand what to backup please

Hi,
after few soft-bricks and hours, i was able to transform my stock A2017 B16 to stock A2017U B25 and everything is working.
now the device is B25, android 7.1.1 + TWRP 3.1.1-0 and i want to make full backup as i know the need it if something goes wrong (and it probably will )
in the back up options i see the following:
Boot (64MB)
Recovery (64MB)
System (4740MB)
System Image (6144MB)
Data (excl. storage) (4001MB)
Cach (27MB)
Modem (NON-HLOS) (95MB)
Bluetooth (BTFM) (1MB)
EFS (6MB)
for now, i did backup of all of them but didn't tried to restore because i saw somewhere that i can get you brick .
can you help me understand what to backup for *complete backup* which one i can use in emergency recovery cases?
Boot - This is your bootloader. I usually back this up.
Recovery - This is twrp, you could back it up by itself once, but it isn't necessary.
System - This is your rom and stuff. This is the main thing to backup/restore if you want to keep the current ROM you are on.
System Image - I'm not positive on this, but I think its a full image of the whole system with everything.
Data (excl. storage) (4001MB) - This is all of your personal data, apps settings, call logs, etc.
Cach - no point in backing this up
Modem (NON-HLOS) - I don't back this up either as you can always flash the newest modem files
Bluetooth (BTFM) - bluetooth settings/devices I think, probably don't need to back up.
EFS - Do one backup of this and keep it forever. If you ever wipe or mess the EFS up you are in trouble.
Don't count on all that 100% as I'm not a dev, but I've been doing this for years. Besides the one time backups I mentioned, I routinely just backup the boot, system and data and have never had any problems restoring.
If you are brave and installing a rom that runs on a similar base, sometimes you can backup only the data, and flash the new rom, then restore just the data and have all your settings and apps stuff back.
Hopefully that helps.
Boot, System, Data- just like the person above me.
That's all you really need to do. Sometimes I'll even do things like wipe system only if I'm having problems with the ROM, Gapps, or some random mod, and reinstall the ROM & Gapps to bring it back to a clean slate. Say, if I tried out A.R.I.S.E. sound mod but it was acting goofy and I wanted to make sure I removed all of its remnants.
Recovery is unnecessary I'd think.
EFS - I guess backup once.
Why not backup everything? It doesn't take up much space. System image seems to be the only one I'd leave out. I still back it up anyway.
ThePublisher said:
Boot - This is your bootloader. I usually back this up.
Recovery - This is twrp, you could back it up by itself once, but it isn't necessary.
System - This is your rom and stuff. This is the main thing to backup/restore if you want to keep the current ROM you are on.
System Image - I'm not positive on this, but I think its a full image of the whole system with everything.
Data (excl. storage) (4001MB) - This is all of your personal data, apps settings, call logs, etc.
Cach - no point in backing this up
Modem (NON-HLOS) - I don't back this up either as you can always flash the newest modem files
Bluetooth (BTFM) - bluetooth settings/devices I think, probably don't need to back up.
EFS - Do one backup of this and keep it forever. If you ever wipe or mess the EFS up you are in trouble.
Don't count on all that 100% as I'm not a dev, but I've been doing this for years. Besides the one time backups I mentioned, I routinely just backup the boot, system and data and have never had any problems restoring.
If you are brave and installing a rom that runs on a similar base, sometimes you can backup only the data, and flash the new rom, then restore just the data and have all your settings and apps stuff back.
Hopefully that helps.
Click to expand...
Click to collapse
You're mostly correct except boot, which is the kernel and not the bootloader, and system image is this as mention in an old TWRP changelog:
The Team Win Recovery Project has released version 2.8.7.0 of its custom recovery, known simply as TWRP. This update brings a system read-only option that's intended to help you make a pure backup of your system image that you can later flash to receive over-the-air updates after having rooted or ROMed your device.
Cheers.
@mb0 Basic backup is system data and boot to have a working device, but I'd backup everything at least once just to be on the safe side.
The "backup all" solution sound nice to me??
At least one full backup and i keep it in safe place(es).
Let's try the restore function and hope not to be surprised
Hehe, good luck mate!
I'm back to update...
Full backup (except 'cache') --> reboot to recovery --> normal 'wipe' --> reboot (to make sure that it wiped) --> reboot to recovery --> restore everything (except 'cache') -->reboot --> ITS ALL GOOD :good:

Categories

Resources