Lost images due to changing the name of its parent folder! - Moto G Q&A, Help & Troubleshooting

I just lost 220 photos because I needed to change their containing folders name from "Camera" to "Photography", after doing this I opened the folder and the folder was empty! I tried renaming it back to Camera but my photos were still gone! And my SD card went from having 7GBs used to 5GBs used! Is there any way for me to recovery my photos?

If you don't use the phone's internal SD storage - there is still a chance you can recover the photos.
You can dump the /sdcard/ partition as a .img and use Windows data recovery software on it.
I would make a backup of this partition asap, before attempting anything else.
To make this backup you will need a usb OTG cable and some external storage (sdcard or pen.) The .img will be around 5.5GB.
You will need root and the command is: dd if=/dev/block/platform/msm_sdcc.1/by-name/userdata of=//userdata.img
Do not accidentally dump the .img onto /sdcard/ (internal storage)
After making a backup - you can explore your options.
There are undelete apps for android such as DiskDigger undelete.
There is also undeleter on xda:
http://forum.xda-developers.com/showthread.php?p=54848945​

lost101 said:
If you don't use the phone's internal SD storage - there is still a chance you can recover the photos.
You can dump the /sdcard/ partition as a .img and use Windows data recovery software on it.
I would make a backup of this partition asap, before attempting anything else.
To make this backup you will need a usb OTG cable and some external storage (sdcard or pen.) The .img will be around 5.5GB.
You will need root and the command is: dd if=/dev/block/platform/msm_sdcc.1/by-name/userdata of=//userdata.img
Do not accidentally dump the .img onto /sdcard/ (internal storage)
After making a backup - you can explore your options.
There are undelete apps for android such as DiskDigger undelete.
There is also undeleter on xda:
http://forum.xda-developers.com/showthread.php?p=54848945​
Click to expand...
Click to collapse
Can you tell me in detail how to dump the image? Or can you give me a link to a tutorial?

What model is your phone? Is your Bootloader unlocked?

lost101 said:
What model is your phone? Is your Bootloader unlocked?
Click to expand...
Click to collapse
Motorola Moto G first gen XT1032 rooted, bootloader unlocked with TWRP custom recovery. I have Cyanogenmod 13 unoffical running android 6. My laptop does not have any drivers so if that is a requirement please tell me so I can install.

Download: Moto G USB Drivers (WinXP/7/8/10 32Bit-64Bit)
Download: ADB and Fastboot files
Test adb by enabling Settings > Developer options > USB debugging: (option may be named differently in CM13)
adb devices​

lost101 said:
Download: Moto G USB Drivers (WinXP/7/8/10 32Bit-64Bit)
Download: ADB and Fastboot files
Test adb by enabling Settings > Developer options > USB debugging: (option may be named differently in CM13)
adb devices​
Click to expand...
Click to collapse
Ok, done. Now what?

lost101 said:
Download: Moto G USB Drivers (WinXP/7/8/10 32Bit-64Bit)
Download: ADB and Fastboot files
Test adb by enabling Settings > Developer options > USB debugging: (option may be named differently in CM13)
adb devices​
Click to expand...
Click to collapse
Ok scratch that, I just plugged in my phone into my laptop and went into the Camera folder and all my photos are there but they are all 0 bytes! Is there another way to recover them?

It's best to backup the entire internal storage before trying anything. Also limit use of phone / apps on phone. Do not install or update anything.
If you don't already own one, buy a USB OTG cable - example.
ADB commands on PC:
adb shell
su
<grant root permission request on phone>
dd if=/dev/block/platform/msm_sdcc.1/by-name/userdata of=/storage/usbdisk/userdata.img​
Note: The dd command above will dump the .img to external usb pen / card. You can then use PC data recovery software on the .img file.
EDIT: http://www.nburles.co.uk/android/recovering-data-from-an-android-device-using-dd - This page details how to dump directly to PC if you have busybox installed on your phone.

lost101 said:
It's best to backup the entire internal storage before trying anything. Also limit use of phone / apps on phone. Do not install or update anything.
If you don't already own one, buy a USB OTG cable - example.
ADB commands on PC:
adb shell
su
<grant root permission request on phone>
dd if=/dev/block/platform/msm_sdcc.1/by-name/userdata of=/storage/usbdisk/userdata.img​
Note: The dd command above will dump the .img to external usb pen / card. You can then use PC data recovery software on the .img file.
EDIT: http://www.nburles.co.uk/android/recovering-data-from-an-android-device-using-dd - This page details how to dump directly to PC if you have busybox installed on your phone.
Click to expand...
Click to collapse
ok thanks!

Related

Can I push a file via fastboot?

I accidentally wiped by SYSTEM partition (ouch) but my nandroid backup is not stored on the phone. I know in TWRP you can mount USB storage and transfer the file, but I heard this is risky (corruption) compared to the adb/fastboot method.
So I have now connected my phone via fastboot but I can't seem to find a command that will push my android backup files to the SD card. Can someone help? Thanks!
Your better off doing it through mass storage
AdB is alot slower
You could do adb push "file" /sdcard/
but it would be slow like I said and you would have to know the directory names to push the nandroid
My suggestion would be to push a aosp ROM just to get it flashed and booted then transfer the nandroid
Sent from my One X using Tapatalk 2
Edit:
NVM: got it working. Thanks!

How to dump /sdcard/ partition as .img to recover lost precious photos

I have a Moto G falcon and unlocked bootloader. I then installed twrp and then CM 11. I had taken pics of my childs 16th bday on the stock rom and screwed up big time.
I would like to dump the 5.5 gig partition to sd card to try and run recovery software on it to recover photos.
so far I have been given the following advice, I dont know how to implement it however.
If you don't use the phone's internal SD storage - there is still a chance you can recover the photos.
You can dump the /sdcard/ partition as a .img and use data recovery software on it.
I would make a backup of this partition asap, before attempting anything else.
To make this backup you will need a usb OTG cable and some external storage (sdcard or pen.) The .img will be around 5.5GB.
You will need root and the command is: dd if=/dev/block/platform/msm_sdcc.1/by-name/userdata of=/<external_storage>/userdata.img
Do not accidentally dump the .img onto /sdcard/ (internal storage)
After making a backup - you can explore your options.
There are undelete apps for android such as DiskDigger undelete.
Click to expand...
Click to collapse
I have my Moto G connected to PC with otg cable and a 16 gig sd card in PC and usb debugging is on. I am in fastboot
Appreciate your help. thanks
Holysmoke99 said:
I have a Moto G falcon and unlocked bootloader. I then installed twrp and then CM 11. I had taken pics of my childs 16th bday on the stock rom and screwed up big time.
I would like to dump the 5.5 gig partition to sd card to try and run recovery software on it to recover photos.
so far I have been given the following advice, I dont know how to implement it however.
I have my Moto G connected to PC with otg cable and a 16 gig sd card in PC and usb debugging is on. I am in fastboot
Appreciate your help. thanks
Click to expand...
Click to collapse
What does "I don't know how to implement it" mean, exactly?
Do you need help following the quoted instructions?
thenookieforlife3 said:
What does "I don't know how to implement it" mean, exactly?
Do you need help following the quoted instructions?
Click to expand...
Click to collapse
sadly, yes
Holysmoke99 said:
sadly, yes
Click to expand...
Click to collapse
Ah.
I'm busy with school at the moment, but I will give you in-depth instructions in a few hours.
Sound good?
thenookieforlife3 said:
Ah.
I'm busy with school at the moment, but I will give you in-depth instructions in a few hours.
Sound good?
Click to expand...
Click to collapse
absolutely!
Okay, so let's get started!
from previous post said:
If you don't use the phone's internal SD storage - there is still a
chance you can recover the photos.
You can dump the /sdcard/ partition as a .img and use data
recovery software on it.
I would make a backup of this partition asap, before attempting
anything else.
To make this backup you will need a usb OTG cable and some
external storage (sdcard). The .img will be around 5.5GB.
You will need root and the command is:
Code:
dd if=/dev/block/platform/msm_sdcc.1/by-name/userdata of= <external_storage>/userdata.img
(the above is all one line)
Do not accidentally dump the .img onto /sdcard/ (internal storage)
After making a backup - you can explore your options.
Click to expand...
Click to collapse
To follow the above instructions, follow my steps:
1. Root your phone!
2. Download and install the attached terminal app.
3. Plug in your empty sdcard.
4. Open the terminal app and execute the following command:
Code:
su
5. Now, execute the command found in the quote above.
• This should create a file called userdata.img on your sdcard.
6. Eject your sdcard from your phone, plug it into your PC, and extract the userdata.img file with an archive manager (7zip, WinRAR).
7. Retrieve your photos!
Hope this helps!
thanks so much for your reply...
I am using an OTG cord. Do the same instructions apply?
Holysmoke99 said:
thanks so much for your reply...
I am using an OTG cord. Do the same instructions apply?
Click to expand...
Click to collapse
What are you using an OTG cable for?
Why do you need one?
thenookieforlife3 said:
What are you using an OTG cable for?
Why do you need one?
Click to expand...
Click to collapse
my phone doesnt have an sd slot
Holysmoke99 said:
my phone doesnt have an sd slot
Click to expand...
Click to collapse
Okay, and yes, it's the same procedure.
thenookieforlife3 said:
Okay, and yes, it's the same procedure.
Click to expand...
Click to collapse
I will report back tomorrow how this goes. thanks!
thenookieforlife3 said:
Okay, so let's get started!
To follow the above instructions, follow my steps:
1. Root your phone!
2. Download and install the attached terminal app.
3. Plug in your empty sdcard.
4. Open the terminal app and execute the following command:
Code:
su
5. Now, execute the command found in the quote above.
• This should create a file called userdata.img on your sdcard.
6. Eject your sdcard from your phone, plug it into your PC, and extract the userdata.img file with an archive manager (7zip, WinRAR).
7. Retrieve your photos!
Hope this helps!
Click to expand...
Click to collapse
do you know what to put for the red part?
dd if=/dev/block/platform/msm_sdcc.1/by-name/userdata of=/<put_correct_location_for_external_storage_here>/userdata.img
Holysmoke99 said:
do you know what to put for the red part?
dd if=/dev/block/platform/msm_sdcc.1/by-name/userdata of=/<put_correct_location_for_external_storage_here>/userdata.img
Click to expand...
Click to collapse
300TH POST! :laugh:
Yes, you put the exact directory on the USB stick you've got plugged into your OTG cable where you want to dump the .img.
thenookieforlife3 said:
300TH POST! :laugh:
Yes, you put the exact directory on the USB stick you've got plugged into your OTG cable where you want to dump the .img.
Click to expand...
Click to collapse
thanks, but how do I determine what the directory is named?
Holysmoke99 said:
thanks, but how do I determine what the directory is named?
Click to expand...
Click to collapse
You need to first be sure your USB stick is mounted on your device.
Then, you use a file explorer app to find out where the stick actually is. I don't know for sure, but try looking for a /mnt in the root of your device.
After you find where it's mounted, it's all easy from there. Just go into the stick's filesystem, and create a folder like "images".
Lastly, the directory name you put into the dd command will look something like this:
Code:
/mnt/usb/images
Please note that it may not be exactly like that.

[Q] need help moving app + app data to external partition sd card

hi all, i recently joined this forum to learn more. this is my first post and i am not an expert and still nub
i am sorry if my question is nubby but i didnt find the question anywhere else on forums so please help.
i recently rooted my android phone just to transfer app and app data to sd card as i read that we can do that after root.
so i rooted android phone and partitioned the sd card with a fat32 and a ext2 filesystem to store personal and app data respectively. i found tutorals on internet to do this and found a app called link2sd links and transfers all apps to sd card easily. i am using that app but i cant buy its paid version from google play. so i am not able to link the internal data to sd card as it requires the plus version. so i thought i would manually copy that internal data and paste it on the sd card and here are the problems i face :
1. i copied the internal data on the fat32 partition but it was of no use and the app again download data on internal memory
2. i thought to copy data to ext2 partition but i cant view that partition or explore it from es file explorer and root explorer both
so i wanna ask is there any way i can manually link that internal data to sd card without using link2sd plus, and how can i view that ext2 partition in my android phone.
thank you all in advance and please help.any help wud be really appreciated
I can give you a way to install any app to your sdcard directly
first of all you should have all these in your pc
java-7-jdk
usb driver for your phone
android sdk
adb
now go to the direction where you install android sdk
now open SDK Manager.exe
uncheck the mark from all except android SDK platform-tools
click install then accept all
on your phone mark usb debugging
then open the command where you had installed SDK (click shift whit the mouse button right -- open command window here)
connect your phone
then type adb devices -- to check that your phone is connected -- it will give you this
List of devices attached
************ device
then type
adb shell pm set-install-location 2
that's it
if you want to reinstall on the phone storage type
adb shell pm set-install-location 0
be free said:
I can give you a way to install any app to your sdcard directly
first of all you should have all these in your pc
java-7-jdk
usb driver for your phone
android sdk
adb
now go to the direction where you install android sdk
now open SDK Manager.exe
uncheck the mark from all except android SDK platform-tools
click install then accept all
on your phone mark usb debugging
then open the command where you had installed SDK (click shift whit the mouse button right -- open command window here)
connect your phone
then type adb devices -- to check that your phone is connected -- it will give you this
List of devices attached
************ device
then type
adb shell pm set-install-location 2
that's it
if you want to reinstall on the phone storage type
adb shell pm set-install-location 0
Click to expand...
Click to collapse
Ah, thanks a lot mate for your help. I may try it bt is there any simpler way like a app like link2sd which does nt require purchase or just transfering the data from root folder . Also can any1 tell how can i explore ext2 partition?
[/COLOR]
sweetlemon said:
Ah, thanks a lot mate for your help. I may try it bt is there any simpler way like a app like link2sd which does nt require purchase or just transfering the data from root folder . Also can any1 tell how can i explore ext2 partition?
Click to expand...
Click to collapse
try this .exe program
mobilego
http://download.wondershare.com/mobilego_full818.exe
or use this if the option move to sdcard isn't appear on apps info http://www.mediafire.com/download/a46l27yiupgw1vm/GeeksAR.com.App2SD-Patch-ENG.zip
use this to read ext2
https://docs.google.com/file/d/0B4UdboVnxTSkWmhmTkNhcFZ4UzQ/edit?pli=1

Phone not recognised by PC

Hello,
So I made the mistake of wiping my sdcard partition, so I don't have the .zip with the ROM on the phone's memory.
The ROM I currently had was deleted aswell when I formatted /system/. Recovery works, but because I don't have an external SD card, I can not put anything on the phone memory.
So now, I can not push the zip file with adb because my Moto G is not recognised, even though I installed all the drivers (in AP Flashboot Mode) it says that the USB is connected, but "adb devices" shows nothing.
So in a few words, phone memory is empty, it's not recognised by the PC so I can not push the .zip with adb sideload.
have you tried to connect an USB stick (in cwm or TWRP)?
Probably you can mount it and install a zip.
a.lex said:
have you tried to connect an USB stick (in cwm or TWRP)?
Probably you can mount it and install a zip.
Click to expand...
Click to collapse
I found a version of the Universal ADB Drivers, installed them and the adb sideload worked.
Let this be a lesson for others with phones that don't have external SD cards - NEVER delete the ROM from your phone's internal memory
FIXED
Are you using Win8 or Win7? I have read posts from people that had problems using fastboot commands in Win8.

[Q] Recovering Data from HTC One M7 after factory reset

Hello Everyone,
I've been trying for more than a week now to recover data (photos, contacts, messages) from my HTC One M7 after I accidentally hit the factory reset button (was in a hurry to play squash and was fumbling around till the disaster happened!) :crying: Worse of all, I have no backups :crying::crying: My phone has no SD card, only the internal memory. It runs on Android 5.0.2 and has been rooted. I have busybox and TWRP installed on the phone. I have Android SDK and cygwin on my PC.
Initially, I tried to mount the phone's internal memory as a drive on Windows so I can do a scan of it using a data recovery tool. But I wasn't successful as MTP seems like the only option and there's no way to diable it. Even the disable MTP option inside TWRP doesn't make the drive accessible via USB! I have tried various recovery software available online but none of them can see my phone thanks to the stupid MTP!
Finally, I tried the steps on this thread precisely
http://forum.xda-developers.com/gal...de-internal-memory-data-recovery-yes-t1994705
Have managed to copy the whole memory block of the phone using
/system/xbin/busybox nc -l -p 5555 -e /system/xbin/busybox dd if=/dev/block/mmcblk0
and created a mmcblk0.raw file which I can open using Disk Internals (Linux Reader). I found only the data that currently exists on the drive after the factory reset. Tried to access the image with TestDisk (as shown here - http://www.df.lth.se/~jokke/androidfilerecovery/) and I cannot see any of my old files there too! (I'm trying the Deeper Search Option now)
I'm not sure if 'dd' command copies the disk sector-by-sector. I think any data recovery software can scan the disk image and find the old files as long as I can create a sector-by-sector image of the phone's internal drive. If not, any way to mount the internal drive as a USB drive on Windows could work too! Can anyone please help me with this?
Many thanks in advance!!!!

Categories

Resources