Hi guys
Using ADB copied all the individual partitions (boot, aboot, system, recovery, etc) from my device to my sd card and then to my pc (Linux). Device is a Hisense Infinity H6 (HS-U800).
I am unable to mount any of the files, and have tried gdisk, fdisk, mount. I get a mount error or wring filesystem type.
Also trying to dd the entire block directly makes a single image that i am unable to read. I tried using gdisk to repair the gpt or recreate an mbr but to no avail.
I would prefer to work with the individual partitions as it appears that they have different filesystems for each. But when I specify the filesystem using mount i get a wring filesystem error.
Would appreciate any help, thanks.
PS
I'm using Ubuntu 14.04 LTS.
###
EDIT
###
Never mind, it turns out that if you dd directly from phone memory to pc android corrupts the files. Fixed it by using the sdcard as an intermediary step.
Related
Hi all.
I recently went about updating my tablet, and in the back of my mind I was under the impression that TWRP would backup the internal sdcard's files during the normal backup, so I thought nothing of wiping the internal sdcard. Whoops. It, of course, didn't, and now I find myself with a whole slew of stuff gone. Not much else was written to the internal sdcard (which is on an ext4 filesystem), so I suspect that a good bit of my stuff can still be sitting there in the data graveyard. Hopefully.
Since I'm on Linux and can't mount the sdcard directly (since for some odd reason Linux has issues with MTP), all I've been able to do was this:
I booted the tablet into recovery mode and opened up adb, and ran the following command through the adb shell:
Code:
~ # dd if=/dev/block/mmcblk0p8 of=/dev/block/mmcblk1p1
Where mmcblk0p8 is the internal sdcard with the lost data, and mmcblk1p1 is an external sdcard. I thought that by running that command, I could create a carbon copy of each and every little thing on the old sdcard, write it onto something my computer could read, and then go through the normal recovery process. In this case I planned to use a Linux tool called "extundelete."
Here's where I get stuck. The sdcard appeared to have cloned correctly, given that the entire thing is now filled up and reads as an ext4 filesystem on gparted (when it was previously fat32), but now I can't mount it. And if I can't mount it, I can't restore anything. Here's what I get when I try to mount it:
Code:
Error mounting /dev/sdb at /media/user/57f8f4bc-abf4-655f-bf67-946fc0f9f25b: Command-line `mount -t "ext4" -o "uhelper=udisks2,nodev,nosuid" "/dev/sdb" "/media/user/57f8f4bc-abf4-655f-bf67-946fc0f9f25b"' exited with non-zero exit status 32: mount: wrong fs type, bad option, bad superblock on /dev/sdb,
missing codepage or helper program, or other error
In some cases useful info is found in syslog - try
dmesg | tail or so
So to sum it up, I accidentally wiped my tablet's internal sdcard using TWRP 2.3.3.0, and now I want to recover what was lost during the wipe. Not that it matters, my tablet is a Transformer Infinity in case anyone asks. Though I don't think that's really relevant here.
If anyone knows how to help me, or knows of a better way I should go about getting my data back, that would be, for a lack of better words, super awesome.
Thanks!
BJSerpas said:
Error mounting /dev/sdb
Click to expand...
Click to collapse
Seems you tried to mount /dev/sdb, not /dev/sdb1.
Also, did you make the SDcard partition the same size as the source partition? And what did dmesg say?
Also, http://forum.xda-developers.com/showthread.php?t=1994705 might be of some help..
kuisma said:
Seems you tried to mount /dev/sdb, not /dev/sdb1.
Also, did you make the SDcard partition the same size as the source partition? And what did dmesg say?
Click to expand...
Click to collapse
When I plugged it in, Linux automatically mounted it to sdb and not sdb1. And the external SD card was the same size as the internal one, 32gb. Currently not home so I can't run dmesg at the moment.
And thank you bodh, that looks very useful and is more or less what I was trying to do. I'll have to get on a windows PC it seems, but no issue there. In the meantime, is there a way to write protect the internal SD from the android terminal emulator until I get home? I don't want my old files accidentally overwritten. Or I could just not use the tablet if that's the better option here.
Thanks guys!
I'm not sure you could write protect the internal sd. I've tried changing permissions on it and get errors. You're best bet is probably to go without the tablet use for now.
BJSerpas said:
When I plugged it in, Linux automatically mounted it to sdb and not sdb1. And the external SD card was the same size as the internal one, 32gb. Currently not home so I can't run dmesg at the moment.
Click to expand...
Click to collapse
I'm talking about the number of blocks exactly, not "32gb" or so. And mount /dev/sdb1 manually, don't rely on Gnome failing to mount /dev/sdb.
the s3 has a couple partitions that have no filesystem.
in log files their filesystems are named as emmc.
the device is able to boot from this partitons(recovery, bota0, bota1)
my question is. how to get access to the files on this partitions?
i tried to mount the recovery partition after copy it with dd on a ubuntu system,
but no chance. response was something like: give me a filesystem.
Hi!
Partitioned my 32GB sdcard, and put CM10.2 on it, but when I check it I have only about 400mb of space or something like that. I had the same amount of space on a 4GB sdcard I used before. Why am I not able to use up the rest of the GB's?! Can someone tell me how to fix it, I don't know if I'm partitioning wrong or doing something wrong, but I want to be able to have lots of extra space for music, apps, etc. Please help! Thanks!!!
I believe you used a low level utility like dd or similar to flash an image onto a partition.
You need to run fsck on that partition, then run resize2fs to expand the ext2/3/4 partition.
Let's say your partition is /dev/block/mmcblk1p1
You would do (in a terminal):
adb reboot recovery
adb shell
# umount /dev/block/mmcblk1p1
# e2fsck /dev/block/mmcblk1p1
# resize2fs /dev/block/mmcblk1p1
After that, your partition will get expanded to whatever size you made it.
It takes a while so be patient. The larger the partition, the longer it will take.
Zenile said:
Hi!
Partitioned my 32GB sdcard, and put CM10.2 on it, but when I check it I have only about 400mb of space or something like that. I had the same amount of space on a 4GB sdcard I used before. Why am I not able to use up the rest of the GB's?! Can someone tell me how to fix it, I don't know if I'm partitioning wrong or doing something wrong, but I want to be able to have lots of extra space for music, apps, etc. Please help! Thanks!!!
Click to expand...
Click to collapse
if you got a prebaked image of a bootable cm card from somewhere, then it usually has 4 partitions on it that were set to the sizes the author of the card specified.
/boot
/system
/data
/sdcard
You would need to put the card in a PC, and use a disk partitioning utility to resize the partitions
some of the images include additional flash files that you install to expand the card's partitions for you. (succulent's), but
you have to do it as you install for the first time.
I prefer to build the card empty first, and load the boot files and zips manually.
linux tools like gparted, Parted Magic , booting from a live USB or CD work pretty well.
Windows based ones like Easus Partition master, or Paragon, not so good.
Mini Tool partition wizard (windows/free) sometimes works
this looks to be a decent write up
http://www.mobileread.com/forums/showthread.php?t=202660
mikeataol said:
...
I prefer to build the card empty first, and load the boot files and zips manually.
linux tools like gparted, Parted Magic , booting from a live USB or CD work pretty well.
Windows based ones like Easus Partition master, or Paragon, not so good.
Mini Tool partition wizard (windows/free) sometimes works
this looks to be a decent write up
http://www.mobileread.com/forums/showthread.php?t=202660
Click to expand...
Click to collapse
The write-up is also posted on XDA at http://forum.xda-developers.com/showthread.php?t=2098419. It was written back in the days of CM10.1, so to use it for CM10.2 or CM11:
Obtain the boot files: MLO, u-boot.bin, and flashing_boot.img -- as well as the files boot.img and recovery.img, from the /boot partition of the pre-made SD CM image. Make sure that MLO is the first file to copy to the freshly made /boot partition.
Substitute in the appropriate ROM and Gapps zip files corresponding to the particular CM build of interest.
Hello all,
I'm hoping someone can help me with this. Long story short, I've bricked my Prime. I was running TWRP recovery (AndroWook, so 2.6.something?) and KatKiss v30 when things went south... but unbricking is for another day.
I'm more interested in getting some data that didn't make it into my last backup off the /sdcard. I don't have access to the device itself (adb or fastboot, haven't tried APX yet), but I did managed to take an image of /dev/block/mmcblk0p8 via the dd command.
The problem is I can't mount it as a loop device in Linux. The problem that started all this was that KatKiss wouldn't boot... the output of "fdisk -l /dev/block/mmcblk0" suggested that its partition table was corrupted or gone.
Various suggestions on XDA and elsewhere (xmount, kpartx, etc.) haven't allowed me to mount this backup image... I'm wondering if the missing partition table isn't the issue.
[email protected]:~/prime_backup_microsdcard_32G_20151227$ sudo mount -t auto -o
loop tf201-mmcblk0p8.img /mnt
NTFS signature is missing.
Failed to mount '/dev/loop3': Invalid argument
The device '/dev/loop3' doesn't seem to have a valid NTFS.
Maybe the wrong device is used? Or the whole disk instead of a
partition (e.g. /dev/sda, not /dev/sda1)? Or the other way around?
So my thought is to try the following:
1. Create a virtual HD of >27.GB (the size of the backup image).
2. Create a partition of the exact size/dimensions as the backup I have, and ensure I'm able to mount it.
3. Restore the backup to this partition using dd.
4. Profit.
Does this make sense, and if so, what format is /dev/block/mmcblk0p8? Based on the steps to install KatKiss I would have guessed f2fs, but the mount error above makes me think otherwise.
Thanks in advance for your help.
ACP
Hello everyone
I am having trouble mounting second partition of my external sdcard. I’ve already done as much research as i could but i couldn’t find the answer.
I am using busybox to try to mount /dev/block/mmcbl1p2 to any folder (tried in /mnt; /storage; /mnt/media_rw; and many more) but my mount command says invalid argument.
To explain what i did, in short i have a raspberry pi, i used piped unzip to dd command to write the raspbian image on my sdcard. dd command was successful and raspberry pi can boot from it. What i am trying to is setup my raspberry headless by editing /etc/network/interfaces which is located in second (ext4) partition of my extSdCard.
I know android understands linux file systems but i also know it only mounts first vfat od sdcard. Is there any way to access the files from second partition of my extSdCard ?
I am not sure how to find the answer since everything on google is related to moving apps to sdcard
Thanks
Device: Huawei Y5II - CUN-L01
Stock rom
I managed to set it up headless by using UsbTethering and connect to ssh through that connection since dhcp is auto enabled on this image for raspberry, but i would still like to know how to mount this partition. Thank you