FORUMS
Remove All Ads from XDA

[Guide] Types of Android backups

1,700 posts
Thanks Meter: 911
 
By scandiun, XDA Ad-Free Senior Member on 28th May 2012, 04:02 PM
Post Reply Email Thread
Since I switched from iPhone, that has a unique complete backup solution for everything, except that doesn't back up the jailbreak itself:
OSXDaily: How to Backup your iPhone
MacRumors: How to make a complete backup/sync of iPhone

I am looking for different backup solutions for Android. Please help me list all of them and correct my mistakes:
  • Google Sync: stores on the cloud Contacts, Calendar, Docs / Drive, Gmail, Google Photos, Google Reader, a thing called Internet and Instant. It is supposed that can store your apps' data in the cloud to sync it between devices, starting from Android 4.3.
    [INFO] List of games that do and don't support Google Saved Games
  • Google Saved Games (Cloud Save): is a feature introduced in Google Play Services. It allows any game to save and restore your progress using your Google account, so you can play Plants vs Zombies 2 in several android devices and keep the progress in all of them up to date. It depends on each game to have or not the feature implemented, depending on the developer (it's not automatic). If developers wish to do it, you could even sync progress between android, iOS and windows phone, considering that google play services is available on it.
  • Dropbox, and similar: mainly for user data on user's demand. There are a lot of cloud websites and software with different features. There are some platform specific (Apple iCloud, Microsoft SkyDrive, BlackBerry Business Cloud) or content specific. Usually each one requires to be registered with an username and password causing a babel tower and very hard to administrate for the average hit and run user. Furthermore, cloud specs can vary from time to time. You can start with promotional 5 GB storage for two years and then cut down or any other variants. Ir requires as well a fast internet connection to be considered time productive.
  • Titanium Backup: backup only for applications itself and some of the data generated by them, but not all. For example a camera application will save its settings but not the pictures generated with it, the same applies to GPS loggers, etc. It will backup data and obb files on sdcards. It can backup some system setting as well, and can restore from Nandroid backups. Is very useful for operating with individual apps, or to backup and restore "as is" between different devices or the same. Some issues may arise because of this, however, because of incompatibilities between devices of for things that are not meant to be restored. An ADB backup is better in this case.
    Titanium Backup - Basic Guide
    Titanium Backup Decrypter
  • ADB backup: you can backup applications with its data, and even the sdcard, but requires a computer with Android SDK installed and command line. Some applications and files may not be backed up depending on application' policies, and to restore the app data requires the app to be installed first, or at least include it within the backup. Automatic installation of apps is not done automatically by adb. It's not a complete backup like Clockworkmod, although has the advantage that does not require rooting or bootloader unlocking and is compatible with device encryption. Also takes care to operate in a compatible way to backup and restore between different devices and versions of Android, which you are up to yourself with Nandroid backups. Also allows to backup the whole sdcard, but is recommended to do it in a separate backup because of known issues. See:
    [GUIDE] Full Phone Backup without Unlock or Root. To convert the android adb ab backup format to tar format check here: [Q] Unpack backup.ab created by "adb backup" command?
    Full local backup infrastructure
    [GUIDE] How to extract, create or edit android adb backups
    Note that apps that explicit android:allowBackup="false" on the AndroidManifest.xml won't be backed up with adb backup. The only solution here is to patch the apk and set the value to true:
    If the flag is not set, then android will decide whether to make the backup for the app or not depending on the android version.
    Since android 6.0, the flag android:allowBackup defaults to true when omitted. Check which apps specify "false" and patch them or use root methods:
    [GUIDE] How to enable adb backup for any app changing android:allowBackup
    Auto Backup for Apps
    App Manifest <application>
    Also, some settings like Notification settings or Permissions settings are not backed up, so you will need to readjust them after restoring the backup.
  • Samsung Kies: only for Samsung devices
  • LG Backup and Sony Backup and Restore: they come preinstalled on recent smartphones from those companies. Those apps allows to backup launcher settings, personal data and apps in a very similar way to adb backups, but in LBF (LG Backup Format) and SBF (probably Settings Backup Format) for LG. Sony will use DBK or "Internal storage/.semc-fullbackup" files or store data on folders like "Documents\Sony\Xperia Companion\Backups" on Windows or "Android/data/SonyBnR/Backup" on the internal or external sd of the phone. This is the recommended method for non-root users, because is exactly like adb backup but takes into consideration specific Sony or LG settings, for the launcher, etc. The downside is that doesn't backup apps with allow:androidBackup="false" so the things explained on the previous point also apply.
  • Nandroid, TWRP or ClockWorkMod Recovery (CWM): it creates a 1:1 backup of the phone except for some minor partitions and the sd cards.

    It usually backups the partitions to the internal sdcard, although some versions of CMWR allow to backup to external sdcard (called by they as internal sdcard, or emmc). The device has to support external sdcard of course. In any case you must have enough free space.

    Is the complete backup solution by far. It means that if you reset all and you restore is impossible to distinguish that it has been done.

    It is usually done with ClockWorkMod Recovery application. At this time the ClockWorkMod does not backup the /efs and /misc partitions, so you should do it manually because are very important.

    Note that since some applications store their data or configuration in the /sdcard such info is not necessarily included in the Nandroid itself, so if for some reason you format the sd card you lose that data and can't restore it later from the Nandroid backup. If you keep the sdcard you can use that data for other ROMs.

    This is clearly visible for example the camera app. While the camera settings are stored in data partition in /data/data/com.sec.android.app.camera/ folder (which is included in Nandroid backup); the photos or videos taken are usually stored on the sdcard, usually in /mnt/sdcard/DCIM/ folder and are NOT included in Nandroid backups. Remember, the SD cards internal or external go separate in Android backups.

    You can start ClockWorkMod Recovery from a sdcard in live mode, without affecting the phone contents (this means no root, no yellow triangle, no flash counter affected, no kernel, rom, firmware or user data affected) unless you intentionally do it. The other way is to flash a custom kernel like cf-root, sihya. The live CWM.zip is here:
    CWM.zip - Live ClockWorkMod Recovery

    For backing up the internal sd you can use mass storage mode on devices supporting it. Note that MTP and PTP is not the same.
    How to enable USB mass storage on Android 4.0 ICS Samsung Galaxy S2
    [GUIDE] MTP and PTP (Media Transfer Protocol) vs UMC (Mass Storage Class)

    To backup directly to your computer:
    [GUIDE] How to make a nandroid backup directly to your computer without using sdcard

    To recover lost data on a partition (example with sdcard):
    [GUIDE] Internal Memory Data Recovery - Yes We Can!

    For more information about the partitions read here:
    Android Partitions Explained: boot, system, recovery, data, cache & misc

    To use a file manager from recovery directly (NOTE: you may have to mount some partitions in order to access them from the filesystem, for example the efs. There's an automount option as well)
    Aroma Filemanager: The World's First ANDROID Recovery Based Filemanager
    Manage Your Files from Recovery with AROMA File Manager

    To extract android adb ab backup format check here: [Q] Unpack backup.ab created by "adb backup" command?.
    You can do it that way, you need dd and openssl. You can do it from linux, mac or windows with cygwin:
    Code:
     dd if=mybackup.ab bs=24 skip=1 | openssl zlib -d > mybackup.tar

    To backup the /efs partition use root explorer on the top directory, long press on the efs folder and Tar it.

    The permissions for the /efs folder may look like that:
    Code:
    ls -lR /efs > /sdcard/efs.ls.txt
    Code:
    /efs:
    drwxrwxr-x radio    system            2012-04-20 17:36 bluetooth
    -rw-rw-rw- system   system          6 2000-01-01 01:01 calibration_data
    -rw-r--r-- system   system          9 2011-01-01 00:01 cryptprop_applied_result
    -rw-r--r-- root     root            1 2000-01-01 01:04 cryptprop_essiv
    -rw-r--r-- system   system          5 2012-04-19 20:25 cryptprop_lock_pattern_autolock
    -rw-r--r-- system   system          6 2012-04-19 20:25 cryptprop_lock_pattern_tactile_feedback_enabled
    -rw-r--r-- system   system          5 2012-04-19 20:25 cryptprop_lock_pattern_visible_pattern
    -rw-r--r-- system   system          6 2012-04-19 20:25 cryptprop_lockscreen.password_type
    -rw-r--r-- system   system          5 2012-04-19 20:25 cryptprop_lockscreen.patterneverchosen
    -rw-r--r-- root     root            5 2012-04-20 20:17 cryptprop_onetimeboot
    -rw-r--r-- system   system         14 2012-04-20 01:02 cryptprop_persist.sys.timezone
    -rw-r--r-- root     root            1 2011-01-01 00:00 cryptprop_rebootMode
    -rw-r--r-- root     root            3 2012-04-20 20:17 cryptprop_securewipedata
    drwx------ system   system            2011-01-01 00:01 dmp
    -rw-rw-rw- system   system        256 2011-01-01 00:00 edk_p
    drwxrwxr-x radio    system            2012-03-05 14:55 imei
    -rw-rw-rw- radio    radio        1438 2011-01-01 01:00 nv.log
    -rwxr-xr-x radio    radio     2097152 2012-05-31 16:20 nv_data.bin
    -rwx------ radio    radio          32 2012-05-31 16:20 nv_data.bin.md5
    -rwxrwxr-- radio    radio         880 2011-01-01 01:02 redata.bin
    -rw-rw-rw- radio    radio           1 2012-04-20 17:36 upgaddr
    drwxrwxr-x radio    system            2012-04-20 17:36 wifi
    
    /efs/bluetooth:
    -rwxrwxr-x radio    radio          17 2012-04-20 17:36 bt_addr
    
    /efs/dmp:
    drwx------ system   system            2011-01-01 00:01 sett
    
    /efs/dmp/sett:
    drwx------ system   system            2011-01-01 00:01 secure
    drwx------ system   system            2012-04-20 16:20 system
    
    /efs/dmp/sett/secure:
    
    /efs/dmp/sett/system:
    -rw------- system   system          1 2012-04-20 20:17 airplane_mode_on
    -rw------- system   system          1 2011-01-01 00:02 dtmf_tone
    -rw------- system   system          3 2012-04-20 13:41 screen_brightness
    -rw------- system   system          1 2012-04-20 13:41 screen_brightness_mode
    -rw------- system   system          6 2012-04-20 16:21 screen_off_timeout
    -rw------- system   system          1 2011-01-01 00:02 sound_effects_enabled
    -rw------- system   system          2 2011-01-01 00:01 time_12_24
    -rw------- system   system          1 2011-01-01 00:01 vibrate_on
    -rw------- system   system          1 2011-01-01 00:01 volume_ring_last_audible
    
    /efs/imei:
    -rw-rw-rw- radio    radio          23 2012-03-05 14:55 bt.txt
    -rw-rw-r-- radio    radio           2 2011-01-01 01:16 keystr
    -rw-rw-rw- radio    radio           3 2011-01-01 00:02 mps_code.dat
    
    /efs/wifi:
The Following 10 Users Say Thank You to scandiun For This Useful Post: [ View ] Gift scandiun Ad-Free
 
 
28th May 2012, 04:55 PM |#2  
jethro650's Avatar
Senior Member
Thanks Meter: 257
 
Donate to Me
More
Quote:
Originally Posted by scandiun

Since I switched from iPhone (that has a unique complete backup solution for everything, except that doesn't back up the jailbreak itself: http://osxdaily.com/2010/06/22/how-t...p-your-iphone/)

I am looking for different backup solutions for Android. Please help me list all of them and correct my mistakes:

  • Titanium Backup: backs up only applications itself and some of the data generated by them, but not all. For example a camera application will save its settings but not the pictures generated with it, the same applies to GPS loggers, etc. I think this app can't backup everything.
  • Nandroid: it creates a 1:1 backup of the phone. I mean if you reset all and you restore is impossible to distinguish that it has been done.
  • ClockWorkMod Recovery: I don't know if is the same as Nandroid
  • adb with Android SDK: supposedly you can backup parts of a whole backup:
    adb backup -all -f C:\backup.ab
  • Samsung Kies: only for Samsung devices

Titanium Backup-an app to back up apps and data as you said, camera app-pics are usually stored on your sd card and are not wiped when flashing ROMs, not sure about the newer phones that only have internal memory. As it is only an app there are of course others that do the same thing such as My Back Up root and its variants which can back up apps, data, contacts, photos and certain system data such as phone settings and home launcher settings. In all cases the back up is stored in a folder on your sd card.

Nandroid and clockworkmod recovery go hand in hand. You make a nandroid backup, or just nandroid for short, through clockworkmod recovery or any other recovery that can make one, so, recovery is where you make it and nandroid is what the backup is called.

Then there is your google account itself when synced to your phone. When synced many things are stored in cloud type storage in your google account such as contacts and calendar and notes(gnotes) and documents (gdocs) and are accessablr through any android phone you sync with your google account, very useful when switching phones, simple as adding your google account to the phone and a few minutes to sync, everything your have told it to sync is now on your new phone.
The Following 2 Users Say Thank You to jethro650 For This Useful Post: [ View ] Gift jethro650 Ad-Free
28th May 2012, 07:45 PM |#3  
scandiun's Avatar
OP Senior Member
Thanks Meter: 911
 
More
So the mentioned ClockWorkMod Recovery does not backup the sdcard (internal or external) mounted at /mnt/sdcard/ and /mnt/sdcard/external_sd/ respectively? But does backup of the other mount points root included / ?
29th May 2012, 10:57 AM |#4  
jethro650's Avatar
Senior Member
Thanks Meter: 257
 
Donate to Me
More
Correct on both points. A nandroid is a snapshot of your system at that time, the ROM, themes, tweaks, add-ons, everything but the sd cards.

Sent from my HTC Vision using xda premium
The Following 2 Users Say Thank You to jethro650 For This Useful Post: [ View ] Gift jethro650 Ad-Free
29th May 2012, 04:10 PM |#5  
scandiun's Avatar
OP Senior Member
Thanks Meter: 911
 
More
Quote:
Originally Posted by jethro650

Correct on both points. A nandroid is a snapshot of your system at that time, the ROM, themes, tweaks, add-ons, everything but the sd cards.

Sent from my HTC Vision using xda premium

Thank you. I've discovered that ClockWorkMod does not backup the /efs and /misc partitions that are important in some devices. That CWM is the best suitable for me.
29th May 2012, 08:22 PM |#6  
Junior Member
Thanks Meter: 0
 
More
How I perform a full backup of a stock rom?
29th May 2012, 09:19 PM |#7  
scandiun's Avatar
OP Senior Member
Thanks Meter: 911
 
More
Quote:
Originally Posted by ClaudioVic

How I perform a full backup of a stock rom?

The easiest way, you have to force your phone to load the recovery partition when powering on. It depends on the phone, on SGS2 it is home+volup+power.

Then you load from there the ClockWorkMod that does the backup (is the CWM.zip that you need to put on a sd card.

From there load the CWM.zip and then backup. It creates a folder withing the internal sdcard of the phone, you need enough free space.
Attached Files
File Type: zip CWM.zip - [Click for QR Code] (1.51 MB, 1733 views)
The Following User Says Thank You to scandiun For This Useful Post: [ View ] Gift scandiun Ad-Free
30th May 2012, 12:59 PM |#8  
Junior Member
Thanks Meter: 0
 
More
Question
Quote:
Originally Posted by scandiun

The easiest way, you have to force your phone to load the recovery partition when powering on. It depends on the phone, on SGS2 it is home+volup+power.

Then you load from there the ClockWorkMod that does the backup (is the CWM.zip that you need to put on a sd card.

From there load the CWM.zip and then backup. It creates a folder withing the internal sdcard of the phone, you need enough free space.

I know that,but installing ClockWorkMod isn´t modfying the ROM?
When I restore will it restore the stock Recovery mod?
What about the /efs and that sort of things, how do we backup?

Thank you
30th May 2012, 03:19 PM |#9  
scandiun's Avatar
OP Senior Member
Thanks Meter: 911
 
More
Quote:
Originally Posted by ClaudioVic

I know that,but installing ClockWorkMod isn´t modfying the ROM?
When I restore will it restore the stock Recovery mod?
What about the /efs and that sort of things, how do we backup?

Thank you

Well, in case you didn't know, you can use ClockWorkMod Recovery WITHOUT installing it, like a linux livecd if you have ever tried.

Running that CWM.zip from the sd card will be a live copy of CWM from the sd but will not modify the /system partition that is where the ROM stored or any other partitions unless you begin doing stuff you don't know of. From there the only partition affected will be the /sdcard that will store there the clockworkmod folder with backup inside but the ROM, kernel and recovery partitions will remain unaffected. You can restore the same way having the backup already in the sdcard OR install a custom ROM.

You can install the CWM to the phone with custom ROMs loading them as a backup, so you don't need anymore the external sd card but the system will not be stock kernel.

To backup /efs or /misc I don't have tried it yet, will add more info as I find it.
8th July 2012, 04:49 PM |#10  
Member
Thanks Meter: 4
 
More
Exclamation i want to ask, can I?
hi!
i want to ask, can I?
u say Nandroid backup didn't included sd card data( esp : internal) ?
is that mean files such pics (taken from camera, even using apps such as "PicsArt", "Camera 360", etc) , videos saved from bluetooth, and esp games data ( what i mean is my games saved data, like "MIB 3" which saved data automatically, and also some other .txt, html, etc). will be erased after perform flash latest firmware and wipe all user apps data from cwm touch recovery mode?

can i restore back my photo and other things that i mention on above?

if no, is there anyone can provided me some apps that can backups sd card data?
please, i need a solution..
any help will be appreciated, thx in advanced for any help to..
8th July 2012, 05:57 PM |#11  
scandiun's Avatar
OP Senior Member
Thanks Meter: 911
 
More
Quote:
Originally Posted by Serdxx

hi!
i want to ask, can I?
u say Nandroid backup didn't included sd card data( esp : internal) ?
is that mean files such pics (taken from camera, even using apps such as "PicsArt", "Camera 360", etc) , videos saved from bluetooth, and esp games data ( what i mean is my games saved data, like "MIB 3" which saved data automatically, and also some other .txt, html, etc). will be erased after perform flash latest firmware and wipe all user apps data from cwm touch recovery mode?

can i restore back my photo and other things that i mention on above?

if no, is there anyone can provided me some apps that can backups sd card data?
please, i need a solution..
any help will be appreciated, thx in advanced for any help to..

Nandroid does not backup neither the internal sdcard nor the external:

[Q] Does nandroid backup sdcard?
[Q] (Clockwork Mod) What is Nandroid Backup and How Does it Work?
[Q] can nandroid not backup the sdcard?

For the external sdcard, you just can unplug it from the phone and make a easy backup on the computer, or putting it on UMC (Massive Storage Mode) from Settings -> More... -> USB Utilities -> Connect Storage to PC.

For the internal sdcard, if it an independent partition on the device, like in the Galaxy S2, you can put it in UMC as well in the previous step.

If your device has the sdcard as a subfolder of the data partition (sdcard goes in /data/media) like Galaxy Nexus or Galaxy S3, then you can use MTP but is not a complete solution; see [GUIDE] MTP and PTP (Media Transfer Protocol) vs UMC (Mass Storage Class).
In this case if you want an exact backup you must other methods. They will be added as soon as possible.
The Following 2 Users Say Thank You to scandiun For This Useful Post: [ View ] Gift scandiun Ad-Free
Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes