TWRP ADB Backup file - Android Q&A, Help & Troubleshooting

I created a TWRP backup which was 17.1 GB in size, I've restored the file whenever the need arised but today when attempting to restore nothing would happen.
I have just realised the file has gone from 17.1 GB to 0 bytes it looks like the file has become corrupt or somehow it has been overwritten with a blank backup.ab is it possible to recover my file?
My OS is Windows 10 and would really appreciate any help if possible.

@AndroidOmenon
Windows 10 automatically creates backups of your files that allows you to jump back to older file versions, of course only if this option is not disabled.

@jwoegerbauer
Many thanks for your reply, I checked my computer for any available backups unfortunately I don't have any. The backup option was set to disabled.
Before you replied to my post I decided to try data recovery software, the file is found and shows as 17.1 GB but when recovered its only 518 bytes if I remember correctly.
I am hoping it will still be possible to recover the file someone may still be able to help me.

Related

Restore file fails checksum verification...

I recently tried a new ROM and made a Rom Manager recovery restore file prior to changing. Things didn't work out as well as I had hoped and when attempting to restore, it fails at the checking MD5 sum process.
Any way to work around this? I really would like to restore to the previous ROM without starting over.
Anybody? I am not quite sure how the restore file can be created on this phone and then not pass verification?
Any ideas or am I stuck starting over?
sandiegopaneraiguy said:
Anybody? I am not quite sure how the restore file can be created on this phone and then not pass verification?
Any ideas or am I stuck starting over?
Click to expand...
Click to collapse
depending on the type of file format used to backup, the restoring could be done manually but a changed md5sum generally means the files are not the same as the original. this could result in corruption and generally it isnt recommended to restore corrupted files as you run the risk of nothing working.
if you're still wanting to proceeding with attempting to restore files which are different than the original and could be corrupted, off the top of my head, you can probably dd the .img files back and untar the .tar files back.
i would suggest starting over and perhaps copying the backup files over to your desktop instead of only leaving on the sdard. this should help ensure at least one of the copies maintains their integrity.
hope that helps!
You can boot into recovery, and run nandroid via adb shell command line, no md5 checksum file needed. Now if the image is bad, you of course get bad results, but if the checksum is just hosed for some reason, it will work fine.
Put the .win files for the partitions you want to restore in /sdacrd
then issue the command "tar xvpf /sdcard/data.win" or "tar xvpf /sdcard/system.win" from the adb shell while in /data or /system respectively. .win files are what TWRP creates for backups.
I had this happen with TWRP 1.01 or 1.02 once on a good backup that passed the checksum tests when I backed it up.
I was testing the reliability of the TWRP package's nandroid and first one failed.
Once I moved to the newer version, I've not had that issue.

[Q] Problems With Large (>10,000 Files) data.img Backup. I Can't Get My Data Out!

Hi guys,
I'm at my wit's end with this one.
I have a 1.2GB data.img file created with Clockworkmod Recovery backup. I believe it was one of the older versions, in the 3.x.x.x range. When this was created I had plenty of space available on the SD and the MD5 was created successfully.
I have had no luck restoring this with any version of CWM. Restoring simply results in a system that won't boot; I am presented with either a black screen or a boot-loop. I have since learned that this is because my backup has too many files. Apparently CWM is hard-coded to restore a maximum of 10,000 files and will not restore anything past that point. I found a thread where someone had edited the source code to increase this limit to 50,000, compiled and flashed it, then successfully restored their backup. Aside from the initial editing, I would not know where to start to do this for my phone (SGS2)
Furthermore, I cannot extract the contents with unyaffs.exe for Windows. When I try to do this, it extracts a small portion of files (around 170MB), then exits with the following report :
Code:
read image file
: Bad file descriptor
read image file
: Bad file descriptor
I have since learnt that this is due to NTFS limitations with the length of pathnames. 'No problem' I think, and decide to install Ubuntu 11.10 so that I can use the linux version of unyaffs to extract the full thing without these limitations.
After a bit of messing around, I successfully compile the unyaffs source (I'm no expert in these matters). I then attempt to extract data.img and after a short while processing I get another error! :
Code:
Segmentation fault
Out of interest, I checked how much data had been extracted and got 9,544 items, totalling 204.2 MB. So I'm roughly 1 GB down.
Please help, you might not believe the hours I've spent to get to this stage and I still can't get all of my data back. I need my contacts (Google didn't back them up apparently), messages, app data and anything else I can get my hands on. If there's a better utility I can use for extracting, or perhaps a modified version of CWM I can flash onto my SGS2 so that I can restore the backup properly, I'm all ears.
Look forward to any responses and thanks in advance.
Just to update, I have now tried ext2explore on Windows 7, as well as yaffs2 explorer on Android. Both will open the .img file but display a blank window.

VZW XT912 Safestrap Error Restoring /data, Backup File Over 2 GB

Hi folks,
The adventures continue. I've been trying to restore my Safestrap backup for ages, and no matter what I try, I continue to get
Code:
Error restoring /data!
at the conclusion of the restoration. I can restore via Fastboot to stock, but no matter what I can't get my full backup restored successfully. Generally unless I restore to stock factory the system ends up in a kind of broken state where there are apps that are installed but have file size 0B, and don't run.
The final error in the recovery log is
Code:
tar: seek failure: Value too large for defined data type
Error while restoring /data!
Of course the first thing I thought was that the backup was corrupt, but it extracts completely fine with plain ole' tar on my Linux laptop.
I have:
Updated Safestrap to 2.11 for Droid Razr
Updated BusyBox via Stericson's BusyBox updater app from Google Play
Attempted restore again after those two steps
Wiped /data and restored to Factory via both Fastboot flash through Matt's Utility and Motorola Recovery menu
Attempted to split the data.ext3.tar file into two, one with my apps directory, one without (since that way, both files are below 2 GB). The first file, the one with the apps directory removed, restored fine. The second one, consisting of just the apps directory, did not (with the same error). It might be a moot point anyway since I think Safestrap formats the partitions before restoring, so it wouldn't "recombine" them anyway.
Bought the XDADevelopers Android Hackers' Toolkit from the bookstore. Haven't finished reading it yet, but hopefully it will give me some ideas.
So I can get access to what my apps directory should look like (I can extract it locally here on my laptop) but I can't get Safestrap to extract it all at once to the correct partition on my phone.
I'm currently almost out of ideas. It seems this is a common problem and that newer versions of CWM Recovery split the tars so to avoid the file size limit imposed by BusyBox, if I'm interpreting what I've read correctly. This might be the case with the newer Safestrap but it doesn't help my old backup, unless I can split it in a way that Safestrap expects and will deal with (is this possible?)
Given that I have the actual files that should be on the phone, and that my phone is rooted, would it make sense to simply attempt to extract the apps-only tar overtop of the apps directory? Would the files be locked when the phone was on normally?
Could this still be a free space issue? Currently I'm showing 1.7 GB free after the latest failed restore. One would think if it was a disk space issue, it would show 0 B free, right? To test this, would it hurt to delete the files in the safestrap directory (i.e. orig and safe, containing a data.ext3.tar in each of about 2.2 GB) since Safestrap is currently in unsafe mode right now anyway?
Also, is there anything I can do to help here? I know C and C++; while I'm not a low-level hardware hacker by any means (I'm a professional web developer) this issue has bugged me enough that I want to try to fix it. I know that Safestrap is on Github but I'm not really sure where to start.
Do you have any other suggestions for ways to get my Safestrap-generated nandroid backup of my data correctly restored to my phone?
Please let me know if I did something wrong in asking this question; I tried to do as much research as I could beforehand. If I haven't done enough, I would appreciate a point in the right direction.
Or maybe the post was too long and drawn out, so I'll try to compact it here.
My phone won't restore a successful Safestrap backup that is 2.2 GB in size. The backup (a tar file) extracts fine on my PC. I'm getting "error restoring /data!". It seems to be the same issue others have had with restoring a CWM backup over 2 GB.
Would it make sense to simply attempt to extract the apps-only tar overtop of the apps directory, or would the files be locked when the phone was on normally?
Could this still be a free space issue?
Do you have any other suggestions for ways to get my Safestrap-generated nandroid backup of my data correctly restored to my phone?
Edit: Could the tar be converted to an image file to be flashed to the data partition with Fastboot?
Final bump. Anyone? Anyone? Bueler?
Is it safe to just grab a root shell through ADB, push the tar containing the apps, and extract over top of my phone's existing apps directory, while the phone is running? Are there risks associated with this?
Edit: Alternatively, is there a native Android GNU tar binary available anywhere, or instructions for cross-compiling one, since this seems to be a problem with BusyBox?
...Answering my own question, apparently yes. I'm going to try replacing the tar symlink to BusyBox with this native version and try again tonight, I'll let you know how it goes.
I had the same problem and the tar from your link worked for me for a 4GB tar extract. Thanks for your tip!

[Q] Can't extract NANDROID backup

I apologize if this question has been asked before; I have done some digging through the forums but I have been unable to find a complete solution/explanation for this problem. Essentially, I cannot copy NANDROID backups created through twrp recovery to my computer. I am using an HTC one AT&T version and a win7 computer. Obviously I have no sd card so I need to copy the backups from the internal storage. I find the backup folder just fine along with the backups I want (upwards of 3gb in size). However, when I try to copy them via USB or network transfer through an android file browser on the phone, only a few mb of files are copied, and no errors are generated. Other forum posts indicate that a simple copy and paste should work. While others indicate some sort of vague copy permissions setting preventing this action. The only solution that I've not tried is using "adb pull". I have no idea how to do that as I have zero experience playing with adb. Before digging into that and trying to figure out how to set up adb and find the relevant commands to do what I want, I would like to know if there is a simpler method of accomplishing copying my NANDROID backups. Any help would be appreciated, sorry if this is a noob question.

TWRP recovery problem

Hope this is in the right place ..
I have a couple of Tanix TX3 mini TV boxes that I would like be able to backup and recover across devices.
I have put S905-TWRP3-VIT.zip onto a micro SD card and can load TWRP from the boot recovery menu.
I can then backup ROM, system and data partitions to a USB flash drive.
if I now go into the restore menu I can see the backup file.
My problem is that if I now start TWRP from a different device I can no longer see the backup file.
If I create a very small backup, I can see the new backup but not the old one.
If I reboot normally, I can see both backup files within the same directory via any file explorer app.
Obviously, this stops me from being able to restore the system to the target device.
I can't see anything obviously wrong, can someone tell me where I am going wrong please?
Many thanks
Baldplumber said:
Hope this is in the right place ..
I have a couple of Tanix TX3 mini TV boxes that I would like be able to backup and recover across devices.
I have put S905-TWRP3-VIT.zip onto a micro SD card and can load TWRP from the boot recovery menu.
I can then backup ROM, system and data partitions to a USB flash drive.
if I now go into the restore menu I can see the backup file.
My problem is that if I now start TWRP from a different device I can no longer see the backup file.
If I create a very small backup, I can see the new backup but not the old one.
If I reboot normally, I can see both backup files within the same directory via any file explorer app.
Obviously, this stops me from being able to restore the system to the target device.
I can't see anything obviously wrong, can someone tell me where I am going wrong please?
Many thanks
Click to expand...
Click to collapse
Solved

Categories

Resources