yashsingh1/xdaforums huggingface dataset:
[Samsung Galaxy Nexus] fvisagie:
On the assumption that bootlooping is caused by corruption of a partition other than data, if your phone is still on a stock Android version (i.e. no OTA or other OS updates since purchase) you can try get it booting again by sideloading select parts of the factory install image. In principle you would create a reduced factory image, boot into recovery, adb sideload the image and reboot to check results.

In all cases you would exclude from the modified image 1) the factory data partition and 2) erasing/formatting the data partition.

I'm not going to try going into details because 1) I haven't yet done this myself, and 2) if you can work out the details yourself, you are sufficiently competent to attempt such a risky procedure ;).
[Samsung Galaxy Nexus] Mixta2:
adb backup -all, did not restore all system apps/data

how to use adb backup, all steps

some claim that adb backup works for system apps and data too. i counted on that, but sadly its not working for me.

it did restore all user apps and data.

but did

not

restore my google calendar storage or google services.

any suggestion how i might fix my calendar storage without flashing FW?
[Samsung Galaxy Nexus] Neinkob:
What conditions have to be fulfilled that adb works in recovery?

When I go in fastboot mode my device is found by "fastboot devices".

When I then choose Recovery Mode, Android lies on its back with an red triangle exclamation-mark over its stomach. Then neither Windows hardware-manager nor "adb devices" find my device. When I then use Power-VloumeUp to enter the Revovery mode Menu still neither Windows hardware-manager nor "adb devices" find my device.

Only when I choose "apply update by using adb" from the recovery mode menu, my device is found by Windows hardware-manager and by "adb devices". But "sideload" is written to the right of my device. But the commands "adb backup -all" or "adb pull \data" give me "error:closed" as answer.

Where does this problem come from? Is it because of the stock recovery or could it be a problem of the usb-driver (I use http://xdaforums.com/google-nexus-5/development/adb-fb-apx-driver-universal-naked-t2513339 )? Does anybody have an idea why this doesn't work?
[Samsung Galaxy Nexus] fvisagie:
What you experience is expected behaviour for stock recovery - adb only works for sideload.

If you want/need to use adb during recovery, use a custom recovery that supports it, e.g. CWM Recovery.
[Samsung Galaxy Nexus] Jake007g:
Awesome guide. Gonna give this a go when I get home.
[Samsung Galaxy Nexus] chuckboy1129:
my phone doesnt prompt me to do a full restore after i do the adb commands is there something i have to turn on in the phone
[Samsung Galaxy Nexus] Miles00x:
I only have adb and fastboot installed

No JDK or full android SDK installed here but this method seems to be working for me! Thanks!
[Samsung Galaxy Nexus] 1ondroid:
if I want to back up just apk and app's data (no need extSD nor device photo music, video backup) is this correct?

adb backup -apk -nosystem -noshared -all
[Samsung Galaxy Nexus] fvisagie:
To be safest, you may want to add '-obb', and replace '-nosystem' with '-system'. I haven't compared results, but as I understand adb's help output, '-nosystem' will exclude system apps and system app updates stored on your /data partition. I.e., I suspect with '-nosystem' you'd only back up apps you installed, and after restoring to a clean /data partition would have to redo all updates to system apps previously stored there.

See 'adb help'.
[Samsung Galaxy Nexus] 1ondroid:
tks. I am going to try it. also I will try it anyway but wanted ask (any Linux users here?) this should work fine on Linux adb right?
[Samsung Galaxy Nexus] lkjsoiuew:
adb backup just stops

I tried several times now to

adb backup -apk -shared -all -f LGBackup.ab

on my LG E975 with cm-12.1 and rooted. After about 1,5 GB it just stops. No error message, just the "finished" toast. This is somewhere in the middle so half of the apps is missing, for example everything with org.... and after. Why?

I tried over USB and network, same thing.
[Samsung Galaxy Nexus] fvisagie:
If those are system apps (they don't seem to be), you can see if adding '-system' helps, although adb supposedly defaults to that setting.

However, bear in mind that not all apps are necessarily configured to be included in such backups. The Android Backup Extractor Readme explains in more detail. For such apps, specifying '[<packages...>]' on the adb command line is probably the last straw to clutch at, although I haven't yet tried that myself.

For whatever apps you do manage to back up, you may want to add '-obb'.
[Samsung Galaxy Nexus] lkjsoiuew:
Now I used -noshared and -obb and it worked, although I didn't find anywhere what -obb means.

The backup options is not mentioned at all anywhere on the official sites. Why?
[Samsung Galaxy Nexus] fvisagie:
The fact that '-noshared' helped, probably points to a bug/problem with adb backup: https://code.google.com/p/android/issues/detail?id=219980. Note that using that option excludes your shared storage from the backup.

See the output of 'adb help' (or just 'adb') for more information on the options.
[Samsung Galaxy Nexus] lkjsoiuew:
Problem with the adb help is that you can't read it on any terminal whatsoever :p
[Samsung Galaxy Nexus] fvisagie:
On Windows, run 'adb help >adbhelp.txt 2>&1' without the quotes, then open adbhelp.txt in a text editor.
[Samsung Galaxy Nexus] lkjsoiuew:
yes I mean the stderr instead of stdout output
[Samsung Galaxy Nexus] 1ondroid:
i tried

adb backup -apk -shared -nosystem -obb -all

doesn't work. just doesn't start.

adb backup -all

works but after it says finished i just got a 150mb backup. ab file?? is that normal. i got 100apps..
[Samsung Galaxy Nexus] fvisagie:
Perhaps this post helps explain it.

Perhaps this post helps.
[Samsung Galaxy Nexus] Pr0je3ct:
Hello everybody, first id like to say thanks to the OP , was happy to find this tread, i went trough couple pages to get the essence of the proccess and see for any positive feedback, i just downloaded and installed JDK and android sdk, connected my android to the laptop and run the command : adb devices - but the command is not recognized, i went back to system properties to add java to the environment variables ( Name: Path , value : C:Progamm Files\java\jdk1.8.0_102\bin) but still nothing.... any advise or solution???

Ill appreciate a quick response

Pr0je3ct

EDIT: ooh im always soo hashing with questions, anyway i noticed by opening sdk manager that i didnt installed the 'Android SDK Platform-Tools and build tools(which i assume are necessary for the proccess ) im downloading them, i guess i have to set an environment variable for it too, or? Before anyone ask , i already have adb drivers installed, so i hope installing the platform tools will fix my issue
[Samsung Galaxy Nexus] GCalzo:
You do not need the complete SDK, just few files that can be installed with [TOOL]Minimal ADB and Fastboot [4-27-16] or [TOOL] [WINDOWS] ADB, Fastboot and Drivers - 15 seconds ADB Installer v1.4.3
[Samsung Galaxy Nexus] Pr0je3ct:
Oh thanks pal
[Samsung Galaxy Nexus] bkz81:
I backed up a note 7 (before the recall) now when i try to do a restore on the new note 7 the screen says i want to do a backup? I did the first backup with no password, and it's about 800MB.
[Samsung Galaxy Nexus] loveymangal:
Need some help

I tried backing up my oneplus 3 like this but i am not able to get any response from my phone. I set up the desktop password as you mentioned and tried running the command but in my cmd windows it finishes in a sec and in mobile nothing happens also the backup file made is empty

adb backup -all worked but not

adb backup -f FullBackup.ab -apk -all

can anyone help with that.
[Samsung Galaxy Nexus] SeniorMoment69:
I want to try and upgrade my Nexus to a newer version, currently on 4.2.2. I have overcome the device offline issue. When I try to run the backup, it seems to go through the motions. I get the prompt on the phone and enter the password setup on the phone for backing up. The backup starts but then almost immediately finishes. The file is only 1 K in size. I have been reading and gotten though half the posts here. Early on there was a reference to this and how to fix it. Seems like the drivers and all that are working and communicating fine with the phone it just can't read the phone side or maybe it can't write to the PC side. I did notice the following logcat entry when the backup begins:

Could this mean the process is uable to access the system?

I am on Windows 10 Pro... Any suggestions would be greatly appreciated.
[Samsung Galaxy Nexus] SeniorMoment69:
UPDATE: I tried to do the same process on my only Windows 7 Pro laptop I have left. Initially ran into the Device Offline problem first. Remove and installed manually the Universal Drivers then updated to ADB 1.4.1 version I downloaded from a link on page 25 of this thread. Got the laptop to see the device as "DEVICE" not "OFF LINE" after getting the RSA pop up on the phone. Ran the same backup command adb backup -f C:\boot\backup10222016.ab -apk -shared -all -system and got the same result but a little different on the logcat out put. Looks sort of like what I got on my Windows 10 system with a couple exceptions:

Calling a method in the system process without a qualified user:

E/Cryptfs ( 119): not running with encryption, aborting <<<< shows up 3 times

W/BackupManagerService( 378): Unknown package '-apk' '-shared' '-all' '-system', skipping <<<< here is a new one

Full capture listed below. So I am not a programmer but it seems that the process can't access the phone. I have reset the backup password 3 times and tried all 3 possible combinations. I even removed the backup password. Still unable to do a backup...
[Samsung Galaxy Nexus] damnason:
Galaxy S7 6.0.1 ADB error

Hey, I have a problem with this backup. It worked fine with my Galaxy S4 5.0 but it doesn't work anymore with my Galaxy S7 6.0.1. I don't know why, I tried a lot of ADB version but nothing works for me. I need backup my apk files with this ADB. I don't trust Titanium Backup or Helium. Somebody has any idea why it isn't working on my 6.0 android? ADB isn't removed some command works perfectly but I can't save my datas... If I write the command the windows pop up on my device and when I accept it looks that it's works but it create a 0 byte .ab file.:confused::confused:
[Samsung Galaxy Nexus] aquatarkus:
I also found that sometimes this backup doesn't work, and I've used it a lot with various different devices. Last week I had it working fine with one particular phone, and when I ran it again, it didn't work, even using the same command parameters. :-/
[Samsung Galaxy Nexus] magicphone:
I've just found this 5-year old topic of general interest hidden in the Samsung Galaxy Nexus forum (anyone remembers this device?), from StackExchange, though I wouldn't have searched for this information in the Samsung Galaxy Nexus subforum. Boy, I like Android fragmentation so much! :) Is there a device-independent, 2016-version of this method, or any updated version of it?
[Samsung Galaxy Nexus] aquatarkus:
It's completely device independent. I've used it on a number of different Android devices, with KitKat, Lollipop and Marshmallow.
[Samsung Galaxy Nexus] Catpuddipuddi:
i really want to swap my neko atsume-file from my old Xperia J to my new samsum galaxy s3 neo. I´m on the end of my hope to save my cats..

Copy from the neko atsume reddit:

"Adb, adb tools, adb+fastboot... All three are working for me...."working". Well, more or less because i just cant transfer ANYTHING. My terminal says im doing everything right,and both phones react with the requested backup. Sadly, the galaxy s3 neo doesnt give a fox about the stuff after the backup. Nothing happens and im lost after hours and hours.

What i did yet/Facts: -Both games are on 1.8.5

-Both phones had the game already steady before the first try.

-Still nothing after re-downloading the game on the s3neo.

-Xperia is running on ver.4.1.2 Android (if i remember right)

-S3Neo 4.4.2

-The terminal is running on Windows 8.1 (64)

-Full backup of phone xperia ->s3 reacts-> does not care at all after doing the backup.

-file alone->does not care at all after the backup...

-the full game+ file with C:\ path-> does not fking care. GG.

-file alone with the C:\path->you know it :P

-im not writing " ´jp.co.hit_point.nekoatsume´ " because the terminal doesnt accept these small lil things,dont ask me why.

-instead im writing (depents on the command) " jp.co.hit_point.nekoatsume.ab "

-used both -apk and -noapk

-told google my problem...google laughed back. everybody has the GAMEproblem,but not the phonetrouble like me.

-Started the game with a new saveslot and did the same few things again

-restarted my s3 before and after the new savefile

-meh."
[Samsung Galaxy Nexus] AndroidDeveloperLB:
Is it possible to launch the "backup" and "restore" commands from within the Android device itself, without PC (root granted if needed) ?
[Samsung Galaxy Nexus] fvisagie:
That doesn't work for 2 reasons. One is that backup/restore access the PC via USB for backup storage, and the other because the commands aren't implemented Android-side, AFAIK at least ;).
[Samsung Galaxy Nexus] AndroidDeveloperLB:
Well, the backup-file can be stored in the external storage, and couldn't I move the needed command files of Linux (adb in this case), into Android, and run them?
[Samsung Galaxy Nexus] fvisagie:
You could, conceivably, but you would also need to emulate or modify the USB adb client-server interface as I see it.
[Samsung Galaxy Nexus] AndroidDeveloperLB:
Is it possible to run it using a rooted device, maybe?

What about non-rooted device?
[Samsung Galaxy Nexus] fvisagie:
I'm no developer, but I guess that since the adb daemon doesn't require root privileges, you wouldn't need a rooted device to run the client.

However, unless you manage to connect your Android adb client to the daemon via IP (which I'm not sure is possible), the issue of the USB interface will remain.
[Samsung Galaxy Nexus] Micha_Btz:
when i created a backup is there a possibility to look into the file what is really included?

maybe mount with loopack or something similar?
[Samsung Galaxy Nexus] fvisagie:
You can try something like Android Backup Extractor.
[Samsung Galaxy Nexus] AndroidDeveloperLB:
Thing is that I don't think I can just copy the adb file to the device and run it. It's for PCs...

I wonder how various backup apps do the backup though.

Anyway, thanks.
[Samsung Galaxy Nexus] fvisagie:
Yes, but only for apps that implement the Android backup API. Many don't and generally it's impossible to tell what the situation is before trying a backup.

That's why using adb backup is a hit-and-miss affair.
[Samsung Galaxy Nexus] carpboy:
Single App Restore Failing

I am having a problem with adb restore.

I can make an .ab file with a single app in it, I also tried making one with -all, it was quite large.

So I have an S3 with 4.4.4 on it, new S7 with 7.0.1. I make a test .ab file of a single app to see how all this works and if the data does really come across.

When I do adb restore, I get the dialog on the phone, but it is for 'full backup', nothing about restore. I put in the password that was used for making the backup, I get 'restore started' and after a little the complete message. The command prompt in my adb window only reappears when this processes is done. If I put in bogus passwords, the process ends immediately.

By all indications this is working. There is a slight matter of there being no app present when done.

Any idea what could be going on here? I can't root this phone yet, not unlockable, I need to restore basic apps and data. Helium doesn't work - it doesn't create the apk depite being told to, and when I install the apk by hand on the new phone the Helium restore freezes.

God, I really really appreciate TiBU now.....
[Samsung Galaxy Nexus] springtownpete:
Empty backup file created.

I am trying to backup a Samsung S3Mini running Android Version 4.4.2 I used the following syntax: adb backup -apk -shared -all -f c:\xmit\backup.ab I was prompted for my developer password. After entering it I got a backup started followed immediately by a backup finished message. The file was created - but only contained 549bytes. My phone itself does not have a password. Can that be an issue?
[Samsung Galaxy Nexus] Fields46391:
HI I just had a quick question...

So I just finished the back up and the file size is 1GB when theres close to 8GB of data on my phone is that ok? I just didn't know if you successfully complete a full back up if the sizes would match or not.

heres the command I used

adb backup -apk -shared -all -f C:\lgbackup.ab
[Samsung Galaxy Nexus] arcma:
you can try to add: -obb

because default: -noobb
[Samsung Galaxy Nexus] Fields46391:
and can you tell me exactly what obb is I mean I looked into it and understand its data which is closed source binary code that only applications with permissions recognize If I understood correctly but Do you need it when creating a back up.
[Samsung Galaxy Nexus] iamsp:
HOT TO GET PHYSICAL BACKUP (.raw extension) without rooting ?

Hi,

As a part of my academic assignment, I am supposed to perform forensic investigation on a Chuwi Vi7 Phablet. I want to get a physical backup (in .raw extension) of the device. How can I do it without rooting the device?

And if rooting is required, then how can I root the device? KingoRoot application is not working in this device.

Please help. Thanks
[Samsung Galaxy Nexus] PIRATA!:
I'm sorry...but why do you use the command -all with -apk & -shared combined together?

-all isn't it enough for everything??

Second thing, about the -obb command: is it for example for the games system files stored in sdcard/Android/obb ??

And is it necessary? Doesn't the -shared do such stuff??

And if it should be used, will the command line be something like this??

adb backup -apk -shared -obb -all -f C:\backupname.ab

Thank you.

Sent using Tapatalk
[Samsung Galaxy Nexus] Dude+:
EDIT: ha, all it needed was double quotes, adb backup "-apk -shared -all -f C:\backup0603201700.ab"

Is being rooted my issue on a N4 running 7.1.2 ? The bootloader was unlocked and screen lock was removed. The phone just sat there with the home screen unchanged.

adb backup -apk -shared -all -f C:\backup0603201700.ab

Now unlock your device and confirm the backup operation.
[Samsung Galaxy Nexus] kr428:
Folks, sorry if this is old, but: I did a full adb backup of all apps on one of my devices and want to restore just a single app out of this right now. Is this somehow possible?
[Samsung Galaxy Nexus] GCalzo:
Give a look here: Android Backup Extractor https://sourceforge.net/projects/adbextractor/
[Samsung Galaxy Nexus] kr428:
Yeah, stumbled across this too in the meantime. Powerful, I wasn't aware this is even possible without being root. ;)

Thanks for your comment nevertheless, greatly appreciated!

Cheers,

Kristian
[Samsung Galaxy Nexus] BigZ1:
Trying to do restore to Galaxy Tab E, but instead of getting the device to approve restore, it shows backup instead. When I do adb devices, it shows what looks like a MAC address and then "unauthorized". Is this why it won't restore, and if so, what does it take to get the device to be authorized? Could it be that I reset the Galaxy to factory settings and then turned on KNOX? Any suggestions welcome.

Thanks!
[Samsung Galaxy Nexus] Rilyuu:
nice guide

So nice guide for adb backup.

I've less question is it fit for no AOSP rom? like MIUI etc..?
[Samsung Galaxy Nexus] GCalzo:
I guess that you have to let it start, enable debug mode and then accept the adb debug connection form the pc.

I've learnt the hard way that adb restore is not for a disaster recovery or after a factory reset...
[Samsung Galaxy Nexus] Messerschmitt262:
I tried this hoping it will allow me to fully backup my phone, INCLUDING the current firmware I have (in case I upgrade the firmware and wish to restore). So if I have android 6, upgrade to 7, don't like it, I can then restore it and get 6 back. But my backup file is only 80mb. This obviously does not include the firmware.

What can I do to do a FULL backup, including the firmware operating system?

Thank you
[Samsung Galaxy Nexus] GCalzo:
Better ask directly into your phone's section!

BTW: adb can backup "user data" only, for that you need a rooted phone and TWRP or Titanium Backup
[Samsung Galaxy Nexus] Messerschmitt262:
Even just for data, can the backup be restored without bootloader unlocked?
[Samsung Galaxy Nexus] GCalzo:
So far I was always able to restore what I have saved, only the "Google" part (or call it system configuration) is hard to recover.

BTW: when doing full backup one can restore just one app using a tool that will split the full backup! https://sourceforge.net/projects/adbextractor/
[Samsung Galaxy Nexus] Messerschmitt262:
Oh ok, so then I don't require to have the bootloader unlocked on the phone to restore correct? OP mentions bootloader must be unlocked.
[Samsung Galaxy Nexus] GCalzo:
... because this specific thread is about restoring your data after having unlocked! And unlocking bootloader means that the phone will be wiped!!

But search better and you'll find at least another thread or two about using adb for backup & restore without unlocking! :good:
[Samsung Galaxy Nexus] Oops...:
Sorry for not searching the thread, but you said, it would not restore after a factory reset? This would render the whole backup useless? Please let me know. Thanks
[Samsung Galaxy Nexus] GCalzo:
It will restore, but only the saved data/apps (not every apps lets you backup them via ADB) and the "system" part will not be (entirely?) restored because after a factory reset you have a new deviceID.

IMHO, ADB backup are useful for restoring single or multiple data/app that you have uninstalled (again, if included into the backup), not for restoring a phone after a factory reset.
[Samsung Galaxy Nexus] proza:
Will it also backup the obb files?
[Samsung Galaxy Nexus] DarkSJ1998:
Works partially for me...I'm able to backup app data only. Adding the -apk or -shared flag doesn't let me backup on my merlin device. So used TiBkp to restore data after installing the apps manually from Play Store and it works! :D But TiBkp is able to restore data only from ADB Backup. But that's sufficient ;) Kudos to the ones who implemented this feature in Android itself :highfive: and also to TiBkp devs!

Backed up via ADB, unlocked my device, flashed LaOS 14.1, installing apps from Play Store and restoring app data via TiBkp using that ADB Backup now :cool:
[Samsung Galaxy Nexus] SkyLey:
I'm still getting the 0 kb backup issue... I don't know what I am doing wrong.

My PC recognizes my phone and I write the command

but nothing. It just starts and ends immediately with a 0 kb archive...

I only want to backup my data :( why is it this hard...
[Samsung Galaxy Nexus] DarkSJ1998:
Try this :-

adb backup -all com.stainlessgames.D15
[Samsung Galaxy Nexus] SkyLey:
Tried it and started doing a full backup instead.

Well, not even that. It did not even complete it. It stopped at 18 MB.

What the hell is going on?...
[Samsung Galaxy Nexus] DarkSJ1998:
Ohh sorry my bad. You want to backup all your data right? That command would back-up only the data of that particular package name that you wrote in CMD.

For backing up all data, just do a

adb backup -all
[Samsung Galaxy Nexus] SkyLey:
no no, you were right. I only want to backup my com.stainlessgames.D15 data so I can transfer it to my new phone (also via adb).

but no matter what I do I always end with the same result... 0 kb file. I even tried with the pull command but it always gives me the same 0 files pulled message.

I can make a video so you can see it if that helps you in any way :confused:
[Samsung Galaxy Nexus] DarkSJ1998:
Do this:-

adb backup com.stainlessgames.D15 -f backup.ab

And, DO set an encryption password on that back-up. Sometimes it doesn't work if you don't set a password. And for me, -apk & -shared don't work & then I get a 0KB file
[Samsung Galaxy Nexus] SkyLey:
STILL nothing. Even with or without password...

:crying: