Pixel 3 XL softbricked after Android 12 update. TWRP stuck at splashscreen. How to rescue data? - Google Pixel 3 XL Questions & Answers

Hi,
today, I received an OTA update for my Pixel 3 XL (I had rooted and unlocked it before). The phone boots up, but right before the PIN/fingerprint screen appears, the UI flickers a few times and apparently crashes, causing the device to reboot infinitely. A similar problem is reported here:
Does anyone have a serious bug in the Lock Screen since android 12 was installed? Using Pixel 5 - Google Pixel Community
support.google.com
I guess the problem would be solved if I flashed with -w (a full factory reset), but I do not want to wipe before saving some important data such as WhatsApp backup. I have my WhatsApp backup at Google, but on Google Drive it shows me a gray triangle with an exclamation mark next to the entry for WhatsApp (see attachment) and according to some users on Reddit, restoring the backup did not work for some people who had that gray triangle. Can somebody confirm that the backup did work despite having that gray triangle? (In Google Drive, click the gear symbol on the right top and go to "Applications", then scroll down to WhatsApp).
I tried re-flashing the factory image of android 12 (without -w) without success.
I also tried flashing the factory image of android 11, but after that I only get an infinite google logo loading screen.
I also downloaded the most recent TWRP and flashed it (fastboot flash boot twrp.img), but it is always stuck at the splashscreen. In this state, however, I can at least enter the adb shell. I have root access to the system, but I cannot mount the data partition (probably it is encrypted somehow). "twrp mount" fails with the error message saying that TWRP is not running (which is probably true since it is stuck at the splashscreen).
Code:
1|crosshatch:/ # twrp mount
TWRP does not appear to be running. Waiting for TWRP to start . . .
Press CTRL + C to quit.
Contents of /etc/fstab
Code:
/dev/block/dm-0 /system_root ext4 ro 0 0
/dev/block/dm-1 /vendor ext4 ro 0 0
/dev/block/dm-2 /product ext4 ro 0 0
/dev/block/sda20 /metadata ext4 rw 0 0
/dev/block/sda21 /data f2fs rw 0 0
/auto0 vfat rw 0 0
/dev/block/sdf2 /persist ext4 rw 0 0
ls /dev/block:
Code:
crosshatch:/ # ls /dev/block/by-name
ALIGN_TO_128K_1 aop_a boot_b cmnlib_b dip fsg keystore misc modemst2 product_b sdc splash storsec_b tz_b vendor_a xbl_config_b
ALIGN_TO_128K_2 aop_b cdt ddr dtbo_a hyp_a klog modem_a msadp_a qupfw_a sdd spunvm system_a uefivar vendor_b
ImageFv apdp_a cmnlib64_a devcfg_a dtbo_b hyp_b limits modem_b msadp_b qupfw_b sde ssd system_b userdata xbl_a
abl_a apdp_b cmnlib64_b devcfg_b frp keymaster_a logfs modemcal persist sda sdf sti toolsfv vbmeta_a xbl_b
abl_b boot_a cmnlib_a devinfo fsc keymaster_b metadata modemst1 product_a sdb sec storsec_a tz_a vbmeta_b xbl_config_a
I assume the "userdata" device (which symlinks to /dev/block/sda21) to contain my data, however I'm not sure about it.
The normal mount command does not work either:
Code:
crosshatch:/ # mount -o rw /dev/block/bootdevice/by-name/userdata /data
mount: /dev/block/bootdevice/by-name/userdata: need -t
1|crosshatch:/ # mount -t ext4 -o rw /dev/block/bootdevice/by-name/userdata /data
mount: '/dev/block/bootdevice/by-name/userdata'->'/data': Invalid argument
1|crosshatch:/ # mount -t f2fs -o rw /dev/block/bootdevice/by-name/userdata /data
mount: '/dev/block/bootdevice/by-name/userdata'->'/data': Invalid argument
I executed:
Code:
adb pull /dev/block/bootdevice/by-name/userdata userdata.img
This succeeded and I got a ~50GB file. Can I mount or decrypt this somehow on my PC?
Thanks and have a nice day!

Related

[Q] partition-layout: None (damaged partition)

Hi, similar to couple of threads, but - I believe - specific enough to start a new dedicated one. I have endeavoru HOX, cid HTC__032. Some time ago I damaged partition layout. It was complete ignorant era - I was doing things I should have read about before I bought used HOX with stock 3.14.401.31 (OTA update applied in the meantime as far as I rmember), I was experiencing some problems with it so unlocked, pushed CWM recovery and installed CM 10.1.3. Unfortunately, gapps kept crashing so I decided to do some cleaning and apparently did the factory reset in custom recovery. I guess this brought me to the state my HOX is in now.
So, how the things look like:
1. This is my current HOX info:
Code:
(bootloader) version: 0.5a
(bootloader) version-bootloader: 1.39.0000
(bootloader) version-baseband: 5.1204.162.29
(bootloader) version-cpld: None
(bootloader) version-microp: None
(bootloader) version-main: 3.14.401.31
(bootloader) serialno: *****
(bootloader) imei: *****
(bootloader) product: endeavoru
(bootloader) platform: HBOOT-T30S
(bootloader) modelid: PJ4610000
(bootloader) cidnum: HTC__032
(bootloader) battery-status: good
(bootloader) battery-voltage: 3816mV
(bootloader) devpower: 54
[B](bootloader) partition-layout: None[/B]
(bootloader) security: on
(bootloader) build-mode: SHIP
(bootloader) boot-mode: FASTBOOT
(bootloader) commitno-bootloader: None
(bootloader) hbootpreupdate: 2
(bootloader) gencheckpt: 0
2. I can connect via fastboot/adb - flash, use adb shell, etc. I can also push files, create and write files in adb shell, so it looks like the card is not entirely dead
3. I can flash recovery (tried TWRP and CWM) - so no problem with charging anymore
4. No partition layout and I can’t mount storage:
Code:
~ # fdisk -l /dev/block/mmcblk0
Disk /dev/block/mmcblk0: 31.2 GB, 31268536320 bytes
4 heads, 16 sectors/track, 954240 cylinders
Units = cylinders of 64 * 512 = 32768 bytes
Disk /dev/block/mmcblk0 doesn't contain a valid partition table
Code:
~ # parted /dev/block/mmcblk0
GNU Parted 1.8.8.1.179-aef3
Using /dev/block/mmcblk0
(parted) print
print
Error: /dev/block/mmcblk0: unrecognised disk label
(parted) mklabel msdos
mklabel msdos
(parted) print
print
Error: /dev/block/mmcblk0: unrecognised disk label
Code:
~ # ls -la /dev/block/
drwxr-xr-x 3 root root 300 Nov 4 21:11 .
drwxr-xr-x 9 root root 2320 Nov 4 21:07 ..
brw------- 1 root root 7, 0 Nov 4 21:07 loop0
brw------- 1 root root 7, 1 Nov 4 21:07 loop1
brw------- 1 root root 7, 2 Nov 4 21:07 loop2
brw------- 1 root root 7, 3 Nov 4 21:07 loop3
brw------- 1 root root 7, 4 Nov 4 21:07 loop4
brw------- 1 root root 7, 5 Nov 4 21:07 loop5
brw------- 1 root root 7, 6 Nov 4 21:07 loop6
brw------- 1 root root 7, 7 Nov 4 21:07 loop7
brw------- 1 root root 179, 0 Nov 4 21:07 mmcblk0
-rw-r--r-- 1 root root 0 Nov 4 21:12 mmcblk0p13
-rw-r--r-- 1 root root 0 Nov 4 21:12 mmcblk0p15
-rw-rw-rw- 1 root root 1088 Nov 4 21:12 mmcblk0p17
drwxr-xr-x 3 root root 60 Nov 4 21:07 platform
[I]-- (but this mmcblk0pxx are there only because I tried to format - unsuccessfully - related partitions through recovery) --[/I]
~ # cat /proc/partitions
major minor #blocks name
179 0 30535680 mmcblk0
~ # cat /etc/fstab
/dev/block/mmcblk0p13 /cache ext4 rw
/dev/block/mmcblk0p15 /data ext4 rw
/dev/block/mmcblk0p12 /system ext4 rw
/dev/block/mmcblk0p14 /sdcard auto rw
~ # cat /etc/recovery.fstab
# mount point fstype device [device2]
/recovery emmc /dev/block/mmcblk0p5
/boot emmc /dev/block/mmcblk0p4
/cache ext4 /dev/block/mmcblk0p13
/data ext4 /dev/block/mmcblk0p15
/sdcard auto /dev/block/mmcblk0p14
/system ext4 /dev/block/mmcblk0p12
/misc emmc /dev/block/mmcblk0p17
~ # cat /proc/emmc
dev: size erasesize name
mmcblk0p5: 00800000 00001000 "recovery"
mmcblk0p4: 00800000 00001000 "boot"
mmcblk0p12: 50000000 00001000 "system"
mmcblk0p13: 14000000 00001000 "cache"
mmcblk0p17: 00200000 00001000 "misc"
mmcblk0p1: 00600000 00001000 "wlan"
mmcblk0p2: 00200000 00001000 "WDM"
mmcblk0p20: 00200000 00001000 "pdata"
mmcblk0p3: 00600000 00001000 "radiocab"
mmcblk0p14: 650000000 00001000 "internalsd"
mmcblk0p15: 89400000 00001000 "userdata"
mmcblk0p19: 01600000 00001000 "devlog"
mmcblk0p16: 00200000 00001000 "extra"
On TRWP/CWM/Philz I get (more or less the same) logs/messages:
Code:
E:Can’t open /dev/block/mmcblk0p17
(No such file or directory)
E: Can’t mount /cache/recovery/command
E: Can’t mount /cache/recovery/log
E: Can’t open /cache/recovery/log
[I](...) eg. Wipe Data/Factory Reset:[/I]
-- Wiping data…
Formating /data
E: format_volume: make_extf4fs failed on /dev/block/mmcblk0p15
Formating /cache
E: format_volume: make_extf4fs failed on /dev/block/mmcblk0p13
Formating /sd-ext
Formating /sdcard/.android_secure…
Error mounting /sdcard/.android_secure!
Skipping format...
Data wipe complete.
5. Tried RUU that ought to be correct for my HOX & hboot version: (RUU_ENDEAVOR_U_JB_45_S_HTC_Europe_3.14.401.31_R_Radio_5.1204.162.29_release_302015_signed.exe) RUU software says it was flashed successfully, but when I restart the HOX it gets stucked on “HTC quitely brilliant” logo. Also, if I try to flash boot and system images manually (extracted from the ROM.zip from this RUU) the latter fails with “heap not enough” error (tried flashing on 32-bit Windows 7 and 64-bit OS X). This way or another, I don’t expect it to work, as there’s a problem with partition.
6. In the recovery I can’t wipe/erase a single thing (as in the example above)
7. As a result, no way to install a zip from recovery (due to missing partition layout) and no way to restore from backup (as it requires to mount /sdcard and it can't)...
8. ADB sideload doesn’t work (on TWRP: big red FAIL).
9. Some interesting lines from recovery.log:
Code:
recovery filesystem table
=========================
0 /tmp ramdisk (null) (null) 0
1 /recovery emmc /dev/block/mmcblk0p5 (null) 0
2 /boot emmc /dev/block/mmcblk0p4 (null) 0
3 /cache ext4 /dev/block/mmcblk0p13 (null) 0
4 /data ext4 /dev/block/mmcblk0p15 (null) 0
5 /sdcard auto /dev/block/mmcblk0p14 (null) 0
6 /system ext4 /dev/block/mmcblk0p12 (null) 0
7 /misc emmc /dev/block/mmcblk0p17 (null) 0
W:Unable to get recovery.fstab info for /datadata during fstab generation!
W:Unable to get recovery.fstab info for /emmc during fstab generation!
W:Unable to get recovery.fstab info for /preload during fstab generation!
W:Unable to get recovery.fstab info for /sd-ext during fstab generation!
W:Unable to get recovery.fstab info for /external_sd during fstab generation!
(...)
W:failed to mount /dev/block/mmcblk0p13 /cache ext4 (No such file or directory)
stat /dev/block/mmcblk0p17 try 1: No such file or directory
(...)
failed to stat /dev/block/mmcblk0p17
E:Can't open /dev/block/mmcblk0p17
(...)
ro.build.display.id=cm_endeavoru-userdebug 4.2.2 JDQ39E eng.root.20130419.224121 test-keys
[I](...) - leftovers from cyanogenmod?[/I]
ro.build.description=4.18.401.2 CL231174 release-keys
[I](...) - is it the reason? Are these problems because I’m actually downgrading?[/I]
ro.aa.customizationid=559204
ro.aa.romver=4.18.401.2
ro.prot=true
ro.aa.maincid=HTC__001
ro.aa.rid=302
ro.aa.modelid=PJ4610000
ro.aa.report=com
ro.aa.project=ENDEAVOR_U_JB_50_S
ro.aa.skulist=401
ro.aa.taskid=330269
ro.aa.mainsku=401
So the most interesting part is the partition-layout: None is found with fastboot getvar all. I noticed that in almost all (all?) threads where people have problems with unsuccessful stock restore (RUU) or other "stuck on logo" and share their info from getvar there's a one common issue: partition-layout: None. Does anyone have idea what's the reason and how to get it back to partition-layout: Generic (this is the correct one as I assume looking at other threads)? I believe founding a fix for this one general problem would solve all of the mentioned not-booting/stuck-on-logo/soft-bricked issues.
I have no more ideas as I browsed through tons of posts and tried a lot of possible solutions with no effect. I believe there's a need to apply some low-level system "magic" I don't feel like being able to figure out myself. If you have any idea on how to proceed I’d be more than happy to try it out. My last try would be to flash a rom with more up-to-date android, but I'm afraid it would involve updating hboot and no chance to use RUU anymore.
Also, if you think it’s all useless given the state the HOX is in, please share, so I stop to waste my (and your) time - I already spent 2 weeks on it, learned a lot, read hundreds of threads on XDA - If I’d only knew that much before
On the other hand, if any member with magic skills would like to use my HOX to perform remote surgery to try to find a general solution for that problem, I'd be more than happy (well, just happy, I would be more if I could fix it ) to sacrifice my HOX even if there's a chance to kill it definitely.
Any clues guys? Maybe I should ask different question: do you know a method to check if the internal storage is faulty (chkdsk kind of thing)? Maybe my case is helpless (why I can read/write it from recovery, though).
Also, I was thinking about booting recovery (fastboot boot recovery - NOT fastboot flash recovery), hoping it won't read from storage but from memory, thus allowing me to unmount the storage and format (am I correct here? would it help anyway?). The thing is fastboot boot recovery won't work on HOX, but maybe there's a specific way that overrides kernel commandline (fastboot -c ... ) known already.
My HOX is stock, locked and working perfectly, and when I do a fastboot getvar all I also see partition-layout: none, so that cannot be the problem.
webpatrick said:
My HOX is stock, locked and working perfectly, and when I do a fastboot getvar all I also see partition-layout: none, so that cannot be the problem.
Click to expand...
Click to collapse
Thank you webpatrick, good to know that. So this one is not a problem.
I suspect bad sectors then (I wonder if that could be a reason for my HOX to restart on stock and gapps keep crashing on CWM back in the days it was alive). Any idea how to verify that and maybe fix?
Ok, so browsing (way) outside One X forum, I found GPT fdisk compiled for android. It is available in this thread: http://forum.xda-developers.com/showpost.php?p=24805392&postcount=74 or directly http://dl.dropbox.com/u/64885133/gptfdisk.zip. I could use it to load partition data from a backup file, but - obviously - I don't have one.
Could any of you guys run gdisk from the zip, back up GPT data to a file and post it?
Code:
./adb push gdisk /sbin
./adb shell
~ # gdisk /dev/block/mmcblk0
GPT fdisk (gdisk) version 0.8.4
Command (? for help): b
Enter backup filename to save: backup.gpt
The operation has completed successfully.
Command (? for help): q
Thanks in advance!
Couple points more:
1) To clarify, as I believe it matters, I have 32GB version, so I'd enjoy GPT back up for this one. Anyone, pleeeeease?
2) Also, one more question. Correct me if I'm wrong, but I believe that:
a) If I flash firmware manually, I don't have to change the name of the zip file
b) If I "flash" automatically, I need to change the name of the firmware zip to the specific one, PJ46IMG.zip in my case, before I put it on the sd card
Not that I could try b), but just wondering if I've been trying a) in the correct way

[Q] How to recover data and reset flash counter when phone won't boot

My S3 went haywire a few days ago and in my attempts to recover data I loaded the TWRP bootloader and a custom ROM hoping I could eventually reboot it and reset the flash counter. Unfortunately, it still won't reboot - it hangs on the pulsing SAMSUNG animation, after the "Samsung Galaxy SIII" splash screen and the Android blast-off animation.
I've already done a cache wipe and factory reset so ideally I'd like to get it into a state where I can run data recovery software to retrieve my deleted files. But if that can't be done, at the least I want to reset the flash counter so the phone will be replaced under warranty.
Since I received the last replacement in Oct 2013 I forgot to enable USB Debugging and I didn't root phone. In my searches, it looks like the power button is stuck (doesn't feel like it, though) and the phone randomly reboots when is Recovery Mode or Download Mode. About 10% of the time I can get it into either mode and remain stable.
Tools I downloaded & installed:
SkipSoft Android Toolkit (updated and registered)
Samsung USB Drivers v1.5.42.0
Google ADT (updated)
Odin 3.09
Here's what I haven/haven't done so far:
Haven't enabled USB Debugging in the OS
Haven't rooted phone
Installed TWRP 2.7.0.0
Installed root66_TMO_T999UVDMD5.tar, but device still won't boot completely
After TWRP installed, I had to updated driver in Device Manager to "Intel USB Flash Loader Utility" from Samsung. In the TWRP logs I see:
E: Could not mount /data and unable to find crypto footer.
E: Unable to mount '/data'
E: Unable to recreate /data/media folder.
Updating partition details...
E: Unable to mount '/data'
E: Unable to mount internal storage.
E: Unable to mount /data/media during GUI startup.
Full SELinux support is present.
Running boot script...
Finished running boot script.
E: Unable to mount /data/media/TWRP/.twrps when trying to read settings file.
E: Unable to mount '/data'
Do I have any hope of recovering the data or resetting the flash counter? I've also considered trying JTAG recovery through a local vendor, but still would like to reset the counter.
Thanks - any help would be GREATLY appreciated.
some progress
OK, with some persistence I managed to get the device to a bootable state. I managed to installed TWRP Bootloader and Chainfire's SuperUser, and that got the phone bootable. Android version is 4.1.2, USB Debugging is now ON, and I went through the setup process but disabled all antennas once I noticed it was downloading content.... PHEW...
For anyone dealing with this issue, here's what worked and didn't:
1 - Spraying CRC brand circuit cleaner on power button - didn't try it, too lazy/scared that I'd break something else
2 - Knocking Power button with a pencil eraser (found elsewhere in xda-developers forum) - this seemed to clear up the issue intermittently
3 - Loaded TWRP using Odin - this worked
4 - Loaded Chainfire AutoRoot - this failed when using miscellaneous tutorials online, BUT it worked when I went straight to the CF Autoroot site (autoroot.chainfire.eu) downloaded the specific file for my device, and loaded it via Odin
Now I'm trying to get data recovery software to recognize the device to analyze the drive and find any recoverable data. Any suggestions?
So far I've tried:
Recuva - unable to see phone
Asoftech Data Recovery - unable to see phone
Glary Undelete - unable to see phone
yodot - unable to see phone
Search xda for an app called Easy UMS. (I think). Then use it to connect as a USB Mass Storage device. If that doesn't help im not sure what else to tell you.
DocHoliday77 said:
Search xda for an app called Easy UMS. (I think). Then use it to connect as a USB Mass Storage device. If that doesn't help im not sure what else to tell you.
Click to expand...
Click to collapse
DocHoliday - thanks for the tip, but Easy UMS only allows access to the external SD card. I'm continuing my search. There must be something that at least allows a full bit-wise backup of the entire device to an SD card that I can then use for forensics.
maradamc said:
DocHoliday - thanks for the tip, but Easy UMS only allows access to the external SD card. I'm continuing my search. There must be something that at least allows a full bit-wise backup of the entire device to an SD card that I can then use for forensics.
Click to expand...
Click to collapse
It looks like BusyBox and the DD command can create a bit-by-bit partition dump but I'm not sure how to issue the commands. I have ADB and SU access, BusyBox installed.
dd if=/dev/block/mmcblk0p15 of=c:\path\saving\to
This will dump the entire userdata partition to an image file on your Windows computer. Note the direction of the /'s.
Thanks Doc! I reformatted my external SD Card to exFAT, then ran the DD command to dump the userdata partition. I'm using DiskInternals Linux Recovery right now to scan the image for any recoverable files.
Where can I find more info on those different partitions in /dev/block/? I think some of the files I want to recover are in /data/data/ and I don't know which partition that would be. I've tried "mount" and "ls -l /dev/block/platform/*/by-name/" but I can't find any reference to a /data/ mount.
My last shot will be to downgrade the OS to ICS version and try data recovery directly via the USB cable. All this stuff I'm finding sure will make a good tutorial afterwards.
The dump you created is the entire /data partition. So it should have everything you need. (Userdata/data, same thing in this case. Sorry if I wasn't more clear on that)
You can google t999 galaxy s3 partition layout and should be able to find the rest. Don't have time to look it up and write it ir I'd just post it here for you.
I did some digging and found I need to pull data from:
/sdcard/callrecorder/
/storage/emulated/0/sounds/
I'm trying to decipher if I need to dump any additional partitions. No luck finding much useful information on S3 partitions - this was the closest I found - http://forum.xda-developers.com/galaxy-s3/general/galaxy-s-iii-partition-layout-basic-efs-t1689623
In ADB, I retrieved the following, but none of them obviously map to sdcard or storage/emulated.
ls -l /dev/block/platform/*/by-name/
lrwxrwxrwx root root 1969-12-31 22:16 aboot -> /dev/block/mmcblk0p5
lrwxrwxrwx root root 1969-12-31 22:16 backup -> /dev/block/mmcblk0p20
lrwxrwxrwx root root 1969-12-31 22:16 boot -> /dev/block/mmcblk0p7
lrwxrwxrwx root root 1969-12-31 22:16 cache -> /dev/block/mmcblk0p17
lrwxrwxrwx root root 1969-12-31 22:16 efs -> /dev/block/mmcblk0p11
lrwxrwxrwx root root 1969-12-31 22:16 fota -> /dev/block/mmcblk0p19
lrwxrwxrwx root root 1969-12-31 22:16 fsg -> /dev/block/mmcblk0p21
lrwxrwxrwx root root 1969-12-31 22:16 grow -> /dev/block/mmcblk0p23
lrwxrwxrwx root root 1969-12-31 22:16 modem -> /dev/block/mmcblk0p1
lrwxrwxrwx root root 1969-12-31 22:16 modemst1 -> /dev/block/mmcblk0p12
lrwxrwxrwx root root 1969-12-31 22:16 modemst2 -> /dev/block/mmcblk0p13
lrwxrwxrwx root root 1969-12-31 22:16 pad -> /dev/block/mmcblk0p9
lrwxrwxrwx root root 1969-12-31 22:16 param -> /dev/block/mmcblk0p10
lrwxrwxrwx root root 1969-12-31 22:16 persist -> /dev/block/mmcblk0p16
lrwxrwxrwx root root 1969-12-31 22:16 recovery -> /dev/block/mmcblk0p18
lrwxrwxrwx root root 1969-12-31 22:16 rpm -> /dev/block/mmcblk0p6
lrwxrwxrwx root root 1969-12-31 22:16 sbl1 -> /dev/block/mmcblk0p2
lrwxrwxrwx root root 1969-12-31 22:16 sbl2 -> /dev/block/mmcblk0p3
lrwxrwxrwx root root 1969-12-31 22:16 sbl3 -> /dev/block/mmcblk0p4
lrwxrwxrwx root root 1969-12-31 22:16 ssd -> /dev/block/mmcblk0p22
lrwxrwxrwx root root 1969-12-31 22:16 system -> /dev/block/mmcblk0p14
lrwxrwxrwx root root 1969-12-31 22:16 tz -> /dev/block/mmcblk0p8
lrwxrwxrwx root root 1969-12-31 22:16 userdata -> /dev/block/mmcblk0p15
[email protected]:/ # mount
mount
rootfs / rootfs ro,relatime 0 0
tmpfs /dev tmpfs rw,nosuid,relatime,mode=755 0 0
devpts /dev/pts devpts rw,relatime,mode=600 0 0
proc /proc proc rw,relatime 0 0
sysfs /sys sysfs rw,relatime 0 0
none /acct cgroup rw,relatime,cpuacct 0 0
tmpfs /mnt/asec tmpfs rw,relatime,mode=755,gid=1000 0 0
tmpfs /mnt/obb tmpfs rw,relatime,mode=755,gid=1000 0 0
none /dev/cpuctl cgroup rw,relatime,cpu 0 0
/dev/block/platform/msm_sdcc.1/by-name/system /system ext4 ro,relatime,user_xattr,barrier=1,data=ordered 0 0
/dev/block/platform/msm_sdcc.1/by-name/userdata /data ext4 rw,nosuid,nodev,relatime,user_xattr,barrier=1,journal_async_commit,data=ordered,noauto_da_alloc,discard 0 0
/dev/block/platform/msm_sdcc.1/by-name/cache /cache ext4 rw,nosuid,nodev,relatime,user_xattr,barrier=1,data=ordered 0 0
/dev/block/platform/msm_sdcc.1/by-name/persist /persist ext4 rw,nosuid,nodev,relatime,user_xattr,barrier=1,data=ordered 0 0
/dev/block/platform/msm_sdcc.1/by-name/modem /firmware vfat ro,relatime,gid=1000,fmask=0006,dmask=0006,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro 0 0
/dev/block/platform/msm_sdcc.1/by-name/efs /efs ext4 rw,nosuid,nodev,relatime,user_xattr,barrier=1,data=ordered 0 0
/sys/kernel/debug /sys/kernel/debug debugfs rw,relatime 0 0
/dev/fuse /storage/sdcard0 fuse rw,nosuid,nodev,noexec,relatime,user_id=1023,group_id=1023,default_permissions,allow_other 0 0
Additionally, the DD for userdata is 12GB while the whole device is 16GB... still trying to figure out how to capture the remaining 4GB. And to complicate things, I've gotten data recovery software to recognize the image dump and scan it, but the files I want have uncommon file extensions (*.m4a, *.3ga) or no extensions at all. <sigh>... it's gonna be a long week...
The 4gb is reserved for the os and firmware. So a 16gb S3 will have 12gb allocated for /data.
The internal sdcard is not a partition of its own. Its simply part of the data partition.
Also, the link you provided is for the I9300, the international S3 which is a very different device with a different partition layout.
This is ours:
Code:
Number Start End Size FS-Type Name Flags
-------------------------------------------------------------------------------
1 4194304B 67108863B 62914560B modem
2 67108864B 67239935B 131072B sbl1
3 67239936B 67502079B 262144B sbl2
4 67502080B 68026367B 524288B sbl3
5 68026368B 70123519B 2097152B aboot
6 70123520B 70647807B 524288B rpm
7 70647808B 81133567B 10485760B boot
8 81133568B 81657855B 524288B tz
9 81657856B 82182143B 524288B pad
10 82182144B 92667903B 10485760B param
11 92667904B 106954751B 14286848B ext4 efs
12 106954752B 110100479B 3145728B modemst1
13 110100480B 113246207B 3145728B modemst2
14 113246208B 1686110207B 1572864000B ext4 system
15 1686110208B 30337400831B 28651290624B ext4 userdata
16 30337400832B 30345789439B 8388608B ext4 persist
17 30345789440B 31226593279B 880803840B ext4 cache
18 31226593280B 31237079039B 10485760B recovery
19 31237079040B 31247564799B 10485760B fota
20 31247564800B 31253856255B 6291456B backup
21 31253856256B 31257001983B 3145728B fsg
22 31257001984B 31257010175B 8192B ssd
23 31257010176B 31262253055B 5242880B grow
(Just thought it might be a little easier to read this way)
As for pulling the files you need from the .img and the unknown extensions, im not sure. Are you using linux or Windows?
Thanks for that table! I noticed that link wasn't for the T999, which is why I hesitated to rely on it. IDK why I'm having such a hard time finding info on the T999.
Anyway, I managed to DD every single partition by running:
dd if=/dev/block/mmcblk0p5 of=/storage/extSdCard/aboot.img
dd if=/dev/block/mmcblk0p20 of=/storage/extSdCard/backup.img
dd if=/dev/block/mmcblk0p7 of=/storage/extSdCard/boot.img
dd if=/dev/block/mmcblk0p17 of=/storage/extSdCard/cache.img
dd if=/dev/block/mmcblk0p11 of=/storage/extSdCard/efs.img
dd if=/dev/block/mmcblk0p19 of=/storage/extSdCard/fota.img
dd if=/dev/block/mmcblk0p21 of=/storage/extSdCard/fsg.img
dd if=/dev/block/mmcblk0p23 of=/storage/extSdCard/grow.img
dd if=/dev/block/mmcblk0p9 of=/storage/extSdCard/pad.img
dd if=/dev/block/mmcblk0p10 of=/storage/extSdCard/param.img
dd if=/dev/block/mmcblk0p16 of=/storage/extSdCard/persist.img
dd if=/dev/block/mmcblk0p18 of=/storage/extSdCard/recovery.img
dd if=/dev/block/mmcblk0p6 of=/storage/extSdCard/rpm.img
dd if=/dev/block/mmcblk0p2 of=/storage/extSdCard/sb11.img
dd if=/dev/block/mmcblk0p3 of=/storage/extSdCard/sb12.img
dd if=/dev/block/mmcblk0p4 of=/storage/extSdCard/sb13.img
dd if=/dev/block/mmcblk0p22 of=/storage/extSdCard/ssd.img
dd if=/dev/block/mmcblk0p14 of=/storage/extSdCard/system.img
dd if=/dev/block/mmcblk0p8 of=/storage/extSdCard/tz.img
dd if=/dev/block/mmcblk0p15 of=/storage/extSdCard/userdata.img
For data recovery, I'm running windows and have installed several tools so I'm able to mount the Linux image as a drive.
Cygwin - I've only played with basics in *nix terminal but am comfortable using command prompt
Ext2Fsd
DiskInternals (Linux Reader & Recovery)
OSFMount
I'll tally up the data recovery/carving tools I've downloaded and tried. Now that I have the images dumped, I'm installing ICS 4.0.4 in an attempt to get USB drive access and try the data recovery software directly against the device.
It may seem difficult to find info on the T999, but a lot of that is due to it being posted in other S3 forums. All US S3's are similar enough that most information applies to all of them. The partition table is one of these. They all are partitioned exactly the same.
Btw, when looking for the internal sdcard data, it will be in the /data/media folder. So in the image just look for the media folder.
I will remember that. Any suggestions where to track down /storage/emulated/0/sounds/ from a partition perspective?
I just finished flashing down to ICS 4.0.4. Even though Odin said it was successful, it's hanging on boot-up at the pulsing Samsung logo just like when this whole mess started. Time for another Factory Reset... not like I can do any more harm.
/storage/emulated/0 = /data/media
Nice! My list of pulled partitions matches the one you provided. Glad to know I was on the right track.
So now I have Android 4.0.4 installed on my device. The problem I have now is that the device isn't recognized in Windows and I can't find a driver for it to work. I've tried Samsung_USB_Driver_for_Mobile_Phones_v1.5.14.0 and v1.5.42.0 - no go. Also tried the ADT driver (android_winusb.inf), still no go. Also tried the driver bundled with the Unified Android Toolkit (by SkipSoft, an XDA dev'r) - no luck. Any suggestions? It must be a driver that supports the old USB Drive mode instead of MTP.
For others who might try this downgrade, I rebooted the device into Download mode and during installation, Odin kept getting an error before finishing. I think it was because I was trying to multitask on the computer because once I let Odin do its thing with and stepped away from the PC, the installation completed successfully. Reboots then kept freezing up but a Factory Reset resolved that.
The S3 never supported using UMS (USB drive), so using different driver versions won't make any difference there. Im honestly not sure if anyone's ever found a way to do this at all. Other than the Easy UMS app.

Stuck in the bootloop after flashing data.img on Pixel C device.

Hi,
I am stuck in the bootloop after flashing data.img on Pixel C device.
I have done the following steps and have serached around in 100s of forums before posting this. Please bear with me.
My bootloader is unlocked and I have flashed my boot partition with dragon-boot-encryptable-rooted-01092016-1.img so that the data is not encrypted by default.
I have a freshly booted up (new setup) device with default apps installed. I installed one app so that the /data partition contains something. I am firing all commands as root on Ubuntu 14
I then flashboot into TWRP recovery so that I can access root shell through adb. This is not flashing the TWRP recovery, just booting into it.
#adb reboot bootloader
#fastboot boot twrp-3.0.0-0-dragon-ryu-02112016-1.img
#adb shell
~ # whoami
root
~ # df
Filesystem 1K-blocks Used Available Use% Mounted on
tmpfs 1420244 20 1420224 0% /dev
tmpfs 1420244 20 1420224 0% /tmp
/dev/block/mmcblk0p6 396744 452 388100 0% /cache
/dev/block/mmcblk0p7 55453060 304032 55132644 1% /data
/dev/block/mmcblk0p7 55453060 304032 55132644 1% /sdcard
Now, I am interested only in taking image backup of my /data partition which is at /dev/block/mmcblk0p7. I confirmed this by:
/dev/block/platform/700b0600.sdhci/by-name # ls -l
...
lrwxrwxrwx 1 root root 20 Oct 16 07:38 UDA -> /dev/block/mmcblk0p7
...
Now, I fire the make_ext4fs command to create the image.
~#umount /sdcard (optional)
~ # make_ext4fs -s -l 55453060K -a data mydata.img /data
SELinux: Loaded file_contexts contexts from /file_contexts.
Creating filesystem with parameters:
Size: 56783933440
Block size: 4096
Blocks per group: 32768
Inodes per group: 8176
Inode size: 256
Journal blocks: 32768
Label:
Blocks: 13863265
Block groups: 424
Reserved block group size: 1024
Created filesystem with 11/3466624 inodes and 263660/13863265 blocks
mydata.img is created. I do an adb pull on my Ubuntu and fetch the mydata.img and /file_contexts
#adb pull /file_contexts
#adb pull /mydata.img
# du *
20 file_contexts
140888 mydata.img
Now, I convert the mydata.img into raw image file with simg2img.
#./simg2img mydata.img mydata.img.raw
#ls -lrt
-rw-r--r-- 1 root root 17261 Oct 16 13:17 file_contexts
-rw-r--r-- 1 root root 144267780 Oct 16 13:18 mydata.img
-rw-r--r-- 1 root root 56783933440 Oct 16 13:21 mydata.img.raw
Now, I create a directory and mount my raw image into that directory.
#mkdir phonedata
#mount -t ext4 mydata.img.raw phonedata/
I navigate into phonedata and verify the contents. I can see that the app I installed in avaialable under /data/data.
Then, I re-create the image from phonedata mount using make_ext4fs, or I can use the mydata.img fetch by adb pull too.
If I re-create the image, I give file_contexts(fetched) as the -S option to make_ext4fs. One doubt here, if I am re-creating the sparse image, what value should be passed to -l paramtere now?
I got to fastboot and fire these commands.
#fastboot format userdata
#fastboot format data
#fastboot format cache
#fastboot flash data mydata.img { I am confused between data and userdata, which is the correct one. This is mydata.img from adb pull }
#fastboot flash vendor vendor.img { I read in one forum that vendor should be flashed again on a nexus device }
#fastboot reboot
All things take smoothly. When the tab reboot, it shows Google logo, then android flash animation, then it shows 'Android is starting', and then goes back to flash animation. That is, it's stuck in bootloop.
Kindly let me know if there is something with these steps. Or is there is any alternate way to do the same thing. My problem statement is, I need a flashable data.img. I can create TWRP backup and recovery fine, but that's not my requirement.
Thanks!
Edit 1:
I should add, at this point, if I hard boot to fastboot and do a fastboot format userdata followed by fastboot reboot, I am able to boot to device and perform new device setup.
I can also flash system,boot,vendor,recovery and cache.img and perform new device setup normally. This should mean my fastboot/adb are working fine.
Ummmmm
Did you try with smaller sparse image size ?
make_ext4fs -s -l 30000M -a data mydata.img /data
The sparse will grow until max partition size.
Did you play with "img2simg" as well ? (not simg2img)
img2simg mydata.img.raw mydata.img

Question I think I messed up my B Slot Partition(s)

I have a Poco F3 Global, and I currently am running TWRP 3.5.2_11-Nebrassy.
If I tap Reboot and it shows my Current Slot as A, then under Mount I see the following:
System, system_ext, Product, Vendor, ODM, Metadata, Data, Cust, and Firmware
And I can check each of them. I can also perform Wipe -> Format Data -> yes.
But if I boot into Slot B, and tap Mount it doesn't let me click the checkmarks for System, system_ext, Product, or Vendor.
And if I try to execute Wipe -> Format Data -> yes it shows "Failed to mount" in red for all of the following:
'/system_root', '/system_ext', '/product', '/vendor' (Invalid argument)
(Some of them are in there multiple times)
Running cat /etc/fstab in B outputs:
Code:
/dev/block/sda18 /metadata ext4 rw 0 0
/dev/block/sda35 /data f2fs rw 0 0
/dev/block/sda29 /cust ext4 rw 0 0
/dev/block/bootdevice/by-name/modem_b /firmware vfat rw 0 0
/dev/block/sda22 /persist ext4 rw 0 0
/usb_otg vfat rw 0 0
Running cat /etc/fstab in A outputs:
Code:
/dev/block/dm-2 /system_root ext4 ro 0 0
/dev/block/dm-3 /system_ext ext4 ro 0 0
/dev/block/dm-1 /product ext4 ro 0 0
/dev/block/dm-4 /vendor ext4 ro 0 0
/dev/block/dm-0 /odm ext4 ro 0 0
/dev/block/sda18 /metadata ext4 rw 0 0
/dev/block/sda35 /data f2fs rw 0 0
/dev/block/sda29 /cust ext4 rw 0 0
/firmware vfat rw 0 0
/dev/block/sda22 /persist ext4 rw 0 0
/usb_otg vfat rw 0 0
For both A and B going to Wipe -> Advanced Wipe it only shows Dalvik / ART Cache, Metadata, Data, Internal Storage, and USB-OTG
I can still install an OS, but that is finicky at times.
How can I fix my B Partition?
Solved it:
Download the MiFlash Tool, and the Fastboot version of the Stock ROM. Extract the contents of the zip (and within the zip the tar file) to a directory without spaces in it (I just extracted it directly to C: drive). Open MiFlash, click Select and choose the directory you just extracted. At the bottom of the MiFlash app select "Clean All", NOT "Clean all and Lock" (unless that's what you want). Click Refresh (if phone doesn't appear, make sure your phone is in fastboot mode and connected to PC). Then click Flash. Mine failed the first time with some error about "Antirollback check error". If you get this you have to manually edit the "flash_all.bat" file within the extracted directory and remove the lines that don't start with "fastboot", then save the bat file, and restart the flash. It took MiFlash 604 seconds to complete, and ended with a status of "error: Not catch checkpoint, ..., flash is not done" you can ignore that, or remove that checkpoint in the MiFlash configuration settings. My phone restarted and booted into the stock ROM.
following had the same errors when i mistakenly ignorantly wiped system etc while trying to flash a rom

Question 19 GB system partition.

I know android needs a big system partition to accommodate updates but 19gb is ludicrous. Did anyone successfully shrink this partition after root ? And to what size ?
I don’t think u can shrink without a custom recovery but I think I can work on one
I could try and port a tree from the moto g9 power
Why do you want shrink it? You got ~111GB of Internal Memory & still have SD slot?
Are you sure it's /system you're looking at¹ or do you mean the system reserved blocks of the internal memory? My /data for the internal memory is 104GB, so the entire Android installation is only using around 7GB taking overheads and beancounter disk space into account. Also, this is an A/B device, which means some partitions have "companion" secondaries.
Code:
caprip:/ $ ls /dev/block/by-name
abl_a cid devinfo fsg_a limits modem_b prov_a ssd uefivarstore vendor_boot_a
abl_b cmnlib64_a dhob fsg_b logfs modemst1 prov_b storsec_a userdata vendor_boot_b
apdp cmnlib64_b dsp_a hw logo_a modemst2 qupfw_a storsec_b utags xbl_a
bluetooth_a cmnlib_a dsp_b hyp_a logo_b msadp qupfw_b super utagsBackup xbl_b
bluetooth_b cmnlib_b dtbo_a hyp_b metadata padA rpm_a tz_a vbmeta_a xbl_config_a
boot_a ddr dtbo_b keymaster_a misc padB rpm_b tz_b vbmeta_b xbl_config_b
boot_b devcfg_a frp keymaster_b mmcblk0 persist sp uefisecapp_a vbmeta_system_a
carrier devcfg_b fsc kpan modem_a prodpersist spunvm uefisecapp_b vbmeta_system_b
Code:
caprip:/ $ df -h
Filesystem Size Used Avail Use% Mounted on
/dev/block/dm-0 804M 802M 0 100% /
tmpfs 2.7G 1.4M 2.7G 1% /dev
tmpfs 2.7G 3.2M 2.7G 1% /dev/Td3J
tmpfs 2.7G 0 2.7G 0% /mnt
/dev/block/dm-2 620M 618M 0 100% /system_ext
/dev/block/dm-3 725M 723M 0 100% /vendor
/dev/block/dm-4 2.3G 2.3G 0 100% /product
tmpfs 2.7G 0 2.7G 0% /apex
/dev/block/mmcblk0p34 27M 14M 13M 52% /vendor/dsp
/dev/block/mmcblk0p49 3.7M 272K 3.2M 8% /mnt/product/persist
/dev/block/mmcblk0p69 13M 13M 0 100% /vendor/fsg
/dev/block/dm-5 104G 10G 94G 10% /data
¹ /system on this device isn't a real partition. It's a dynamic part of the super partition.
I'm going by this. There's no way I've 42gb used.

Categories

Resources