[Q] Restore SYSTEM partition? - Nexus 7 Q&A, Help & Troubleshooting

I dun goofed and erased my system partition. I have backed up my DATA partition and have a few things.... but i would like to know if i can simply flash the system partition back from a stock rom, instead of having to system restore everything and have to re-root, etc.
Thanks.
(Nexus 7 2012)

Yes you can, use
fastboot flash system <system.img>
but it needs to be the same version you erased otherwise you might get a boot loop.
Sent from my Nexus 7 using xda app-developers app

Simple fix
NullUserID said:
I dun goofed and erased my system partition. I have backed up my DATA partition and have a few things.... but i would like to know if i can simply flash the system partition back from a stock rom, instead of having to system restore everything and have to re-root, etc.
Thanks.
(Nexus 7 2012)
Click to expand...
Click to collapse
if you have recovery like twrp just flash the system image back. if you dont you might have to restore it.
Wugs tool kit works if you get stuck on flashing system see my response to this thread http://forum.xda-developers.com/showthread.php?t=2625843
click thanks if i helped

Related

Help!! My SD partition shrunk!!

I was playing around with kernels in fastboot the other day, and somehow my SD storage partition got all messed up. It's supposed to be 16GB, but it's only showing 5.8GB.
I ran the fastboot erase commands for boot, userdata, system, and cache, then flashed the jdq39 factory image. When I rebooted, the partition was only 5.8GB, and there were no files left on it.
I've tried formatting it in cwm recovery, but it just stays the same size. It's not showing any extra storage partition, but it almost feels like that's what happened somehow, and I just can't access the other partition. I'm also thinking that maybe the other partition I can't access possibly still contains my missing files, which I would love to recover, if possible, since I do have a nandroid on there I'd love to be able to restore!
I'm running UBUNTU and do not have windows, so if I need to do any terminal work I'm game...but I'm also a n00b, so please explain well
hp420 said:
I was playing around with kernels in fastboot the other day, and somehow my SD storage partition got all messed up. It's supposed to be 16GB, but it's only showing 5.8GB.
I ran the fastboot erase commands for boot, userdata, system, and cache, then flashed the jdq39 factory image. When I rebooted, the partition was only 5.8GB, and there were no files left on it.
I've tried formatting it in cwm recovery, but it just stays the same size. It's not showing any extra storage partition, but it almost feels like that's what happened somehow, and I just can't access the other partition. I'm also thinking that maybe the other partition I can't access possibly still contains my missing files, which I would love to recover, if possible, since I do have a nandroid on there I'd love to be able to restore!
I'm running UBUNTU and do not have windows, so if I need to do any terminal work I'm game...but I'm also a n00b, so please explain well
Click to expand...
Click to collapse
you might have to flash the stock system img via fastboot to fix it.
I've done a FULL flash...bootloader, radio, boot, system, userdata
http://forum.xda-developers.com/showthread.php?t=2033692
You'll either follow the steps in the OP or flash stock recovery and factory reset and clear cache.
Sent from my Nexus 4 using xda premium
OMG thank you!! This is exactly what I was looking for I knew there had to be one!

[Q] [CWM] delete data part of backup

I was wondering if it is possible to delete parts of a nandroid backup? I basically only want the system, boot and recovery images and NOT the data (2.5 GB) and cache partitions. I know I can restore parts of a backup, but I just don't want them around and take up space?
The bottom line is that I would like to be able to restore a clean system img, and then use TB to restore apps and data. Now the data is back-upped in duplicate which is unnecessary?
Why not just flash the ROM then or am I missing something?
Sent from my Nexus 4
pepdavies said:
Why not just flash the ROM then or am I missing something?
Sent from my Nexus 4
Click to expand...
Click to collapse
I run the N4 stock Android rom. I don't think there is a version I can flash via CWM?

Twrp Backup Options

Hello, i want to try a different rom out and im wondering what things do i need to back up in twrp just in case something goes wrong or i want to go back. Also if i go back i would like everything to be right as i left off before flashing a new rom. My backup options are Boot, System, System image, Vendor, Vendor Image, Data, Chache, Recovery, EFS
kradkovich said:
Hello, i want to try a different rom out and im wondering what things do i need to back up in twrp just in case something goes wrong or i want to go back. Also if i go back i would like everything to be right as i left off before flashing a new rom. My backup options are Boot, System, System image, Vendor, Vendor Image, Data, Chache, Recovery, EFS
Click to expand...
Click to collapse
By default, you have to backup Boot, System and Data
Braakie said:
By default, you have to backup Boot, System and Data
Click to expand...
Click to collapse
and that will bring me back like i left off if i restore boot, system, and data?
Don't you have to disable all security passwords like pattern lock and fingerprints before making a nandroid or it won't work when you restore? I read that in the How to thread for the 6P. Wondering if this is true or not.
kradkovich said:
Hello, i want to try a different rom out and im wondering what things do i need to back up in twrp just in case something goes wrong or i want to go back. Also if i go back i would like everything to be right as i left off before flashing a new rom. My backup options are Boot, System, System image, Vendor, Vendor Image, Data, Chache, Recovery, EFS
Click to expand...
Click to collapse
See section 4 of my guide.
http://forum.xda-developers.com/nexus-6p/general/guides-how-to-guides-beginners-t3206928
Heisenberg said:
See section 4 of my guide.
http://forum.xda-developers.com/nexus-6p/general/guides-how-to-guides-beginners-t3206928
Click to expand...
Click to collapse
Thank you! Im going to try flashing the BeanStalk 6.02 rom on my 6p tomorrow! Would it possible to restore data on a new rom coming from your old rom? For example: My Nexus 6p is running chroma rom right now, if i back up the data partition can i restore that partition onto my new rom ( BeanStalk 6.02)?
Krunk83 said:
Don't you have to disable all security passwords like pattern lock and fingerprints before making a nandroid or it won't work when you restore? I read that in the How to thread for the 6P. Wondering if this is true or not.
Click to expand...
Click to collapse
Yes that would be true, you would have to disable any type of lockscreen security because it wont let you unlock your phone after restoring.
kradkovich said:
Thank you! Im going to try flashing the BeanStalk 6.02 rom on my 6p tomorrow! Would it possible to restore data on a new rom coming from your old rom? For example: My Nexus 6p is running chroma rom right now, if i back up the data partition can i restore that partition onto my new rom ( BeanStalk 6.02)?
Click to expand...
Click to collapse
Thats not even remotely a clean wipe and would cause nothing but issues.
I would highly recommend not doing that.
Sent from my Nexus 6P, Note 5, Nexus 6 or Note 4
kradkovich said:
Thank you! Im going to try flashing the BeanStalk 6.02 rom on my 6p tomorrow! Would it possible to restore data on a new rom coming from your old rom? For example: My Nexus 6p is running chroma rom right now, if i back up the data partition can i restore that partition onto my new rom ( BeanStalk 6.02)?
Click to expand...
Click to collapse
Noooooooo. When flashing a different ROM you need to clean flash (wipe system, data, cache, dalvik cache).
I have a pattern lock and fingerprints and restore my backup without any problems?
Braakie said:
I have a pattern lock and fingerprints and restore my backup without any problems?
Click to expand...
Click to collapse
Which partitions do you backup and restore?
I don't feel the original question has been fully answered and explained.
The usual answer is: boot, system, data.
In the guide, section 4 that Heisenberg links however, vendor is added to the mix.
Remaining questions:
- Is vendor needed for usual backup together with boot, system and data. If so, why? What does it contain?
- What about the remaining partitions? Vendor image, system image. What do they contain and why do we not need them backed up?
---------- Post added at 01:40 PM ---------- Previous post was at 01:39 PM ----------
Also, yes you can still get back into a backup with fingerprint lock still active. See this post:
http://forum.xda-developers.com/showpost.php?p=64321640&postcount=91
TigerSoul925 said:
I don't feel the original question has been fully answered and explained.
The usual answer is: boot, system, data.
In the guide, section 4 that Heisenberg links however, vendor is added to the mix.
Remaining questions:
- Is vendor needed for usual backup together with boot, system and data. If so, why? What does it contain?
- What about the remaining partitions? Vendor image, system image. What do they contain and why do we not need them backed up?
---------- Post added at 01:40 PM ---------- Previous post was at 01:39 PM ----------
Also, yes you can still get back into a backup with fingerprint lock still active. See this post:
http://forum.xda-developers.com/showpost.php?p=64321640&postcount=91
Click to expand...
Click to collapse
Boot, system and data are fine just as it's always been. I've already done this and restored with no issues. Even with lock screen security. All you do is use file manager in twrp to delete "data/system/locksettings.db". If you know what you are flashing is going to actually write to a partition other than boot or system then yeah, back those up too. Suppose it wouldn't hurt to grab backups of each partition individually and store them on your pc to be on the safe side.
Gizmoe said:
Boot, system and data are fine just as it's always been. I've already done this and restored with no issues. Even with lock screen security. All you do is use file manager in twrp to delete "data/system/locksettings.db". If you know what you are flashing is going to actually write to a partition other than boot or system then yeah, back those up too. Suppose it wouldn't hurt to grab backups of each partition individually and store them on your pc to be on the safe side.
Click to expand...
Click to collapse
The only issue with not backing up and restoring the vendor partition, and the reason I include that in my guide, is if you have themes applied they will survive through the wipe and be carried onto the restore/flash, potentially causing compatibility issues and a failure to boot or a wonky/unusable system after boot.
Gizmoe said:
Boot, system and data are fine just as it's always been. I've already done this and restored with no issues. Even with lock screen security. All you do is use file manager in twrp to delete "data/system/locksettings.db". If you know what you are flashing is going to actually write to a partition other than boot or system then yeah, back those up too. Suppose it wouldn't hurt to grab backups of each partition individually and store them on your pc to be on the safe side.
Click to expand...
Click to collapse
Heisenberg said:
The only issue with not backing up and restoring the vendor partition, and the reason I include that in my guide, is if you have themes applied they will survive through the wipe and be carried onto the restore/flash, potentially causing compatibility issues and a failure to boot or a wonky/unusable system after boot.
Click to expand...
Click to collapse
Oh so that's the reason! Well thanks, then I know what to do! I'll include the vendor partition then just for safety. I already have a complete backup of all partitions except recovery and cache too so I'll just keep that safe somewhere just in case.
Thanks for the replies!
Heisenberg said:
Which partitions do you backup and restore?
Click to expand...
Click to collapse
I backup/restore my boot, data and system partitions to data/media (SDCard)
So what are other options such as system image?
Is it necessary to back it up? I just backed up the default ones
survivor_evil said:
So what are other options such as system image?
Is it necessary to back it up? I just backed up the default ones
Click to expand...
Click to collapse
System.img is just that. An exact image copy of the system image in one chunk. So you would end up with IMG files. It's not necessary to choose the IMG options. Default options for boot, system and data is a complete backup.

Stuck on Google Logo after TWRP Backup Restore.

Hello,
so i backup my phone before i do anything risky. so i was trying to restore my phone (from yesterday backup) using twrp. everything went perfect and when my device rebooted after restore. it stuck on Google Logo. i tried 3 times but no luck. any help? i select Boot, Data, System, System.img
EDIT: should i select vendor / vendor.img ?? while restoring it ?
UPDATE: when i tried 4th time. my phone rebooted after about 72% and stuck on google logo.
Tried clearing cache? Also, what things did you precisely backup?
DJBhardwaj said:
Tried clearing cache? Also, what things did you precisely backup?
Click to expand...
Click to collapse
almost everything including vendor ; no cache
setul34 said:
almost everything including vendor ; no cache
Click to expand...
Click to collapse
I had the same issue when I backed up system image.
DJBhardwaj said:
I had the same issue when I backed up system image.
Click to expand...
Click to collapse
okay so any solution?
Try it without the system image.
DJBhardwaj said:
Try it without the system image.
Click to expand...
Click to collapse
i did but that did not install root / apps / settings. basically i just got data and stock rom.
setul34 said:
i did but that did not install root / apps / settings. basically i just got data and stock rom.
Click to expand...
Click to collapse
No idea, I myself haven't tried further.
Lets see if someone else comes up with something
setul34 said:
Hello,
so i backup my phone before i do anything risky. so i was trying to restore my phone (from yesterday backup) using twrp. everything went perfect and when my device rebooted after restore. it stuck on Google Logo. i tried 3 times but no luck. any help? i select Boot, Data, System, System.img
EDIT: should i select vendor / vendor.img ?? while restoring it ?
UPDATE: when i tried 4th time. my phone rebooted after about 72% and stuck on google logo.
Click to expand...
Click to collapse
Let me guess you are on TWRP 3.0.0.0?
Yes
oneandroidnut said:
Let me guess you are on TWRP 3.0.0.0?
Click to expand...
Click to collapse
@oneandroidnut Yes.
setul34 said:
@oneandroidnut Yes.
Click to expand...
Click to collapse
You don't backup system image, only backup system, data, and boot.
setul34 said:
@oneandroidnut Yes.
Click to expand...
Click to collapse
pm me if you are still having issues we can go to hangouts or something and i can walk you through
oneandroidnut said:
pm me if you are still having issues we can go to hangouts or something and i can walk you through
Click to expand...
Click to collapse
It'd be much better if you did this here, that way the solution is available for others to find, that's pretty much the entire point of the Q&A section. I'm confident it's just a case of selecting the wrong partitions to backup anyway.
Heisenberg said:
It'd be much better if you did this here, that way the solution is available for others to find, that's pretty much the entire point of the Q&A section. I'm confident it's just a case of selecting the wrong partitions to backup anyway.
Click to expand...
Click to collapse
The solution i used when i incorrectly updated vendor image and then tried to restore old system image and vendor image was to use Nexus Tool kit by wugs fresh to flash back to stock while keeping internal card intact. Then flash the rom you were on with correct vendor image in TWRP 3.0.0.0 and then restore your twrp backup without the vendor image etc and boom should be back to normal. At least that is what worked for me. What should you backup and restore? I back up everything and restore everything but vendor stuff. any suggestions?
oneandroidnut said:
The solution i used when i incorrectly updated vendor image and then tried to restore old system image and vendor image was to use Nexus Tool kit by wugs fresh to flash back to stock while keeping internal card intact. Then flash the rom you were on with correct vendor image in TWRP 3.0.0.0 and then restore your twrp backup without the vendor image etc and boom should be back to normal. At least that is what worked for me. What should you backup and restore? I back up everything and restore everything but vendor stuff. any suggestions?
Click to expand...
Click to collapse
That seems over-complicated. You only need to backup/restore system, data, and boot. Vendor is optional if you have Layers that you want to keep. Don't backup/restore system image or vendor image. That's the reason he got into this mess, be backed up and restored system image. I posted the solution a couple of posts back.
okay so i tried to recover Data System Boot, still didn't work. so i remove everything including twrp and installed stock rom. and then i installed twrp 3.0 and somehow it worked and my device is back on
oneandroidnut said:
The solution i used when i incorrectly updated vendor image and then tried to restore old system image and vendor image was to use Nexus Tool kit by wugs fresh to flash back to stock while keeping internal card intact. Then flash the rom you were on with correct vendor image in TWRP 3.0.0.0 and then restore your twrp backup without the vendor image etc and boom should be back to normal. At least that is what worked for me. What should you backup and restore? I back up everything and restore everything but vendor stuff. any suggestions?
Click to expand...
Click to collapse
this worked for me thankyou
Heisenberg said:
That seems over-complicated. You only need to backup/restore system, data, and boot. Vendor is optional if you have Layers that you want to keep. Don't backup/restore system image or vendor image. That's the reason he got into this mess, be backed up and restored system image. I posted the solution a couple of posts back.
Click to expand...
Click to collapse
i won't make that mistake again to backup vendor or system image.
Thanks @oneandroidnut @Heisenberg
setul34 said:
okay so i tried to recover Data System Boot, still didn't work. so i remove everything including twrp and installed stock rom. and then i installed twrp 3.0 and somehow it worked and my device is back on
this worked for me thankyou
i won't make that mistake again to backup vendor or system image.
Thanks @oneandroidnut @Heisenberg
Click to expand...
Click to collapse
No problem man glad it worked!!
I had the same problem.
I tried to restore a backup (MMB29Q - system+data+boot, done after installing the last factory image without root) and I got blocked on the Google logo. I tried twice without managing.
In the end I solved the problem installing supersu v2.68 zip before restarting.
It's as though the restore needs the root to work properly.
What do you think?
Thanks.
Hello everyone! I bring news from the TWRP developers from the #TWRP IRC channel! TWRP 3.0.2-1 has a fatal bug! If you backup and restore EFS it will brick you! Do not backup and restore EFS on 3.0.2-1! Use 3.0.2-0 instead! This has already been fixed in the newer builds!
If you have been bricked you NEED to Erase the EFS partitions and that will fix it immediately.
For the Nexus 6P go to TWRP. Then on PC Open Command Prompt with access to ADB ( Android Debug Bridge) and execute the following commands:
ADB shell dd if=/dev/zero of=/dev/block/platform/soc.0/f9824900.sdhci/by-name/modemst1 bs=16384
and
ADB Shell dd if=/dev/zero of=/dev/block/platform/soc.0/f9824900.sdhci/by-name/modemst2 bs=16384
This should fix it for ANY Nexus 6P users. Users on other phones with the same problem await instructions!

TWRP Backup and Restore?

Does backing up my phone using TWRP without the data partition fix the phone if it somehow got the OS removed?
CodeRida said:
Does backing up my phone using TWRP without the data partition fix the phone if it somehow got the OS removed?
Click to expand...
Click to collapse
Depends what got wiped or messed up. If it was just the System partition, then yes you can backup and restore System which should solve your problem.
It certainly helped me when I was trying to install the KangVIP rom. I couldn't initially get it to boot, so I restored previously backed up stock Boot and System partitions and all was fine.

Categories

Resources