[Q] Data recovery with adb after soft-brick - Moto G Q&A, Help & Troubleshooting

Hello,
I installed the latest cyanogenmod nightly. There were issues with the google play store so I had to switch back to a cyanogenmod 11 nightly from december. Unfortunately there was a problem with CWM and based on the information on the forums I flashed the old nightly manually in CWM. Unfortunately, my phone became stuck in a bootloop. I was not thinking clearly so I did not make a backup at the right time. I am trying to recover some data. I have first done a backup within CWM, it has apparently created a backup file in the /sdcard/. I then used "adb pull /sdcard/" to copy the contents of the /sdcard/ to a safe location on my PC. It seems to have worked but I am not sure. I do not know in which folders the data is actually stored.
(I don't know if reflashing the most recent nightly will work)
I was wondering if this solution will work, and if I will be able to keep the app data this way as well as retrieve a few pictures. Ideally I hope this will allow me to put the phone back to its original state at some point. I hear a factory reset deletes the contents of the internal sdcard on the moto g so that is why I am trying to copy it back to PC. But I wonder if I will be able to restore it afterwards. Any adivce would be greatly appreciated.
edit: uh oh seems adb pull sdcard has not completed successfully so I am at a loss at what to do

Is there an option in CWM or TWRP to mount partitions for access by a PC?

audit13 said:
Is there an option in CWM or TWRP to mount partitions for access by a PC?
Click to expand...
Click to collapse
Thanks for your help. I'm sorry I couldn't get back to you earlier. Thankfully I have been able to solve the problem by reflashing the cm12 nightly, retrieving the data from that, and then wiping the phone and reflashing an old snapshot. Now I will be careful with backing up my data in the future.
I don't understand why the cm12 don't work though. I get weird scan lines on everything, including the boot screen. I think it may be due to the google apps because they keep quitting. I will try something else.
edit: I will post this issue in a separate thread

Related

[Q] PLEASE Help

Hello everyone, for starters im a complete newb at rooting phones and have never before tonight so please excuse my ignorance. I just rooted my phone which went fine, downloaded titanium backup and backed up everything, and then moved a zip of m1 cm10 and gapps onto my ext sd card. then i followed a video on how to install these. i was running clockwork recovery and did a factory reset/clear. in the video, the next screen had an option for "choose zip from sd", all mine had was something like update from external so i clicked that and it brought up my sd card files, including the cm10 and gapps files. i clicked on them (i tried each more than once) and they both stgarted to install then said failed. Im literally here freaking out because none of the apps i downloaded to restore my stuff are on my phone anymore, and when i downloaded them from the play store they said i had not backed anything up. somebody please help me, im legitimately having a nervous breakdown because i lost everything and dont know what to do.
Ok first things first. What was the fail error that CWM produced? I dont understand what you mean by none of the apps you downloaded to restore your stuff are on the phone anymore. Where did they go? If you didnt delete them they should still be there. Did you boot up after the failed attempt, and are now at a factory state OS? Perhaps titanium isnt pointed to the correct location of the backups you made. Please provide more info.
Edit: Ok I misunderstood a point. The apps I take it are gone from the factory reset, but I still dont understand why the backup data cant be restored.
Sounds like CWM didn't flash. That sounds like stock recovery. Flash factory image via Odin, reroot, and reinstall CWM. Download an app called EZ Recovery from the market and follow the instructions. You will be fine.
Sent from my SCH-I535 using xda premium
Just a side note as far as using CWM goes:
I've noticed that with CWM, the backup file sizes are way too small. Hence a possible corrupted backup folder. TWRP seems to work better with our device as far as backups go.
It's always a good idea to check the size of a backup afterwards before proceeding with any risky procedures like low level flashing. Luckily there is always ODIN.
With my device backup sizes range between 2.0GB and 2.34GB.
tekrhino said:
Just a side note as far as using CWM goes:
I've noticed that with CWM, the backup file sizes are way too small. Hence a possible corrupted backup folder. TWRP seems to work better with our device as far as backups go.
It's always a good idea to check the size of a backup afterwards before proceeding with any risky procedures like low level flashing. Luckily there is always ODIN.
With my device backup sizes range between 2.0GB and 2.34GB.
Click to expand...
Click to collapse
You've got to remember that CWM backs up differently now. It backs up data separately in blobs in a different folder. So your backups in clockwork are naturally smaller. Also, I've heard nothing but bad things with TWRP on this device. I'd stay away from it and stick with non touch CWM.
mustbepbs said:
You've got to remember that CWM backs up differently now. It backs up data separately in blobs in a different folder. So your backups in clockwork are naturally smaller. Also, I've heard nothing but bad things with TWRP on this device. I'd stay away from it and stick with non touch CWM.
Click to expand...
Click to collapse
This!
apacseven said:
Ok first things first. What was the fail error that CWM produced? I dont understand what you mean by none of the apps you downloaded to restore your stuff are on the phone anymore. Where did they go? If you didnt delete them they should still be there. Did you boot up after the failed attempt, and are now at a factory state OS? Perhaps titanium isnt pointed to the correct location of the backups you made. Please provide more info.
Edit: Ok I misunderstood a point. The apps I take it are gone from the factory reset, but I still dont understand why the backup data cant be restored.
Click to expand...
Click to collapse
When I open titanium backup and try to restore, it tells me no backups have been performed. Before trying to flash cm10, I moved the backup to my external sdcard and it is still there, yet I still can't restore it and when I try to do something with the files on my card it says no application can perform this task. Ive gotten my contacts back through tha app I backed them up on so I'm at a loss for why tb Isnt working.
levibernhardt said:
When I open titanium backup and try to restore, it tells me no backups have been performed. Before trying to flash cm10, I moved the backup to my external sdcard and it is still there, yet I still can't restore it and when I try to do something with the files on my card it says no application can perform this task. Ive gotten my contacts back through tha app I backed them up on so I'm at a loss for why tb Isnt working.
Click to expand...
Click to collapse
Launch titanium and hit menu/preferences. From there you can change the backup location to wherever you moved it to and it should see them.
Also for your contacts... If you are planning on flashing roms do yourself a favor a migrate your contacts off your phone and on to Google. That way you just log back in to your Google account after a re flash and they are all resynced. Plus you can access them from anywhere at contacts.Google.com
Sent from here using this
Relentless D said:
Launch titanium and hit menu/preferences. From there you can change the backup location to wherever you moved it to and it should see them.
Also for your contacts... If you are planning on flashing roms do yourself a favor a migrate your contacts off your phone and on to Google. That way you just log back in to your Google account after a re flash and they are all resynced. Plus you can access them from anywhere at contacts.Google.com
Sent from here using this
Click to expand...
Click to collapse
Did this ^ in titanium and the files show up, but it still says there is nothing to restore.
Also, could someone tell me/point me to a good method of flashing M1 cm10 onto a us cellular gs3?
mustbepbs said:
You've got to remember that CWM backs up differently now. It backs up data separately in blobs in a different folder. So your backups in clockwork are naturally smaller. Also, I've heard nothing but bad things with TWRP on this device. I'd stay away from it and stick with non touch CWM.
Click to expand...
Click to collapse
I agree 100%, the non-touch version of CWM works perfectly. I could care less about touch/non-touch/color of the app etc. ALL I care about is the capability to do a sucessful restore & CWM has never failed me for that.
I did a restore from it last night & it worked perfectly. The ONLY thing I have ever had to do after a CWM restore is clear data in GMAIL to get it to send.

[Resolved] [HELP] [TWRP] Unable to find "Format data" button

Hi guys,
First : thanks a lot for all your help on this forum.
I'm trying to install a custom ROM on my new LG G6 H870 phone using TWRP 3.1 and i'm facing an issue : I can't find the "Format Data" button in the Wipe menu. I need that button to remove the "Encryption Unsuccessful" screen after flashing.
What did I missed ? Can't see any thread talking about this....
Is the option "Repair or Change File System" / "Change File System" / "Ext4" doing exactly the same ? It does not remove the "Encryption Unsuccessful" screen...
Should I try to reinstall TWRP ?
Thanks a lot for your help.
Ok, the twrp image I used seems to be broken... I downloaded it again from the official webiste, now everything works.
I re-flashed twrp using fastboost, everything worked well. I have now the Format data button...
Thanks
Format data button
Hello,
Could you please help me to understand the real function of Format data button in Wipe section ?
Cause I saw in a thread that it is needed to root android phone but does-it also delete all data in the phone (pictures videos etc...) ? And if so, is it possible to recover these files after formatting ?
Thank you !
infostar said:
Hello,
Could you please help me to understand the real function of Format data button in Wipe section ?
Cause I saw in a thread that it is needed to root android phone but does-it also delete all data in the phone (pictures videos etc...) ? And if so, is it possible to recover these files after formatting ?
Thank you !
Click to expand...
Click to collapse
Yes, everything that you have stored on the device will be removed during the format.
Can it be recovered after? Maybe, maybe not, typically, if just deleted, it can be mostly recovered fairly easily, but when formatting instead of deleting, it is usually difficult to recover anything, if anything can even be recovered at all.
When stored information is simply deleted, it can be recovered because it isn't actually gone, it is still there, it is just "tagged" to be ignored by the system as if it isn't there, then, the next time the device needs to write new data, it overwrites the "tagged" data. When you "recover" deleted data, you are basically just removing the "tag" so that the "deleted" data is no longer marked to be ignored/overwritten.
But, when you format, it does not delete the data(it is not "tagged"), it is removed and then overwritten to make the space "blank".
Sent from my SM-S767VL using Tapatalk
Droidriven said:
Yes, everything that you have stored on the device will be removed during the format.
Can it be recovered after? Maybe, maybe not, typically, if just deleted, it can be mostly recovered fairly easily, but when formatting instead of deleting, it is usually difficult to recover anything, if anything can even be recovered at all.
When stored information is simply deleted, it can be recovered because it isn't actually gone, it is still there, it is just "tagged" to be ignored by the system as if it isn't there, then, the next time the device needs to write new data, it overwrites the "tagged" data. When you "recover" deleted data, you are basically just removing the "tag" so that the "deleted" data is no longer marked to be ignored/overwritten.
But, when you format, it does not delete the data(it is not "tagged"), it is removed and then overwritten to make the space "blank".
Sent from my SM-S767VL using Tapatalk
Click to expand...
Click to collapse
Thanks a lot for the details, I will try my best to restore my phone after this because it bootlooped yesterday ...... So, I'm thinking of getting an image of the system with ADB sideload on recovery mode before flashing the original firmware....
Is it a bad idea ?
infostar said:
Thanks a lot for the details, I will try my best to restore my phone after this because it bootlooped yesterday ...... So, I'm thinking of getting an image of the system with ADB sideload on recovery mode before flashing the original firmware....
Is it a bad idea ?
Click to expand...
Click to collapse
You don't necessarily need to pull a system.img, backing up your data via adb then restoring the data after getting the bootloop fixed, should work.
If you can get adb to connect with the device properly, then, yes, I would pull an adb backup of your apps, data and personal settings. Then wipe or reflash the device then restore the apps, data and settings from the adb backup. Are you familiar with adb backup?
Sent from my SM-S767VL using Tapatalk
Droidriven said:
You don't necessarily need to pull a system.img, backing up your data via adb then restoring the data after getting the bootloop fixed, should work.
If you can get adb to connect with the device properly, then, yes, I would pull an adb backup of your apps, data and personal settings. Then wipe or reflash the device then restore the apps, data and settings from the adb backup. Are you familiar with adb backup?
Sent from my SM-S767VL using Tapatalk
Click to expand...
Click to collapse
No, I'm not familiar with it but I read a lot of XDA threads and I will give it a shot. ISo, I'll try an ADB backup. If it's not working, it won't big a big deal, I will reflash it to have my phone back.
Thanks

Can't restore TWRP back up

I'm getting "extractTarFork( ) process ended with ERROR: 255" whenever I try to restore the back up. I'm able to successfully restore system and boot without any issues, so it seems to be something to do with the data section.
I recently upgraded my TWRP to the latest so I tried to downgrade back to the previous version but it still doesn't let me restore it.
From googling, I've seen posts suggesting that people have been deleting a line by finding it in their log, but I'm unable to find the log nor do I understand how to edit it to try and solve the issue.
Any help would be appreciated
I had this problem and it took me two days to resolve it. I had a good backup and I know it was good because I had used it several times and it worked. But then after doing some system installs I got the error 255 when I tried to restore it. I tried several things to fix it and nothing worked and I really did not want to lose my backup. What did work for me was to use TWRP wipe function to FORMAT the phone. Wiping or factory reset did not work. I lost the contents of my internal SD card but I was able to transfer most to my external SD card. You could also connect the phone with a cable to a computer and use the pull command in ADB to backup the contents f the internal SD card. Given the choice between losing the SD card and the data files I come to lose some of the SD card. Anyway, a FORMAT worked when nothing else did. I read that this error is caused by a lack of space. When I checked the log it seemed that the restore was failing with a particular file which misled me to thinking I had to remove the corrupt file, but since after the format I was able to restore without any problem, it would seem that there was no corrupt data. Hope this helps someone.
sir..please help me.. I have a twrp backup of system image vendor image data boot recovery persist but im unable to recover because it shows an error extract tar fork process ended up with error 255
i also have a backup of my internal storage in twrp but im not able to restore because of this error

TWRP restore failed, wierd folder names, can't access my files after a clean flash

Hey Guys!
I'm kind of a noob, so sorry in advance!
Today I wanted to try out the new Q Beta, so I opted in, but before that I made sure to create a TWRP backup, so that I could roll back easily if needed.
Well, after like 30 minutes I realized, that some of my apps won't work properly when using this Q preview. So I went back to TWRP, did a factory reset, then I tried to restore my backup from there. It worked without a problem, but during the boot process it showed me an error like:"AuthFailed..." or something. After that, rebooting back to TWRP I couldn't see my normal folders and stuff. I managed to sideload the latest Pie OTA, it works, but still can't access my internal storage and I only see the wierd folders with scrambled letters and numbers.
I know, that there are multiple mistakes I've made doing this and I should have removed my password... Is there any way to get my stuff back and/or restore that backup? Every available box was checked when creating the backup, I copied it to my PC beforehand, I assume it doesn't contain my pictures etc.
Any suggestion is welcome! Thanks in advance!
hsoma94 said:
Hey Guys!
I'm kind of a noob, so sorry in advance!
Today I wanted to try out the new Q Beta, so I opted in, but before that I made sure to create a TWRP backup, so that I could roll back easily if needed.
Well, after like 30 minutes I realized, that some of my apps won't work properly when using this Q preview. So I went back to TWRP, did a factory reset, then I tried to restore my backup from there. It worked without a problem, but during the boot process it showed me an error like:"AuthFailed..." or something. After that, rebooting back to TWRP I couldn't see my normal folders and stuff. I managed to sideload the latest Pie OTA, it works, but still can't access my internal storage and I only see the wierd folders with scrambled letters and numbers.
I know, that there are multiple mistakes I've made doing this and I should have removed my password... Is there any way to get my stuff back and/or restore that backup? Every available box was checked when creating the backup, I copied it to my PC beforehand, I assume it doesn't contain my pictures etc.
Any suggestion is welcome! Thanks in advance!
Click to expand...
Click to collapse
The weird folders mean the data is encrypted. As long as the data is safely backed up on your PC you can format the data partition and boot the phone completely once and then go back to TWRP and copy the backup back to your phone and restore it.

Stuck in recovery after rom update

Hello,
I just updated the rom Evolution X 11 on my Xiaomi Mi 9T Pro after using an older version for about half a year.
Now my phone does not boot anymore, its stuck in recovery (TWRP). Also all data seems to be encrypted and TWRP is not asking for a password.
Is there a way to get my phone to boot again or at least backup my data before I do a full wipe?
You should always do a full twrp backup before messing with roms.
The best solution would be to backup the "Data" and "Internal Storage" partitions. Data contains all apps, their appdata and settings, while internal storage contains all of your own files (photos, videos etc.). After you back these up, wipe your phone (system, data, cache, dalvik) and flash the version of evolution x you were using previously. Now restore data and internal storage and your device should be back to normal.
If you get a bootloop while booting after restoring data and internal storage, then wipe the device again and this time flash evolution x, but only restore internal storage. This way, it should boot and you will be able to recover your files, though your apps will be gone.
If you only restore internal storage then it will no doubt boot up and you will have access to your files, but since you'll have already backed up the important stuff (data + internal storage), you might as well try restoring data as well, as there is no harm, and if the phone boots correctly after restoring both partitions, your phone will be as it was before your updated your rom.
This happened a while back to me with my J5, the issue was that I made a full TWRP backup, then began to test other roms. After I was done, I tried to restore my backup, but it would constantly fail. I sat down for a while, confused and sad about how my TWRP backup had failed me. I tried every solution I could think of, eventually this solution I've mentioned in the above paragraph came to my mind. Thank god for putting it into my mind, otherwise I would've lost a lot of stuff (mainly whatsapp chats which werent backed up, and a lot of apps which I took the time to pain-stakingly configure in the best way for my device).
Anyways, enough of my story, hope this helps you out! If it does, message back here and let us know, and also mark my post as the solution if it was able to help you, so that anyone else who stumbles upon this thread can be saved too!
Cheers!
PhotonIce said:
You should always do a full twrp backup before messing with roms.
The best solution would be to backup the "Data" and "Internal Storage" partitions. Data contains all apps, their appdata and settings, while internal storage contains all of your own files (photos, videos etc.). After you back these up, wipe your phone (system, data, cache, dalvik) and flash the version of evolution x you were using previously. Now restore data and internal storage and your device should be back to normal.
If you get a bootloop while booting after restoring data and internal storage, then wipe the device again and this time flash evolution x, but only restore internal storage. This way, it should boot and you will be able to recover your files, though your apps will be gone.
If you only restore internal storage then it will no doubt boot up and you will have access to your files, but since you'll have already backed up the important stuff (data + internal storage), you might as well try restoring data as well, as there is no harm, and if the phone boots correctly after restoring both partitions, your phone will be as it was before your updated your rom.
This happened a while back to me with my J5, the issue was that I made a full TWRP backup, then began to test other roms. After I was done, I tried to restore my backup, but it would constantly fail. I sat down for a while, confused and sad about how my TWRP backup had failed me. I tried every solution I could think of, eventually this solution I've mentioned in the above paragraph came to my mind. Thank god for putting it into my mind, otherwise I would've lost a lot of stuff (mainly whatsapp chats which werent backed up, and a lot of apps which I took the time to pain-stakingly configure in the best way for my device).
Anyways, enough of my story, hope this helps you out! If it does, message back here and let us know, and also mark my post as the solution if it was able to help you, so that anyone else who stumbles upon this thread can be saved too!
Cheers!
Click to expand...
Click to collapse
Thank you for your help but backing up the data and internal storage doesnt seem possible right now because all the data is encrypted in TWRP...
If you can't backup anything, then wipe system, cache and dalvik, and flash the version of evolutionx you were previously using. Then boot, it should be fine. If it wont boot (give it some time, it will take the time of a fresh install), then this time wipe system+data+cache+dalvik, then flash whichever rom you like and you'll be able to access the files.
You can also try using platform tools and fastboot or adb ( i dont remember exactly which one) to copy the filess from your phone onto your pc.
Sorry if this doesn't apply to your situation, I've never used a phone which has been encrypted, as such I have no experience with them.
PhotonIce said:
If you can't backup anything, then wipe system, cache and dalvik, and flash the version of evolutionx you were previously using. Then boot, it should be fine. If it wont boot (give it some time, it will take the time of a fresh install), then this time wipe system+data+cache+dalvik, then flash whichever rom you like and you'll be able to access the files.
You can also try using platform tools and fastboot or adb ( i dont remember exactly which one) to copy the filess from your phone onto your pc.
Sorry if this doesn't apply to your situation, I've never used a phone which has been encrypted, as such I have no experience with them.
Click to expand...
Click to collapse
That sounds like a good idea. I found the old version on my PC.
Now I just need a way to install it... because twrp cant read the file. I tried with adb sideload but that results in an error for some reason. Flashing Magisk for example with adb sideload is possible.
Edit: Got it to work by using a tool called "Large Address Aware". Now waiting for the results...
PhotonIce said:
If you can't backup anything, then wipe system, cache and dalvik, and flash the version of evolutionx you were previously using. Then boot, it should be fine. If it wont boot (give it some time, it will take the time of a fresh install), then this time wipe system+data+cache+dalvik, then flash whichever rom you like and you'll be able to access the files.
You can also try using platform tools and fastboot or adb ( i dont remember exactly which one) to copy the filess from your phone onto your pc.
Sorry if this doesn't apply to your situation, I've never used a phone which has been encrypted, as such I have no experience with them.
Click to expand...
Click to collapse
This did not help unfortunately... Im still in the same recovery-bootloop and my data is still encrypted.
It's probably still bootlooping as the data partition got modified when you flashed the newer version of evolutionx, and now it will not work with the old one. You can try wiping system+data+cach+dalvik and then flashing any rom of your choice. This will give you access to your internal storage (photos, media etc), but it will remove your apps and their settings. Whatsapp images are stored in the internal storage so you won't need to worry about those.
Again, this is risky, as it may not work (I don't know much about encryption), or you might still not be able to access your files after flashing the new rom. Proceed at your own risk.
PhotonIce said:
It's probably still bootlooping as the data partition got modified when you flashed the newer version of evolutionx, and now it will not work with the old one. You can try wiping system+data+cach+dalvik and then flashing any rom of your choice. This will give you access to your internal storage (photos, media etc), but it will remove your apps and their settings. Whatsapp images are stored in the internal storage so you won't need to worry about those.
Again, this is risky, as it may not work (I don't know much about encryption), or you might still not be able to access your files after flashing the new rom. Proceed at your own risk.
Click to expand...
Click to collapse
Thank you for still helping me out but I already did a full reset yesterday. I did not lose much except for the time setting it all up again.
I still dont really get the point of encrypting all your data if you cant decrypt it even if you know the password...

Categories

Resources