[Q] What does a nandroid backup contain? - Droid Incredible Q&A, Help & Troubleshooting

When I perform a backup from recovery (or via a front-end such as ROM Manager), what exactly is saved?
Is it like a clone of a hard drive in the PC world?
Does it contain only data, and not the actual ROM?
How should I go about using such a backup when doing a restore? Should a ROM be installed first, followed by the restore? If so, must the ROM match the backup exactly -- that is, must it be the ROM under which the backup was performed in the first place?

kirkers said:
When I perform a backup from recovery (or via a front-end such as ROM Manager), what exactly is saved?
Is it like a clone of a hard drive in the PC world?
Click to expand...
Click to collapse
That's a pretty close analogy. Only difference is I don't think it captures partitions...but I'm not sure about that. (It's not clear to me, for instance, if you did a nandroid of a phone with the EXT4 mod implemented and tried to install it on a phone without the EXT4 mod, exactly how that would play out.)
As an example, though, I took a nandroid of my stock phone immediately after I rooted it and got S-off. I then played around with various CM7, CM9, and JB ROMs for a weekend, but reloaded the stock nandroid Sunday night before going back to work on Monday. (I need a reliable phone for work.)
My phone was restored to exactly the way it was when I took the nandroid snapshot. I had to re-download a handful of app updates and email that had arrived since the time I took the nandroid to "catch up" to the present time, but that's all.

kirkers said:
When I perform a backup from recovery (or via a front-end such as ROM Manager), what exactly is saved?
Is it like a clone of a hard drive in the PC world?
Does it contain only data, and not the actual ROM?
How should I go about using such a backup when doing a restore? Should a ROM be installed first, followed by the restore? If so, must the ROM match the backup exactly -- that is, must it be the ROM under which the backup was performed in the first place?
Click to expand...
Click to collapse
It is everything on your phone at the current time when you made a backup. Including your rom, apps, files, boot animation and e.t.c.
Sent from my EVO using Tapatalk 2

Impact of EXT4 partition on nandroid backup + restore?
sully9292 said:
It is everything on your phone at the current time when you made a backup. Including your rom, apps, files, boot animation and e.t.c.
Click to expand...
Click to collapse
MysticCobra said:
[The PC clone image is] a pretty close analogy. Only difference is I don't think it captures partitions...but I'm not sure about that. (It's not clear to me, for instance, if you did a nandroid of a phone with the EXT4 mod implemented and tried to install it on a phone without the EXT4 mod, exactly how that would play out.)
Click to expand...
Click to collapse
Thanks for the clarifications and the personal experience story. It helps calm my nerves. :fingers-crossed: Now it is clear that the nandroid is a full snapshot, close to being a clone image.
Can anyone address MysticCobra's point about the EXT4 partition?
As a rule, I have followed ROM Manager app's recommendation to partition the sdcard to allow apps to be stored on it. This is what the EXT4 partition is designed to do, as far as I understand such things.
If I format the sdcard with EXT4 (which in my experience wipes out all data on the card), and then restore a nandroid that came from an older EXT4-formatted sdcard of the same size or smaller than the new sdcard, would the nandroid restoration go smoothly?
What would happen if the new sdcard did NOT have an EXT4 partition?
Thanks in advance for further advice.
:good: Cheers!

kirkers said:
Thanks for the clarifications and the personal experience story. It helps calm my nerves. :fingers-crossed: Now it is clear that the nandroid is a full snapshot, close to being a clone image.
Can anyone address MysticCobra's point about the EXT4 partition?
As a rule, I have followed ROM Manager app's recommendation to partition the sdcard to allow apps to be stored on it. This is what the EXT4 partition is designed to do, as far as I understand such things.
If I format the sdcard with EXT4 (which in my experience wipes out all data on the card), and then restore a nandroid that came from an older EXT4-formatted sdcard of the same size or smaller than the new sdcard, would the nandroid restoration go smoothly?
What would happen if the new sdcard did NOT have an EXT4 partition?
Thanks in advance for further advice.
:good: Cheers!
Click to expand...
Click to collapse
Nandroid backup/restores don't touch the sdcard. They backup to the sdcard but the nandroid only handles /system, /data, /data/data, /cache, boot, and recovery.
The ext4 partition is not the same as the ext4 mod that MysticCobra mentioned. The mod converts /data, and /cache to ext4 and changes the ramdisk to mount them as ext4. The no data limit one also disables the mounting /data/data so the phone will share the apps and app data with a 750MB. Your app data is intact with the no data limit mod but a backup is still advised. No wipe updates don't touch the filesystem in /data or /cache but the mod may need to be flashed again for the ROM to boot correctly as the ramdisk is overridden on all updates. Technically with the normal data one you are good on later cm7 and ICS/JB ROMs as it's already ext4.
If you want to undo the mod the best thing is to wipe /data and /cache and reflash the ROM.
For further reading check the first link in the link below:
http://forum.xda-developers.com/showthread.php?t=1623038

Related

[Q] What should be backed up in Amon RA nandroid backups?

I recently upgraded my Amon RA to the latest build (2.3)
I like all the new choices but I'm confused about what I should be backing up when making a Nandroid.
I made one that backed these parts up:
[x] boot
[x] system
[x] data
[x] wimax
Is that good enough? Should I backup recovery too? I understand sd-ext and .android-secure backups will take more space and time to create. But are the ones I listed above pretty much the only essential things if I ever need to flash a backup?
yep...
I would make a backup of just wimax, then there would be no need to back it up again.
Depends on your amount of paranoia about being able to recover. I backup my entire phone, including my SD card, prior to flashing any ROM. So far I haven't had any issues recovering. Granted I'm new to rooting and flashing ROMs...so haven't had enough time to really bork things up.
I know my b/u is over kill, but I'd rather spend the few extra minutes getting everything than find out I missed something if I need to recover.
HTC Evo
Rooted, but still stock...for now
----------------------------------------
The program is designed to work, if it's not, we have a problem.
You are good to go with your backup scheme.
You don't need to backup WiMax every time. Just back it up once, separately, then backup boot, data, and system regularly.
i have four or five nands on my card that i checked every option for. cant hurt...
Thanks for all the replies guys.
I'll take it all into account and do an "in case of catastrophic data loss" backup (in other words, full on backup, full checks)
And keep it to the OP scheme i had for future backups.
@n00bhackin
I'm the same way. Better safe than sorry.
Yep, wimax is a seperate backup.
Before backup, wipe cache and dalvik cache (reduces size of backup file and forces dalvik to be rebuilt when recovered).
At a bare minimum: boot, system, data
If you use apps2sd, backup .android.secure also unless you want to reinstall some apps.
If you use apps2sd to a ext3 partition on your SD, backup SD:ext for the same reasons above.
If your not sure which apps2sd you are using;
1) check on your SD the folder .android.secure, got apps there then its option 1.
2) if you use dark tremors apps2sd, then you know what it does and you back up option 2.
It would be awesome to have a .ini file on the sd with various defaults already enabled.
Maybe next in the next version

[Q] What information from Nandroid is stored in 'boot'?

After successfully S-Off'ing my desire I had problems booting the phone after restoring my nandroid backup. A full restore would result in bootloops.
I originally thought this was because the custom Oxygen table I had applied was too small, but on trying others, I had the same result.
In recovery, under advance restore options, I only restored the following elements of the nandroid backup:
sd-ext
system
data
cache
I didn't restore 'boot'.
This prevented the boot-loops and I seem to have my phone functioning as before with nothing missing...
So, my question is, what data was in 'boot' and did I need it?!
If anyone cares to tell me why the full nandroid caused these issues, then please do!
Finally, if the above is answered, I assume I'm ok to flash the custom Oxygen hboot and restore all again other than 'boot'? Users were checking the 'size' of their nandroid backups, but I could work out how to do this?
Thanks in advance.
Data stored in '/boot' is used help in the process of loading the Android OS when you turn on your phone. The '/boot' partition is used to set up all the other partitions (i.e. /data, /cache, /system...). S-OFF just suspends a security feature and puts a new S-OFFed bootloader(this is not in /boot). You have to do a FULL WIPE after performing the S-OFF before doing the full restore.
If you flashed the custom Oxygen HBOOT, then you have to install a new ROM that will fit inside the '/data' or '/system' partition (can't remember which one exactly...I think it's /system). Restoring your previous ROM will cause problems as it may not be able to fit in.
As for checking the size of the nandroid backups, connect the phone to a PC and mount it as the USB Drive. Go into the SD card and under your recovery folder (which will be named as 'ClockworkMod' or to the one you are using) you'll be able to find all your backups. Check their properties....
Appreciate the info, thank you. I think I only flashed a new ROM after my nandroid restore failed... I'll have another go and install fresh ROM straight after the custom hboot.
Thanks again.
Sent from my HTC Desire using XDA Premium App
No worries...
This was extremely valuable info. It restored back to the Backup with out a hitch. Thanks alot. Dude you Rock! Very clever!

Question about nandroid backup if you have DarkTremor A2SD

As anyone with DarkTremor's A2SD is well aware, the sd-ext partition is utilized as a symbolic link from within /data.
As a user of a custom recovery with the nandroid backup/restore feature, you're also well aware that you can back up both data and sd-ext.
If you choose to back up both, you end up with two large img's... the one for sd-ext being slightly larger than the one for data. Both of these img's contain all of the stuff within data (what a waste of space!).
Since sd-ext includes data (when using DT's A2SD), is it sufficient to only back up sd-ext, and not data as well? Basically, what should I be backing up? Seems wasteful to back up both-- If I back up only sd-ext, I'm concerned that the /data dir will never be created. And if I back up only /data, I'll miss the extra 30 or so megs that the sd-ext img has over the data img (what makes up that difference, I'm not quite sure).
Any thoughts?
Make a backup in each form that you discribed and check the results after trying to restore your backup of question.
Sent From DEEZ
popper668 said:
Make a backup in each form that you discribed and check the results after trying to restore your backup of question.
Click to expand...
Click to collapse
Yeah, I COULD do that... but I figured at least a hundred people on here have already figured this one out before me.
No risk no reward!
Sent From DEEZ
I use a2sd and I nandroid everything, but cache and regularly go back to nandroids of my stock/rooted ROM and back with no problems. That's the reason I back up all of it, just in case. I'd rather be safer than sorry.
popper668 said:
No risk no reward!
Click to expand...
Click to collapse
No sh!t, but there's likely some who've already done it. Isn't that the point of the Q&A forum-- so those who aren't sure about taking risks can ask questions, and gain expertise from those who already have?
You my friend are lazy and snotty, sorry I replied.
Sent From DEEZ
BigMatza said:
No sh!t, but there's likely some who've already done it. Isn't that the point of the Q&A forum-- so those who aren't sure about taking risks can ask questions, and gain expertise from those who already have?
Click to expand...
Click to collapse
I don't back up sd-ext personally because I never wipe it before a flash. There is no real need, unless you are using newer mik roms.
popper668 said:
You my friend are lazy and snotty, sorry I replied.
Click to expand...
Click to collapse
I'm looking for someone to explain a little bit about the difference between backing up data and sd-ext when using DT's A2SD. You haven't offered any explanation-- you only pointed out the obvious.
There are a LOT of lazy questions in this forum. Unless you happen to know the answer to mine or can show me where my search failed, go harass someone else ya f*ckin' troll.
I do, however, appreciate that your replies continue to bump my thread... so thanks for that I guess.
If DTA2SD is utilized then the APKs are not on the phones internal storage, they are on the sd-ext.
However all of the saved information from the apks (logins/game saves and such)are not on the sd-ext, that is stored on the internal memory.
So, lets say you do a nand backup without the sd-ext.
1 - if you wipe the sd-ext then nand back, your apks will not be restored, but when you re-install the apks, your saved info from the time you backed up will be restored. All you have to do is re-install the apk.
2 - if you dont wipe the sd-ext and then nand back, all of your info and apks will still be there, but if you installed another apk after you did the nand, any info you have saved from that particular apk will be gone(not the apk itself).
Now, lets say you do a nand backup with the sd-ext.
All apks and information from the time you did your backup will be restored, but again if you have installed any apks after the nand, they will be gone, along with any saved information.
Side note:
Because the saved information is not on the sd-ext, there is no need to wipe the sd-ext before flashing a new or updated rom. It is the same as having apks pre-installed. Doing this keeps you from having to redownload all of your favorite apps, but any saved info will be wiped out.
The only exception is when developers move system apps to /data(such as the newer mik roms). If they do that, then you may have to wipe the sd-ext before flashing new or updated roms.
If you wish to keep the saved information from your apks between rom flashes, then I would suggest backing up the data through Titanium backup. However you may experience problems restoring data from certain apks, so to be safe i only restore data from apps i know do not cause issues. Most games do not cause issues, but retoring data from apps like lookout have been known to cause bootloops and such.
Hope this helps.
Lots of good info there... thanks!
I know for sure that the data.img in my nandroid backup holds apks. If it didn't, there'd be no way it could be 300MB. Similarly, my sd-ext is a little larger (like 311MB).
So what happens if I don't wipe my sd-ext, but wipe my data instead? Since components of data are within sd-ext (specifically, the apks), wouldn't that in turn wipe most of sd-ext too (since it would follow the symbolic links)?
BigMatza said:
Lots of good info there... thanks!
I know for sure that the data.img in my nandroid backup holds apks. If it didn't, there'd be no way it could be 300MB. Similarly, my sd-ext is a little larger (like 311MB).
So what happens if I don't wipe my sd-ext, but wipe my data instead? Since components of data are within sd-ext (specifically, the apks), wouldn't that in turn wipe most of sd-ext too (since it would follow the symbolic links)?
Click to expand...
Click to collapse
That would only happen if DTA2SD was activated, which it is not while in recovery.
As far as I know, the only folders from /data that are moved to the sd-ext are /data/app and /data/app-private. All the other folders and info remain on the internal storage. Dalvik can be moved, but it isn't set to do so by default in most roms.
Edit: What Rom are you using? I looked at my data.img from synergy and it's 190.76MB, and the last time I backed up my SD-ext it was only 77.03MB

[Q] Nandroid backup/Restore -sd ext

Hi !
i have a ROM with A2SD+ on EXT3 partition
1- First i'd like to know if Nandroid Backup make a copy of the EXT3 content .and if so does it restore the EXT3 content as it was ?
2- when i make a Nandroid restore do i have first to make a data,cache, dalvik,sd-ext wipe ?
3- Do i need to flash the ROM before flashing nandroid restore ?
4- if i have changed Radio or partition table does nandroid restore puts everything like at the moment of backup ?
thanks
Hi,
1 yes
2 I do wipe
3 no
4 no
LukenBoy said:
2- when i make a Nandroid restore do i have first to make a data,cache, dalvik,sd-ext wipe ?
Click to expand...
Click to collapse
In fact, it depends. There are few constellations where you don't need to wipe. But, to be on the safe side, just do it. Cause Nandroid restore doesn't restore an image, but files, thus w/o wiping you may end up with unneeded files.
This possibly answers your 4), too.
Greets, Magpie
I got the message like (when backup) sd-ext did not gone with restored files..?
Does anyone knows why..?
Thanks
petar17 said:
I got the message like (when backup) sd-ext did not gone with restored files..?
Click to expand...
Click to collapse
Please post the error message _literally_, cause the one you cited, makes no sense at all. At least for me ...
Greets, Magpie
petar17 said:
I got the message like (when backup) sd-ext did not gone with restored files..?
Does anyone knows why..?
Thanks
Click to expand...
Click to collapse
I think this means, when the nandroid backup is taken, it doesnot include ext backup file. Same thing happend to me.
I did some research on the problem and found a solution which seems to have worked for few people. However I have not tried it myself. I am going to do that though.
Summary of the solution
1.) Download Root Explorer
2.) Enable Root Mode/Mount System
3.) Navigate to /system/
4.) Create a new folder called 'sd'
5.) Ensure you're phone has at least 50% of battery
6.) Reboot and try the backup again.
link: http://android.modaco.com/topic/347662-error-backup-nandroid-ext-with-recovery-22/

Where to put files so a wipe won't delete them?

I've already rooted and unlocked my bootloader and I'm just about to load a custom ROM, however where do I put the files so when I wipe/factory reset they don't get deleted? Thanks.
Your files don't get deleted. Only data and apps on android partition
Sent from my Galaxy Nexus using xda premium
Brett3rThanU said:
I've already rooted and unlocked my bootloader and I'm just about to load a custom ROM, however where do I put the files so when I wipe/factory reset they don't get deleted? Thanks.
Click to expand...
Click to collapse
Anywhere outside /system. i.e. place them on the part of your sd card where your pics, music, etc... live.
Really? That doesn't seem right for some reason...I just unlocked & rooted my girlfriends new Verizon Nexus but didn't put a ROM on it right then (which I should have done ), and during that process all of her photos and apps were deleted. I luckily had backed up photos, sms backups, etc. off of the device so I was able to transfer those back, but it was bone stock (like nothing on it at all) after that process. Is that "wipe" different than the "wipe data/factory reset" we have to do before going onto most of the ROMs for the Nexus?
Sorry about my ignorance...I'm an Epic 4g Touch owner so I'm well versed in it, but just starting to learn about the Verizon Nexus. Thanks a lot guys.
Unlocking the bootloader wipes it all; but a wipe data/factory reset from CWM doesn't touch your virtual sd card, i.e. photos, etc... remain. The OP is already unlocked, so he's "safe".
I will answer your specific question, "Where to put files so a wipe won't delete them?" If you want to be safe, on your computer or on anything external other than the phone. I only say this because the phone does not have an external sd card. Ill repeat what I said in another thread...we don't backup for the disasters we foresee but for the ones we don't.
Only the factory recovery wipes the /data/media ("/sdcard") partition. Any third-party community-built recovery (like ClockworkMod Recovery or TeamWin Recovery Project) will wipe everything except /data/media.
So, to answer your question, as long as the files are on your phone's pretend SD card (the default for user-created content and files you transfer to your phone), they won't be wiped when installing a custom ROM.
CMNein said:
Unlocking the bootloader wipes it all; but a wipe data/factory reset from CWM doesn't touch your virtual sd card, i.e. photos, etc... remain. The OP is already unlocked, so he's "safe".
Click to expand...
Click to collapse
codesplice said:
Only the factory recovery wipes the /data/media ("/sdcard") partition. Any third-party community-built recovery (like ClockworkMod Recovery or TeamWin Recovery Project) will wipe everything except /data/media.
So, to answer your question, as long as the files are on your phone's pretend SD card (the default for user-created content and files you transfer to your phone), they won't be wiped when installing a custom ROM.
Click to expand...
Click to collapse
Awesome - thank you both for your responses. That's actually a pretty cool little feature. I wish my phone could have apps retained after doing a "data/factory reset" wipe, which is such a good idea when going between ROMS.
I am stating that correctly, right? Apps, app data/caches, pretty much everything but system apps will be retained after a 3rd party data wipe? I just want to be sure, especially since it's not my device I'd be messing with Thanks
DutchDogg54 said:
I am stating that correctly, right? Apps, app data/caches, pretty much everything but system apps will be retained after a 3rd party data wipe? I just want to be sure, especially since it's not my device I'd be messing with Thanks
Click to expand...
Click to collapse
No, I'm afraid not. Applications will be wiped, as they reside on /data/app. The only item not wiped is the /data/media partition. Plug your phone up to your computer - the files and folders that you see listed will remain after a full wipe. Everything else will be gone.
Though, to be technical, a "factory reset" wipe primarily wipes /data (except for /data/media) and /cache. You'll generally have to manually wipe (through recovery) /system.
codesplice said:
No, I'm afraid not. Applications will be wiped, as they reside on /data/app. The only item not wiped is the /data/media partition. Plug your phone up to your computer - the files and folders that you see listed will remain after a full wipe. Everything else will be gone.
Though, to be technical, a "factory reset" wipe primarily wipes /data (except for /data/media) and /cache. You'll generally have to manually wipe (through recovery) /system.
Click to expand...
Click to collapse
Yeah, that's what I was thinking...thought it was a little too good to be true. No biggie...that's what Titanium backup is for
So, just to play devils advocate...if I were to copy, for instance, the go sms backup file that's created when you backup files to the /data/media partition, theoretically that would be retained, correct? That's about the only thing that would be lost doing a 3rd party wipe that couldn't be TB restored...and when I talk about the go sms back up I would like to throw things like her circle launcher setup backup files, etc. in that ring...what do you think about that?
DutchDogg54 said:
Yeah, that's what I was thinking...thought it was a little too good to be true. No biggie...that's what Titanium backup is for
So, just to play devils advocate...if I were to copy, for instance, the go sms backup file that's created when you backup files to the /data/media partition, theoretically that would be retained, correct? That's about the only thing that would be lost doing a 3rd party wipe that couldn't be TB restored...and when I talk about the go sms back up I would like to throw things like her circle launcher setup backup files, etc. in that ring...what do you think about that?
Click to expand...
Click to collapse
A lot of apps (I can't speak specifically for those, unfortunately) actually keep their user-created backup files in a directory on /data/media, so those would be safe. I know that Nova Launcher, Titanium Backup, Tasker, and some others do that.
The SD card does not get wiped between rom flashes using Cwm. Only the first boot loader unlock does everything get wiped.
So all my files and pics on my SD card stay in tact when I wipe in Cwm or flash a new rom.
Hi all,
I have a similar question.. I'm wanting to know where I can safely put the ROM zip because I want to wipe the sdcard0 partitiion
If I put it in /data/media I should be able to select it from there in CWM recovery right?
lamenting said:
Hi all,
I have a similar question.. I'm wanting to know where I can safely put the ROM zip because I want to wipe the sdcard0 partitiion
If I put it in /data/media I should be able to select it from there in CWM recovery right?
Click to expand...
Click to collapse
after wiping sdcard partition, just use adb to push files to sdcard.
kyokeun1234 said:
after wiping sdcard partition, just use adb to push files to sdcard.
Click to expand...
Click to collapse
So I rebooted into recovery, formatted the sdcard.
Now when I try to push the file in adb, it's not showing up.
Tried pushing to both /storage/sdcard0 and /sdcard but they're not showing up when i ls into them from shell. In fact I can't acces /sdcard at all, but /storage/sdcard0 is empty.
I can't mount /sdcard in CWM either.
Help!
lamenting said:
So I rebooted into recovery, formatted the sdcard.
Now when I try to push the file in adb, it's not showing up.
Tried pushing to both /storage/sdcard0 and /sdcard but they're not showing up when i ls into them from shell. In fact I can't acces /sdcard at all, but /storage/sdcard0 is empty.
I can't mount /sdcard in CWM either.
Help!
Click to expand...
Click to collapse
Try /data/media, as that is where the "sdcard" data actually resides. The other locations are just links that point here
You may need to use the recovery option to mount /data.
codesplice said:
Try /data/media, as that is where the "sdcard" data actually resides. The other locations are just links that point here
You may need to use the recovery option to mount /data.
Click to expand...
Click to collapse
Thanks!
I ended up flashing back to stock and then flashed a new ROM and it seems to be working OK.
In the future, though, what should I have done different to avoid not being able to access /sdcard?
lamenting said:
Thanks!
I ended up flashing back to stock and then flashed a new ROM and it seems to be working OK.
In the future, though, what should I have done different to avoid not being able to access /sdcard?
Click to expand...
Click to collapse
I'd just try accessing it via /data/media instead. The other links may not be created before the system actually boots.

Categories

Resources