[SOLVED] Reformat /cache /system /boot partitions? - Sprint HTC One (M7)

Hello, forum!
I have an issue with my Sprint m7. I inherited it with problems, but I'm afraid I might have made them worse. I have been trying to SIM unlock this phone for days now and I keep hitting snags. Well, in a drunken frustration one night recently, I seem to have done a wipe in TWRP and deleted some rather important partitions without making a backup. Now my room smells like shame
Anyway, I was hoping I could find some help on these forums. I want to reformat the partitions and flash a ROM to get this phone up and running again. I was following @nkk71's responses to a similar problem here. However, his solution to the issue was for m7_u and m7_ul only. The partition identifiers are apparently different for Sprint, VZ, and Dual SIM. I was hoping that maybe someone could walk me through the steps or offer some sound advice on getting this brick up and running again. I would like to reformat the partitions and simply push a rom and install through CWM as that seems like the only option now.
I tried flashing a stock recovery and factory reset, but recovery simply won't load regardless of the option I choose in the bootloader.
Before the wipe, I had ADB and FASTBOOT access across the board, but now the only place I can get ADB access is through CWM recovery. TWRP does not load anymore after the wipe (splash, then cut to black, then bootloop). CWM works, but it seems like every time I try to do something, I get an error with mounting /system or /cache
Please help if you can! Thanks! :victory:
HBOOT Versioning:
Code:
*** TAMPERED ***
*** UNLOCKED ***
M7_WLS PVT SHIP S-ON RH
HBOOT-1.56.0000
RADIO-1.00.20.1108
OpenDSP-V32.120.274.0909
OS-4.06.651.9
eMMC-boot 2048MB
Feb 25 2014,21:52:07.0
fastboot getvar all results:
Code:
(bootloader) version: 0.5
(bootloader) version-main: 4.06.651.9
(bootloader) version-misc: PVT SHIP S-ON
(bootloader) serialno: FA35GS914427
(bootloader) imei: 990001468107123
(bootloader) meid: 99000146810712
(bootloader) product: m7_wls
(bootloader) platform: HBOOT-8064
(bootloader) modelid: PN0720000
(bootloader) cidnum: SPCS_001
(bootloader) battery-status: good
(bootloader) battery-voltage: 4309mV
(bootloader) partition-layout: Generic
(bootloader) security: on
(bootloader) build-mode: SHIP
(bootloader) boot-mode: FASTBOOT
(bootloader) commitno-bootloader: dirty-4dab9d12
(bootloader) hbootpreupdate: 11
(bootloader) gencheckpt: 0
all: Done!
finished. total time: 0.040s

wpetestraw;52389761. . . Please help if you can! Thanks! :victory:[/QUOTE said:
Go get my TWRP build (look in my signature below).
Tell it to wipe /cache and /system *and* /data it won't wipe your personal data, it knows better.
Then load up a ROM of your liking -- that will reload /system and /data with relevant parts, and /cache is largely uninteresting anyway.
The /boot needs no formatting, it's always a direct dump (dd) of a boot image right onto that partition.
See if that doesn't get you going.
Click to expand...
Click to collapse

nkk71 said:
m7_wls (Sprint) partitions:
Code:
mmcblk0p37: 73fffc00 00000200 "system"
mmcblk0p38: 27fffe00 00000200 "cache"
mmcblk0p39: 680000000 00000200 "userdata"
m7_u/ul partitions:
Code:
mmcblk0p35: 73fffc00 00000200 "system"
mmcblk0p36: 27fffe00 00000200 "cache"
mmcblk0p37: 680000000 00000200 "userdata"
Click to expand...
Click to collapse
Thanks @nkk71 for posting these partition IDs. I was able to format the partitions using the mkfs.ext4 file you uploaded.
Here are the results of the formatting:
Code:
C:\Users\Akuma\Desktop\Root>adb shell
~ # mount
mount
rootfs on / type rootfs (rw,seclabel)
tmpfs on /dev type tmpfs (rw,seclabel,nosuid,relatime,mode=755)
devpts on /dev/pts type devpts (rw,seclabel,relatime,mode=600)
proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,seclabel,relatime)
selinuxfs on /sys/fs/selinux type selinuxfs (rw,relatime)
tmpfs on /storage type tmpfs (rw,seclabel,relatime,mode=050,gid=1028)
tmpfs on /mnt/secure type tmpfs (rw,seclabel,relatime,mode=700)
tmpfs on /mnt/fuse type tmpfs (rw,seclabel,relatime,mode=775,gid=1000)
~ # exit
exit
C:\Users\Akuma\Desktop\Root>adb push mkfs.ext4 /tmp/
3241 KB/s (3537143 bytes in 1.065s)
C:\Users\Akuma\Desktop\Root>adb shell
~ # chmod 777 /tmp/mkfs.ext4
chmod 777 /tmp/mkfs.ext4
~ # /tmp/mkfs.ext4 -b 4096 -O ^huge_file,^dir_nlink,^ext_attr,^resize_inode,^ext
ra_isize -m 0 /dev/block/mmcblk0p37
/tmp/mkfs.ext4 -b 4096 -O ^huge_file,^dir_nlink,^ext_attr,^resize_inode,^ext
ra_isize -m 0 /dev/block/mmcblk0p37
mke2fs 1.41.12 (17-May-2010)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
Stride=0 blocks, Stripe width=0 blocks
118800 inodes, 475135 blocks
0 blocks (0.00%) reserved for the super user
First data block=0
15 block groups
32768 blocks per group, 32768 fragments per group
7920 inodes per group
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912
Writing inode tables: done
Creating journal (8192 blocks): done
Writing superblocks and filesystem accounting information: done
This filesystem will be automatically checked every 38 mounts or
180 days, whichever comes first. Use tune2fs -c or -i to override.
~ # /tmp/mkfs.ext4 -b 4096 -O ^huge_file,^dir_nlink,^ext_attr,^resize_inode,^ext
ra_isize -m 0 /dev/block/mmcblk0p38
/tmp/mkfs.ext4 -b 4096 -O ^huge_file,^dir_nlink,^ext_attr,^resize_inode,^ext
ra_isize -m 0 /dev/block/mmcblk0p38
mke2fs 1.41.12 (17-May-2010)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
Stride=0 blocks, Stripe width=0 blocks
40960 inodes, 163839 blocks
0 blocks (0.00%) reserved for the super user
First data block=0
5 block groups
32768 blocks per group, 32768 fragments per group
8192 inodes per group
Superblock backups stored on blocks:
32768, 98304
Writing inode tables: done
Creating journal (4096 blocks): done
Writing superblocks and filesystem accounting information: done
This filesystem will be automatically checked every 36 mounts or
180 days, whichever comes first. Use tune2fs -c or -i to override.
~ # /tmp/mkfs.ext4 -b 4096 -O ^huge_file,^dir_nlink,^ext_attr,^resize_inode,^ext
ra_isize -m 0 /dev/block/mmcblk0p39
/tmp/mkfs.ext4 -b 4096 -O ^huge_file,^dir_nlink,^ext_attr,^resize_inode,^ext
ra_isize -m 0 /dev/block/mmcblk0p39
mke2fs 1.41.12 (17-May-2010)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
Stride=0 blocks, Stripe width=0 blocks
1703936 inodes, 6815744 blocks
0 blocks (0.00%) reserved for the super user
First data block=0
208 block groups
32768 blocks per group, 32768 fragments per group
8192 inodes per group
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000
Writing inode tables: done
Creating journal (32768 blocks): done
Writing superblocks and filesystem accounting information: done
This filesystem will be automatically checked every 26 mounts or
180 days, whichever comes first. Use tune2fs -c or -i to override.
~ # mount /data
mount /data
~ # mkdir -p /data/media/0
mkdir -p /data/media/0
~ # exit
exit
C:\Users\Akuma\Desktop\Root>fastboot flash recovery recovery.img
sending 'recovery' (9136 KB)...
OKAY [ 1.143s]
writing 'recovery'...
OKAY [ 0.700s]
finished. total time: 1.843s
C:\Users\Akuma\Desktop\Root>fastboot erase cache
erasing 'cache'...
OKAY [ 0.045s]
finished. total time: 0.045s
C:\Users\Akuma\Desktop\Root>fastboot reboot-bootloader
rebooting into bootloader...
OKAY [ 0.032s]
finished. total time: 0.032s
C:\Users\Akuma\Desktop\Root>adb devices
List of devices attached
FA35GS914427 recovery
C:\Users\Akuma\Desktop\Root>adb push ARHD_31.6.zip /data/media/0/
failed to copy 'ARHD_31.6.zip' to '/data/media/0/': Is a directory
C:\Users\Akuma\Desktop\Root>adb devices
List of devices attached
FA35GS914427 sideload
C:\Users\Akuma\Desktop\Root>adb sideload ARHD_31.6.zip
sending: 'ARHD_31.6.zip' 100%
I'm not sure what happened with the adb ROM push, but I was able to sideload it into CWM and flash the ARHD 31.6 ROM. The installation of the ROM seemed successful, but when rebooting the system, the phone still hangs on bootloop.
Since the partition IDs are different for m7_u/ul and Sprint, does this also mean that the ext4 file would be different as well?

tdhite said:
Go get my TWRP build (look in my signature below).
Tell it to wipe /cache and /system *and* /data it won't wipe your personal data, it knows better.
Then load up a ROM of your liking -- that will reload /system and /data with relevant parts, and /cache is largely uninteresting anyway.
The /boot needs no formatting, it's always a direct dump (dd) of a boot image right onto that partition.
See if that doesn't get you going.
Click to expand...
Click to collapse
Okay, this version of TWRP works now thank you! adb commands work and no more crash to bootloop! Wipe successful. Working on ROM load now.

wpetestraw said:
Thanks @nkk71 for posting these partition IDs. I was able to format the partitions using the mkfs.ext4 file you uploaded.
Here are the results of the formatting:
Code:
C:\Users\Akuma\Desktop\Root>adb shell
~ # mount
mount
rootfs on / type rootfs (rw,seclabel)
tmpfs on /dev type tmpfs (rw,seclabel,nosuid,relatime,mode=755)
devpts on /dev/pts type devpts (rw,seclabel,relatime,mode=600)
proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,seclabel,relatime)
selinuxfs on /sys/fs/selinux type selinuxfs (rw,relatime)
tmpfs on /storage type tmpfs (rw,seclabel,relatime,mode=050,gid=1028)
tmpfs on /mnt/secure type tmpfs (rw,seclabel,relatime,mode=700)
tmpfs on /mnt/fuse type tmpfs (rw,seclabel,relatime,mode=775,gid=1000)
~ # exit
exit
C:\Users\Akuma\Desktop\Root>adb push mkfs.ext4 /tmp/
3241 KB/s (3537143 bytes in 1.065s)
C:\Users\Akuma\Desktop\Root>adb shell
~ # chmod 777 /tmp/mkfs.ext4
chmod 777 /tmp/mkfs.ext4
~ # /tmp/mkfs.ext4 -b 4096 -O ^huge_file,^dir_nlink,^ext_attr,^resize_inode,^ext
ra_isize -m 0 /dev/block/mmcblk0p37
/tmp/mkfs.ext4 -b 4096 -O ^huge_file,^dir_nlink,^ext_attr,^resize_inode,^ext
ra_isize -m 0 /dev/block/mmcblk0p37
mke2fs 1.41.12 (17-May-2010)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
Stride=0 blocks, Stripe width=0 blocks
118800 inodes, 475135 blocks
0 blocks (0.00%) reserved for the super user
First data block=0
15 block groups
32768 blocks per group, 32768 fragments per group
7920 inodes per group
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912
Writing inode tables: done
Creating journal (8192 blocks): done
Writing superblocks and filesystem accounting information: done
This filesystem will be automatically checked every 38 mounts or
180 days, whichever comes first. Use tune2fs -c or -i to override.
~ # /tmp/mkfs.ext4 -b 4096 -O ^huge_file,^dir_nlink,^ext_attr,^resize_inode,^ext
ra_isize -m 0 /dev/block/mmcblk0p38
/tmp/mkfs.ext4 -b 4096 -O ^huge_file,^dir_nlink,^ext_attr,^resize_inode,^ext
ra_isize -m 0 /dev/block/mmcblk0p38
mke2fs 1.41.12 (17-May-2010)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
Stride=0 blocks, Stripe width=0 blocks
40960 inodes, 163839 blocks
0 blocks (0.00%) reserved for the super user
First data block=0
5 block groups
32768 blocks per group, 32768 fragments per group
8192 inodes per group
Superblock backups stored on blocks:
32768, 98304
Writing inode tables: done
Creating journal (4096 blocks): done
Writing superblocks and filesystem accounting information: done
This filesystem will be automatically checked every 36 mounts or
180 days, whichever comes first. Use tune2fs -c or -i to override.
~ # /tmp/mkfs.ext4 -b 4096 -O ^huge_file,^dir_nlink,^ext_attr,^resize_inode,^ext
ra_isize -m 0 /dev/block/mmcblk0p39
/tmp/mkfs.ext4 -b 4096 -O ^huge_file,^dir_nlink,^ext_attr,^resize_inode,^ext
ra_isize -m 0 /dev/block/mmcblk0p39
mke2fs 1.41.12 (17-May-2010)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
Stride=0 blocks, Stripe width=0 blocks
1703936 inodes, 6815744 blocks
0 blocks (0.00%) reserved for the super user
First data block=0
208 block groups
32768 blocks per group, 32768 fragments per group
8192 inodes per group
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000
Writing inode tables: done
Creating journal (32768 blocks): done
Writing superblocks and filesystem accounting information: done
This filesystem will be automatically checked every 26 mounts or
180 days, whichever comes first. Use tune2fs -c or -i to override.
~ # mount /data
mount /data
~ # mkdir -p /data/media/0
mkdir -p /data/media/0
~ # exit
exit
C:\Users\Akuma\Desktop\Root>fastboot flash recovery recovery.img
sending 'recovery' (9136 KB)...
OKAY [ 1.143s]
writing 'recovery'...
OKAY [ 0.700s]
finished. total time: 1.843s
C:\Users\Akuma\Desktop\Root>fastboot erase cache
erasing 'cache'...
OKAY [ 0.045s]
finished. total time: 0.045s
C:\Users\Akuma\Desktop\Root>fastboot reboot-bootloader
rebooting into bootloader...
OKAY [ 0.032s]
finished. total time: 0.032s
C:\Users\Akuma\Desktop\Root>adb devices
List of devices attached
FA35GS914427 recovery
C:\Users\Akuma\Desktop\Root>adb push ARHD_31.6.zip /data/media/0/
failed to copy 'ARHD_31.6.zip' to '/data/media/0/': Is a directory
C:\Users\Akuma\Desktop\Root>adb devices
List of devices attached
FA35GS914427 sideload
C:\Users\Akuma\Desktop\Root>adb sideload ARHD_31.6.zip
sending: 'ARHD_31.6.zip' 100%
I'm not sure what happened with the adb ROM push, but I was able to sideload it into CWM and flash the ARHD 31.6 ROM. The installation of the ROM seemed successful, but when rebooting the system, the phone still hangs on bootloop.
Since the partition IDs are different for m7_u/ul and Sprint, does this also mean that the ext4 file would be different as well?
Click to expand...
Click to collapse
no, the mkfs file is the same. however this:
Code:
C:\Users\Akuma\Desktop\Root>adb push ARHD_31.6.zip /data/media/0/
failed to copy 'ARHD_31.6.zip' to '/data/media/0/': Is a directory
disturbs me
.... are you sure, that
1- you have a m7_wls recovery?
2- /data must have been mounted since you used "mount /data", otherwise i could understand the error
what does "mount" (in the adb shell) show?

nkk71 said:
no, the mkfs file is the same. however this:
Code:
C:\Users\Akuma\Desktop\Root>adb push ARHD_31.6.zip /data/media/0/
failed to copy 'ARHD_31.6.zip' to '/data/media/0/': Is a directory
disturbs me
.... are you sure, that
1- you have a m7_wls recovery?
2- /data must have been mounted since you used "mount /data", otherwise i could understand the error
what does "mount" (in the adb shell) show?
Click to expand...
Click to collapse
mount results:
Code:
C:\Users\Akuma\Desktop\Root>adb shell
~ # mount
mount
rootfs on / type rootfs (rw,seclabel)
tmpfs on /dev type tmpfs (rw,seclabel,nosuid,relatime,mode=755)
devpts on /dev/pts type devpts (rw,seclabel,relatime,mode=600)
proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,seclabel,relatime)
selinuxfs on /sys/fs/selinux type selinuxfs (rw,relatime)
tmpfs on /storage type tmpfs (rw,seclabel,relatime,mode=050,gid=1028)
tmpfs on /mnt/secure type tmpfs (rw,seclabel,relatime,mode=700)
tmpfs on /mnt/fuse type tmpfs (rw,seclabel,relatime,mode=775,gid=1000)
I tried to mk dir again in shell and then the push worked. I don't know what I did

wpetestraw said:
mount results:
I tried to mk dir again in shell and then the push worked. I don't know what I did
Click to expand...
Click to collapse
so the push worked, and installed the ROM?

nkk71 said:
so the push worked, and installed the ROM?
Click to expand...
Click to collapse
The ROM installed, but this time, instead of getting hung on bootloop (@ white HTC screen), it played the HTC One w/beatsaudio video and then hung up on me.

Hmm, did another mount in adb shell and the results are different now:
Code:
C:\Users\Akuma\Desktop\Root>adb shell
~ # ←[6nmount
mount
rootfs on / type rootfs (rw,seclabel)
tmpfs on /dev type tmpfs (rw,seclabel,nosuid,relatime,mode=755)
devpts on /dev/pts type devpts (rw,seclabel,relatime,mode=600)
proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,seclabel,relatime)
selinuxfs on /sys/fs/selinux type selinuxfs (rw,relatime)
tmpfs on /tmp type tmpfs (rw,seclabel,relatime)
/dev/block/mmcblk0p38 on /cache type ext4 (rw,seclabel,relatime)
/dev/block/mmcblk0p39 on /data type ext4 (rw,seclabel,relatime,data=ordered)
/dev/block/mmcblk0p39 on /sdcard type ext4 (rw,seclabel,relatime,data=ordered)

wpetestraw said:
The ROM installed, but this time, instead of getting hung on bootloop (@ white HTC screen), it played the HTC One w/beatsaudio video and then hung up on me.
Click to expand...
Click to collapse
for how long? you know the first boot can take anywhere from a few minutes to 15 minutes.
my personal experience (m7_ul)... after a clean flash (ie wiping userpartition during the installer, and before rebooting wiping dalvik & cache [a bit redundant, but i do it anyways]):
during the first bootup, the screen brightness changes after 3~5 minutes, then i know i'm not in a bootloop, and wait another 5~20 minutes.... more than 20 minutes (as in... "i left it overnight") is unreasonable.
---------- Post added at 10:26 PM ---------- Previous post was at 10:24 PM ----------
wpetestraw said:
Hmm, did another mount in adb shell and the results are different now:
Code:
C:\Users\Akuma\Desktop\Root>adb shell
~ # ←[6nmount
mount
rootfs on / type rootfs (rw,seclabel)
tmpfs on /dev type tmpfs (rw,seclabel,nosuid,relatime,mode=755)
devpts on /dev/pts type devpts (rw,seclabel,relatime,mode=600)
proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,seclabel,relatime)
selinuxfs on /sys/fs/selinux type selinuxfs (rw,relatime)
tmpfs on /tmp type tmpfs (rw,seclabel,relatime)
/dev/block/mmcblk0p38 on /cache type ext4 (rw,seclabel,relatime)
/dev/block/mmcblk0p39 on /data type ext4 (rw,seclabel,relatime,data=ordered)
/dev/block/mmcblk0p39 on /sdcard type ext4 (rw,seclabel,relatime,data=ordered)
Click to expand...
Click to collapse
actually that looks good, and looks like TWRP recovery, both /data and /sdcard are mounted

nkk71 said:
for how long? you know the first boot can take anywhere from a few minutes to 15 minutes.
my personal experience (m7_ul)... after a clean flash (ie wiping userpartition during the installer, and before rebooting wiping dalvik & cache [a bit redundant, but i do it anyways]):
during the first bootup, the screen brightness changes after 3~5 minutes, then i know i'm not in a bootloop, and wait another 5~20 minutes.... more than 20 minutes (as in... "i left it overnight") is unreasonable.
---------- Post added at 10:26 PM ---------- Previous post was at 10:24 PM ----------
actually that looks good, and looks like TWRP recovery, both /data and /sdcard are mounted
Click to expand...
Click to collapse
Understood, reflashing ROM just in case, then I'll go edge the yard

Well, that's what I get for being impatient. ROM installed ok, looks like she's good to go. Any special advice on gaining S-off or should I just give rumrunner a shot now?

Hi everyone,
How can I rewrite all partitions?
My imei and baseband null,
I tried everything
I installed all roms but
It doesn't improve.
Maybe if rewrite all partitions,
it can ameliorative.
Can anyone help me?

Related

how to dump your zio

I wrote this up in another forum and it also got lost in the 1.6 thread. Thought I'd pull it out.
---------
Instructions on how to dump your image manually:
Note: Everything in green is a command to type.
Pre)You installed the Kyocera USB drivers that came with the phone.
Kyocera ZIO - Downloads
Direct: http://www.ziobykyocera.com/downloads/files/M6000_USB_Driver.zip
Also, on the phone: Menu->Settings->Applications->Development->USB Debugging [selected]
Steps:
Root your phone:
[APP] [ROOT] 1-click root for N1 (Latest ver: 1.6.2 beta 5) - xda-developers
Direct: xda-developers
Install Android SDK for windows:
Android SDK | Android Developers
Direct: http://dl.google.com/android/android-sdk_r07-windows.zip
Extract that somewhere convinient, for ex: c:\
You'll need dump_image to get the img, find it here:
My Brain Hurts: Porting Clockwork Recovery to New Devices
Direct: http://koush.tandtgaming.com/test/dump_image
Copy that to the root of your sdcard, we'll use it later.
Lets connet to your phone.
Plug it in to the usb, make sure it is not mounted for reading the sdcard. On the phone, in the notification window tap the 'usb connected' notice and select "don't mount".
Now in windows, click Start->Run and type cmd.
cd \android-sdk-windows\tools\
adb.exe devices
It should list your device if all has gone well.
adb.exe shell
It should have connected to the phone and you have a "$" prompt.
su root
Now look at the phone, the Super User program (was installed after 1-click-root) should have popped up and asked if you want to allow root access, allow it.
Now you are at a "#" prompt.
Installing dump_image:
dump_image should be on the root of your sdcard from step 3.
Copy it to your bin directory:
cat /sdcard/dump_image > /system/bin/dump_image
Give it executable permission:
chmod 6755 /system/bin/dump_image
What to dump:
cat /proc/mtd
You're going to want to copy the output of that to the forum.
There should be a number of lines begining with mtd#
and the last name column has the name we'll need in quotes.
The dump:
mkdir /sdcard/dumped
dump_image boot /sdcard/dumped/boot.img
That just pulled the boot image. We need to do that for all the other images now:
dump_image name_here /sdcard/dumped/name_here.img
There could be 6-8 of them. Total will take a couple hundred megs.
Final:
Now we have it all, so zip up the files in /sdcard/dumped and put it on megaupload.com or something like that and post a link and the output from "cat /proc/mtd"
And that's it
Simple, yeah?
Some of those partitions that were listed in /proc/mtd are probably not needed, but I'm not certain as to which ones those are. I'm guessing "cache" and "userdata" probably aren't needed.
There was some issues with using the dump_image on yaffs2 partitions. For those the yaffs2 utility is useful. Here's some more info that was in the 1.6 thread:
Get it here:
http://jiggawatt.org/badc0de/android/mkfs.yaffs2.arm.tar.gz
(I attached it as well since that's the only place I could find an actual working version)
There's also a utility to extract the yaffs2 image (source)
You can also google for "mkyaffs2image" which is for something I can't recall.
Kind of shows how to use it in the middle of this section:
http://jiggawatt.org/badc0de/android/index.html#dynamic
adb push mkfs.yaffs2 /data/misc/mkfs.yaffs2
adb shell
# cd /data/misc
# ./mkfs.yaffs2 /system /system.img
# exit
adb pull /system.img ./system.img
Click to expand...
Click to collapse
Other useful info:
Code:
#cat /proc/mtd
dev: size erasesize name
mtd0: 01080000 00020000 "fota_amss"
mtd1: 00400000 00020000 "boot"
mtd2: 06780000 00020000 "system"
mtd3: 011e0000 00020000 "flex"
mtd4: 00500000 00020000 "recovery"
mtd5: 0ba60000 00020000 "userdata"
mtd6: 00600000 00020000 "fota_boot"
mtd7: 06780000 00020000 "cache"
mtd8: 000c0000 00020000 "misc"
Code:
#mount
rootfs / rootfs ro,relatime 0 0
tmpfs /dev tmpfs rw,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
/dev/block/mtdblock2 /system yaffs2 rw,relatime 0 0
/dev/block/mtdblock5 /data yaffs2 rw,nosuid,nodev,relatime 0 0
tmpfs /mnt/asec tmpfs rw,relatime,mode=755,gid=1000 0 0
/dev/block/mtdblock7 /cache yaffs2 rw,nosuid,nodev,relatime 0 0
/dev/block/mtdblock3 /data/FLEX yaffs2 rw,nosuid,nodev,relatime 0 0
/dev/block/vold/179:1 /mnt/sdcard vfat rw,dirsync,nosuid,nodev,noexec,relatime,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
/dev/block/vold/179:1 /mnt/secure/asec vfat rw,dirsync,nosuid,nodev,noexec,relatime,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
tmpfs /mnt/sdcard/.android_secure tmpfs ro,relatime,size=0k,mode=000 0 0
So
Code:
boot not yaffs2
system yaffs2
recovery ...most likely yaffs2
userdata yaffs2
cache yaffs2
misc ...no clue
I've also tossed a bug in clockworkmods ears -- maybe if enough people request, we can get a fully supported recovery through rom manager.
dump_image data /sdcard/data.img
can't find data partition
is this a yaffs2 partition?
edit: mkfs.yaffs2 allows me to dump the partition, dump_image will not.
Could you clarify, ftr, what filesystem each of the partitions are?
I added more info the the second post about the yaffs2 and partitions.

system dump

Hey guys,
Here's a dump of /system from the Google I/O GT10.1. Let me know if there's anything else you're interested in.
http://www.mediafire.com/?hmjy4w04u9cb4j4
smaskell said:
Hey guys,
Here's a dump of /system from the Google I/O GT10.1. Let me know if there's anything else you're interested in.
http://www.mediafire.com/?hmjy4w04u9cb4j4
Click to expand...
Click to collapse
EDIT: Haha fail wasn't even thinking.....
Thanks mate. Can you dump boot and recovery as well? Not even sure if you can, but...
I could if I knew where they were. Someone more knowledgeable than I would probably know where they usually are. Unfortunately, I cannot search the device because most standard commands are not available(find, grep, etc.)
smaskell said:
I could if I knew where they were. Someone more knowledgeable than I would probably know where they usually are. Unfortunately, I cannot search the device because most standard commands are not available(find, grep, etc.)
Click to expand...
Click to collapse
Cool. Thanks.
Have you tried adding busybox? Im surprised that the root 'package' didn't include them. I think Titanium Backup will add it for you but not the symlinks AFAIK so you need to prefix each command with busybox. eg:
Code:
busybox chmod +x <file>
it won't let me create a link to /system/bin/ because it's stuck at read only. I created a thread about this already, but does anyone know how to remount /system? I've tried the standard ways and they don't seem to work
This worked for me:
mount -o remount,rw /system
If all else fails, use Root Explorer to remount /system
Just thinking "out loud" here, but would it be fair to say that if someone could extract the boot and recovery images from these google 10.1's that they could be flashed onto a 10.1v with Odin or fastboot and allow the 10.1v to be rooted in the same way as the 10.1g?
That's what I'm hoping
Sent from my GT-P7100 using XDA Premium App
ObsidianX said:
This worked for me:
mount -o remount,rw /system
Click to expand...
Click to collapse
wow, that was stupid of me. I was trying
mount -o remount,rw /dev/block/mmcblk0p4 /system
but obviously that isn't needed.
Thanks
alright, so I have busybox working
but all the tutorials I've found have said to use
cat /proc/mtd
to find out what to pull but for me, it just returns
dev: size erasesize name
also, they say to use
cat /dev/mtd/mtdX > /sdcard/mtdX.img
but /dev/mtd doesn't exist on this device
any ideas what I could be doing wrong?
smaskell said:
alright, so I have busybox working
but all the tutorials I've found have said to use
cat /proc/mtd
to find out what to pull but for me, it just returns
dev: size erasesize name
also, they say to use
cat /dev/mtd/mtdX > /sdcard/mtdX.img
but /dev/mtd doesn't exist on this device
any ideas what I could be doing wrong?
Click to expand...
Click to collapse
Stupid question, but you did do a
Code:
su
before running these commands?
Sometimes it's the simple things
it certainly wouldn't be the first time I'd missed something as blatantly obvious as that, but no I did remember this time. That's not to say that I'm not missing something else that should be completely obvious, but I did at least remember to run it as root.
smaskell said:
it certainly wouldn't be the first time I'd missed something as blatantly obvious as that, but no I did remember this time.
Click to expand...
Click to collapse
Haha - yeah, Ive certainly been stumped by simpler things than that. Usually success if followed by a facepalm
Really appreciate your persistence with this!
Could you possibly post the output of:
Code:
adb shell mount
and
Code:
adb shell su ls -l /cache
You should see from this output which device is mounted as /cache and how the /cache/recovery is mounted/linked.
certainly
Code:
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
debugfs /sys/kernel/debug debugfs 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/mmcblk0p4 /system ext4 ro,relatime,barrier=1,data=ordered 0 0
/dev/block/mmcblk0p5 /cache ext4 rw,nosuid,nodev,noatime,barrier=1,data=ordered 0 0
/dev/block/mmcblk0p8 /data ext4 rw,nosuid,nodev,noatime,barrier=1,data=ordered 0 0
/dev/block/mmcblk0p1 /efs ext4 rw,nosuid,nodev,noatime,barrier=1,data=ordered 0 0
/dev/fuse /mnt/sdcard fuse rw,nosuid,nodev,relatime,user_id=1023,group_id=1023,default_permissions,allow_other 0 0
Code:
drwxrwx--- root root 1969-12-31 16:00 lost+found
drwxrwx--- system cache 2011-05-11 23:38 recovery
in /cache/recovery/last_log, I see this(among other things)
Code:
recovery filesystem table
=========================
0 /tmp ramdisk (null) (null) '(null)' 0000 '(null)' 0
1 /efs ext4 /dev/block/mmcblk0p1 (null) '(null)' 0000 '(null)' 0
2 /recovery emmc /dev/block/mmcblk0p2 (null) '(null)' 0000 '(null)' 0
3 /boot emmc /dev/block/mmcblk0p3 (null) '(null)' 0000 '(null)' 0
4 /system ext4 /dev/block/mmcblk0p4 (null) '(null)' 0000 '(null)' 0
5 /cache ext4 /dev/block/mmcblk0p5 (null) '(null)' 0000 '(null)' 0
6 /data ext4 /dev/block/mmcblk0p8 (null) '(null)' 0000 '(null)' -16384
I'll try pulling mmcblk0p2 and 3
Edit: here they are. Hopefully this is what you were looking for
or not.. I tried uploading twice and both times it appeared to succeed but they're not showing up. let's try again.
still not working. let's try mediafire
http://www.mediafire.com/file/r37q8vluzshkdu8/boot.img
http://www.mediafire.com/file/bhi4q2wrqgl2ms5/recovery.img
Fantastic! Thanks again.
Downloading now although I just discovered I have blown my 120Gb/month allowance in 14 days so it may take a while to download at 256k
EDIT: smaskell, you are truly a champ! Recovery works on the 10.1v so I now have root!
Will be posting a guide here and asking all to thank smaskell
http://forum.xda-developers.com/showthread.php?t=1079781
smaskell said:
or not.. I tried uploading twice and both times it appeared to succeed but they're not showing up. let's try again.
still not working. let's try mediafire
http://www.mediafire.com/file/r37q8vluzshkdu8/boot.img
http://www.mediafire.com/file/bhi4q2wrqgl2ms5/recovery.img
Click to expand...
Click to collapse
You need to zip them. XDA only accepts ZIPs and media files for upload. Only discovered this myself yesterday
excellent! just glad I could help =]

CM10 - Issue with /data partiton

After installing the latest CM10 Nightly 20121002 it would appear that the /datadata partition is back however my apps are still trying to install themselves to /data which has been reduced to ~80MB and as a result I get a messsage soon after the market restore begins that space is low.
I went back to CM10-20120919 and I have 422MB available in the /data partition as expected.
I tried to post to the CM10 Nightly thread but I'm still less than 10 posts old on XDA, I posted the partition layout in 20121002 on the Cyanogen forums, can't post links, too noobish for XDA yet again.
Is this expected behaviour in CM10? Do we now how to put everything on the SD card?
Hi,
I'm on CM10 1002 and I have 1G free in /data (and 472M used). In /datadata I have 218M free and 203M used.
All my apps are on the phone, i didn't moved anything on sd card.
I think it was something wrong with your install, you should try flashing it again.
Aviatoru said:
Hi,
I'm on CM10 1002 and I have 1G free in /data (and 472M used). In /datadata I have 218M free and 203M used.
All my apps are on the phone, i didn't moved anything on sd card.
I think it was something wrong with your install, you should try flashing it again.
Click to expand...
Click to collapse
I have downloaded the latest nightly 20121003 and I still have the same issue.
Here is what I see in ADB:
1|[email protected]:/ # df
df
Filesystem Size Used Free Blksize
/dev 184M 48K 184M 4096
/mnt/asec 184M 0K 184M 4096
/mnt/obb 184M 0K 184M 4096
/cache 17M 2M 14M 4096
/radio 16M 15M 760K 4096
/datadata 422M 17M 404M 4096
/system 393M 229M 164M 4096
/data 81M 46M 35M 4096
/efs 12M 5M 6M 4096
/storage/sdcard1 7G 822M 6G 32768
/storage/sdcard0 14G 11G 3G 8192
/mnt/secure/asec 14G 11G 3G 8192
[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/mtdblock3 /cache yaffs2 rw,nosuid,nodev,relatime 0 0
/dev/block/mtdblock5 /radio yaffs2 rw,relatime 0 0
/dev/block/mtdblock2 /datadata yaffs2 rw,relatime 0 0
/dev/lvpool/system /system ext4 ro,relatime,barrier=1,data=ordered 0 0
/dev/lvpool/userdata /data ext4 rw,nosuid,nodev,noatime,errors=panic,barrier=1,n
omblk_io_submit,data=ordered 0 0
/dev/block/mtdblock4 /efs yaffs2 rw,relatime 0 0
/sys/kernel/debug /sys/kernel/debug debugfs rw,relatime 0 0
/dev/block/vold/179:9 /storage/sdcard1 vfat rw,dirsync,nosuid,nodev,noexec,relat
ime,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,ioch
arset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
/dev/block/vold/179:1 /storage/sdcard0 vfat rw,dirsync,nosuid,nodev,noexec,relat
ime,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,ioch
arset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
/dev/block/vold/179:1 /mnt/secure/asec vfat rw,dirsync,nosuid,nodev,noexec,relat
ime,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,ioch:angel:
arset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
tmpfs /storage/sdcard0/.android_secure tmpfs ro,relatime,size=0k,mode=000 0 0
[email protected]:/ #
Everything checks out except the /data LV, it's only been created as 81MB!
Something has gone wrong in LVM:
--- Volume group ---
VG Name lvpool
System ID
Format lvm2
Metadata Areas 1
Metadata Sequence No 3
VG Access read/write
VG Status resizable
MAX LV 0
Cur LV 2
Open LV 2
Max PV 0
Cur PV 1
Act PV 1
VG Size 484.00 MiB
PE Size 4.00 MiB
Total PE 121
Alloc PE / Size 121 / 484.00 MiB
Free PE / Size 0 / 0
VG UUID buUfFr-wHCP-0WaI-theX-LYHJ-WIB3-CvBIW0
--- Logical volume ---
LV Path /dev/lvpool/system
LV Name system
VG Name lvpool
LV UUID KyabDe-sf7A-eVsT-S0ay-XenC-Yvyk-QuStAC
LV Write Access read/write
LV Creation host, time localhost, 2012-10-05 19:18:17 +0000
LV Status available
# open 1
LV Size 400.00 MiB
Current LE 100
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 254:0
--- Logical volume ---
LV Path /dev/lvpool/userdata
LV Name userdata
VG Name lvpool
LV UUID zIQCKS-O3sA-QqJa-6FCb-dw0A-mvSV-5nAcH0
LV Write Access read/write
LV Creation host, time localhost, 2012-10-05 19:18:17 +0000
LV Status available
# open 1
LV Size 84.00 MiB
Current LE 21
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 254:1
[EDIT]
Partition list on mmcblk0
[email protected]:/ # fdisk -l /dev/block/mmcblk0
fdisk -l /dev/block/mmcblk0
Disk /dev/block/mmcblk0: 16.0 GB, 16005464064 bytes
255 heads, 63 sectors/track, 1945 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/block/mmcblk0p1 1 1868 15004678+ c Win95 FAT32 (LB
A)
/dev/block/mmcblk0p2 1869 1931 500173 83 Linux
/dev/block/mmcblk0p3 1931 1946 125453 82 Linux swap
Anybody know how to fix this?
infecticide said:
I have downloaded the latest nightly 20121003 and I still have the same issue.
Here is what I see in ADB:
1|[email protected]:/ # df
df
Filesystem Size Used Free Blksize
/dev 184M 48K 184M 4096
/mnt/asec 184M 0K 184M 4096
/mnt/obb 184M 0K 184M 4096
/cache 17M 2M 14M 4096
/radio 16M 15M 760K 4096
/datadata 422M 17M 404M 4096
/system 393M 229M 164M 4096
/data 81M 46M 35M 4096
/efs 12M 5M 6M 4096
/storage/sdcard1 7G 822M 6G 32768
/storage/sdcard0 14G 11G 3G 8192
/mnt/secure/asec 14G 11G 3G 8192
[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/mtdblock3 /cache yaffs2 rw,nosuid,nodev,relatime 0 0
/dev/block/mtdblock5 /radio yaffs2 rw,relatime 0 0
/dev/block/mtdblock2 /datadata yaffs2 rw,relatime 0 0
/dev/lvpool/system /system ext4 ro,relatime,barrier=1,data=ordered 0 0
/dev/lvpool/userdata /data ext4 rw,nosuid,nodev,noatime,errors=panic,barrier=1,n
omblk_io_submit,data=ordered 0 0
/dev/block/mtdblock4 /efs yaffs2 rw,relatime 0 0
/sys/kernel/debug /sys/kernel/debug debugfs rw,relatime 0 0
/dev/block/vold/179:9 /storage/sdcard1 vfat rw,dirsync,nosuid,nodev,noexec,relat
ime,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,ioch
arset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
/dev/block/vold/179:1 /storage/sdcard0 vfat rw,dirsync,nosuid,nodev,noexec,relat
ime,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,ioch
arset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
/dev/block/vold/179:1 /mnt/secure/asec vfat rw,dirsync,nosuid,nodev,noexec,relat
ime,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,ioch:angel:
arset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
tmpfs /storage/sdcard0/.android_secure tmpfs ro,relatime,size=0k,mode=000 0 0
[email protected]:/ #
Everything checks out except the /data LV, it's only been created as 81MB!
Something has gone wrong in LVM:
--- Volume group ---
VG Name lvpool
System ID
Format lvm2
Metadata Areas 1
Metadata Sequence No 3
VG Access read/write
VG Status resizable
MAX LV 0
Cur LV 2
Open LV 2
Max PV 0
Cur PV 1
Act PV 1
VG Size 484.00 MiB
PE Size 4.00 MiB
Total PE 121
Alloc PE / Size 121 / 484.00 MiB
Free PE / Size 0 / 0
VG UUID buUfFr-wHCP-0WaI-theX-LYHJ-WIB3-CvBIW0
--- Logical volume ---
LV Path /dev/lvpool/system
LV Name system
VG Name lvpool
LV UUID KyabDe-sf7A-eVsT-S0ay-XenC-Yvyk-QuStAC
LV Write Access read/write
LV Creation host, time localhost, 2012-10-05 19:18:17 +0000
LV Status available
# open 1
LV Size 400.00 MiB
Current LE 100
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 254:0
--- Logical volume ---
LV Path /dev/lvpool/userdata
LV Name userdata
VG Name lvpool
LV UUID zIQCKS-O3sA-QqJa-6FCb-dw0A-mvSV-5nAcH0
LV Write Access read/write
LV Creation host, time localhost, 2012-10-05 19:18:17 +0000
LV Status available
# open 1
LV Size 84.00 MiB
Current LE 21
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 254:1
[EDIT]
Partition list on mmcblk0
[email protected]:/ # fdisk -l /dev/block/mmcblk0
fdisk -l /dev/block/mmcblk0
Disk /dev/block/mmcblk0: 16.0 GB, 16005464064 bytes
255 heads, 63 sectors/track, 1945 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/block/mmcblk0p1 1 1868 15004678+ c Win95 FAT32 (LB
A)
/dev/block/mmcblk0p2 1869 1931 500173 83 Linux
/dev/block/mmcblk0p3 1931 1946 125453 82 Linux swap
Anybody know how to fix this?
Click to expand...
Click to collapse
So I think I found the problem and, possibly, the solution.
I noticed on my internal SD card that there is a swap parititon that wasn't being used, as confirmed by 'free' in ADB. Swap shouldn't be there so I deleted it Reflashed, hoping it would recreate the internal partitioning to right size. Nope, same issue.
Deleted the linux partition (mmcblk0p2) hoping that during the reflash it would recreate it. Nope, almost bricked the phone until I discovered that ADB is available in recovery.
Re-created said partition with remaining space, I now have ~360MB of "internal storage". So it would appear that the internal card is partitioned wrong.
Could the helpful person from before, go into ADB shell and run fdisk -l /dev/block/mmcblk0 and post the results so I can see what I should have for unit numbers?
Thanks!

[Solved] /efs partition gone

Hello, [Solution lower in this thread]
My /EFS partition is gone. I dont know why, because I wasnt doing anything with my phone at that moment. Until this problem I was running cyanogenmod nightly. The battery was wasted I think because it feels slightly thicker than normal. I already replaced it.
I have an efs.img made with SA manager.
Symptoms:
Bootloop
Original recovery says:
Code:
E: failed to mount /efs (invalid argument)
I can get into recovery & download mode.
I can still flash philz custom recovery.
When in cwm I can still flash a zip with a rom, but it wont start.
These are the steps I tried to get my phone working again:
ODIN
Flashed stock jellybean with original pit file, and checked "clear efs" in odin 3.09.
Custom Recovery
Connected with ADB, and executed the following commands:
Code:
But as you can see that doesnt help much.
I tried several other things, but they boil down to the same. I used an aroma efs restore tool, but it just executes the dd command and fails the same way.
jogai said:
Hello,
My /EFS partition is gone. I dont know why, because I wasnt doing anything with my phone at that moment. Until this problem I was running cyanogenmod nightly. The battery was wasted I think because it feels slightly thicker than normal. I already replaced it.
I have an efs.img made with SA manager.
Symptoms:
Bootloop
Original recovery says:
Code:
E: failed to mount /efs (invalid argument)
I can get into recovery & download mode.
I can still flash philz custom recovery.
When in cwm I can still flash a zip with a rom, but it wont start.
These are the steps I tried to get my phone working again:
ODIN
Flashed stock jellybean with original pit file, and checked "clear efs" in odin 3.09.
Custom Recovery
Connected with ADB, and executed the following commands:
Code:
~ # mount
mount
rootfs on / type rootfs (rw)
tmpfs on /dev type tmpfs (rw,seclabel,nosuid,relatime,mode=755)
devpts on /dev/pts type devpts (rw,seclabel,relatime,mode=600)
proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,seclabel,relatime)
selinuxfs on /sys/fs/selinux type selinuxfs (rw,relatime)
tmpfs on /tmp type tmpfs (rw,seclabel,relatime)
tmpfs on /storage type tmpfs (rw,seclabel,relatime,mode=050,gid=1028)
tmpfs on /mnt/secure type tmpfs (rw,seclabel,relatime,mode=700)
tmpfs on /mnt/fuse type tmpfs (rw,seclabel,relatime,mode=775,gid=1000)
/dev/block/mmcblk0p7 on /cache type ext4 (rw,seclabel,relatime,user_xattr,barrier=1,journal_async_commit,data=ordered)
/dev/block/vold/259:3 on /storage/sdcard0 type vfat (rw,dirsync,nosuid,nodev,noexec,relatime,uid=1023,gid=1023,fmask=0007,dmask=0007,allow_uime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
~ # mke2fs /dev/block/mmcblk0p3
mke2fs /dev/block/mmcblk0p3
mke2fs 1.41.14 (22-Dec-2010)
Filesystem label=
OS type: Linux
Block size=1024 (log=0)
Fragment size=1024 (log=0)
Stride=0 blocks, Stripe width=0 blocks
160 inodes, 1280 blocks
64 blocks (5.00%) reserved for the super user
First data block=1
Maximum filesystem blocks=1310720
1 block group
8192 blocks per group, 8192 fragments per group
160 inodes per group
Writing inode tables: done
Writing superblocks and filesystem accounting information: done
This filesystem will be automatically checked every 27 mounts or
180 days, whichever comes first. Use tune2fs -c or -i to override.
~ # dd if=/storage/sdcard0/efs.img of=/dev/block/mmcblk0p3 bs=4096
dd if=/storage/sdcard0/efs.img of=/dev/block/mmcblk0p3 bs=4096
dd: writing '/dev/block/mmcblk0p3': No space left on device
321+0 records in
320+0 records out
1310720 bytes (1.3MB) copied, 0.035800 seconds, 34.9MB/s
~ # chown 1001:radio /efs/nv_data.bin
chown 1001:radio /efs/nv_data.bin
chown: /efs/nv_data.bin: No such file or directory
But as you can see that doesnt help much.
I tried several other things, but they boil down to the same. I used an aroma efs restore tool, but it just executes the dd command and fails the same way.
Click to expand...
Click to collapse
so hold on!
the dd is failing because the img file is larger than the partition
why?
https://github.com/CyanogenMod/andr...common/blob/cm-11.0/rootdir/fstab.smdk4210#L9
i dont have an exynos4 device, but it seems p1 is /efs. and you are flashing p3, wtf!!! its a miracle if the phone is not fully bricked!! also, was efs mounted while you dd'ed? that would have corrupted it! not to mention using chown on it.
seriously, please stop randomly touching things and be very sure of what you do next or you'll have an unrecoverable brick soon.
p2 and p3 seem to be the bootloaders:
https://gitlab.com/ameer1234567890/...part_layouts/raw/partlayout4nandroid.GT-N7000
so. have you tried rebooting the phone after this? do you still have recovery and download mode?
if so, you need to recover p3 somehow. google a method then ASK before doing anything.
go to recovery and adb shell to it.
use blockdev command to find out the sizes of partitions p1 p2 and p3.
compare it to the size of the alleged-efs.img file you have, which apparently may actually be anything but.
unmount everything from recovery, then you can just adb pull /dev/your/desired/partition.
(i havent seen this used anywhere in xda, but i use it all the time. easier than dd'ing)
get images of your current p1 p2 and p3.
check that p3 and alleged-efs.img match (except for size) to verify that p3 was actually overwritten.
check the contents of alleged-efs.img and verify that it actually is an efs partition image.
dont make any further changes, and post the result of EVERYTHING here
Yes. Can confirm p1 is EFS.
This is N7000 partition table print by parted.
Model: MMC VYL00M (sd/mmc)
Disk /dev/block/mmcblk0: 15.8GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Number Start End Size File system Name Flags
1 4194kB 25.2MB 21.0MB ext4 EFS
2 25.2MB 26.5MB 1311kB SBL1
3 27.3MB 28.6MB 1311kB SBL2
4 29.4MB 37.7MB 8389kB PARAM
5 37.7MB 46.1MB 8389kB KERNEL
6 46.1MB 54.5MB 8389kB RECOVERY
7 54.5MB 264MB 210MB ext4 CACHE
8 264MB 281MB 16.8MB MODEM
9 281MB 1174MB 893MB ext4 FACTORYFS
10 1174MB 3322MB 2147MB ext4 DATAFS
11 3322MB 15.2GB 11.9GB fat32 UMS
12 15.2GB 15.8GB 537MB ext4 HIDDEN
The efs backup image in my phone is about 20mb.
GL.
you havent answered my questions.
so. have you tried rebooting the phone after this? do you still have recovery and download mode?
go to recovery and adb shell to it.
use blockdev command to find out the EXACT sizes of partitions p1 p2 and p3.
or use any other command you want.
compare it to the EXACT size of the alleged-efs.img file you have.
apparently it might be a match for p1, which is good.
get images of your current p1 p2 and p3:
unmount everything from recovery, then you can just adb pull /dev/your/desired/partition.
(i havent seen this used anywhere in xda, but i use it all the time. easier than dd'ing)
this is another way to find the exact partition sizes by the way: looking at the image sizes
check that p3 and alleged-efs.img match (except for size) to verify that p3 was actually overwritten.
do you absolutely trust that your alleged-efs.img is a good efs backup? you can mount it read only in your linux pc and check the contents of it to verify that it actually is an efs partition image. or you can just be sure that it is the right image. or you can pm it to me and i can check that.
you can pm the 4 partition images so i can see whats going on.
i think the phone has two equal bootloader copies (because corruption means unrecoverable brick) and you borked one. that's why it might be still booting. we need to restore p3 asap. please google the subject and check my asumption if you can.
---------- Post added at 03:31 PM ---------- Previous post was at 02:35 PM ----------
of course if you are lazy you can just:
dd if=/storage/sdcard0/efs.img of=/dev/block/mmcblk0p1
or:
adb push your/pc/dir/efs.img /dev/block/mmcblk0p1
MAKE SURE that the efs partition is not mounted before doing those.
you dont need any kind of chown if the backup is ok.
you need to recover p3. it could be as simple as:
adb pull /dev/block/mmcblk0p2 sbl.img
adb push sbl.img /dev/block/mmcblk0p3
if the two copies are the same, BUT DONT DO ANYTHING UNTIL YOU ARE VERY SURE!
if you use, say, odin now, and the writing of p2 gets interrupted for any reason, there wont be p3 to boot! so device is bricked FOREVER. no recovery possible without JTAG. you need to fix this ASAP.
your first TO-DO: verify the assumption that p2 and p3 are supposed to be two bit-by-bit exact copies of the bootloader.
any rom that contains a bootloader is extremely dangerous to flash at this time. this includes stock.
Thanks for your concern!
I got my instructions from here: http://techbeasts.com/2013/11/29/how-to-restore-and-back-up-efs-data-on-samsung-galaxy-devices/
Thats why I was tring p3. The aroma backup tool did try the same partition.
I tried all this several times, and tried to odin flash several times. The phone is still not bricked and I still can get to download & recovery just fine.
I'm at work now, but will post my findings asap.
jogai said:
Thanks for your concern!
I got my instructions from here: http://techbeasts.com/2013/11/29/how-to-restore-and-back-up-efs-data-on-samsung-galaxy-devices/
Thats why I was tring p3. The aroma backup tool did try the same partition.
I tried all this several times, and tried to odin flash several times. The phone is still not bricked and I still can get to download & recovery just fine.
I'm at work now, but will post my findings asap.
Click to expand...
Click to collapse
I would try to restore efs first to see how it goes. I suspect SBL2 maybe not important!
forest1971 said:
I would try to restore efs first to see how it goes. I suspect SBL2 maybe not important!
Click to expand...
Click to collapse
SBL2 is probably the 2nd copy of the bootloader. if SBL1 gets damaged (eg: interrupted odin) the phone is bricked and unbrickable, except by taking it to a JTAG house.
if you are not going to reseach this, at least copy p2 over p3:
adb pull /dev/block/mmcblk0p2 sbl.img
adb push sbl.img /dev/block/mmcblk0p3
Code:
~ # dd if=/dev/block/mmcblk0p2 of=sdcard/sbl1.img
dd if=/dev/block/mmcblk0p2 of=sdcard/sbl1.img
2560+0 records in
2560+0 records out
1310720 bytes (1.3MB) copied, 0.400897 seconds, 3.1MB/s
~ # dd if=/dev/block/mmcblk0p3 of=sdcard/sbl3.img
dd if=/dev/block/mmcblk0p3 of=sdcard/sbl3.img
2560+0 records in
2560+0 records out
1310720 bytes (1.3MB) copied, 0.161615 seconds, 7.7MB/s
Result:
https://filetea.me/t1sxlmPdQ9xSe2qh94HX82wMQ
https://filetea.me/t1sVUTXpxrWQ2mRSIx600aCqg
Code:
~ # dd if=sdcard/efs.img of=/dev/block/mmcblk0p1
dd if=sdcard/efs.img of=/dev/block/mmcblk0p1
40960+0 records in
40960+0 records out
20971520 bytes (20.0MB) copied, 6.726656 seconds, 3.0MB/s
Seems to work!
Code:
~ # mkdir /efs
mkdir /efs
~ # busybox mount -w -t ext4 /dev/block/mmcblk0p1 /efs
busybox mount -w -t ext4 /dev/block/mmcblk0p1 /efs
I think its strange I had to make /efs, and after reboot its seems gone:
Code:
~ # mount
mount
rootfs on / type rootfs (rw)
tmpfs on /dev type tmpfs (rw,seclabel,nosuid,relatime,mode=755)
devpts on /dev/pts type devpts (rw,seclabel,relatime,mode=600)
proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,seclabel,relatime)
selinuxfs on /sys/fs/selinux type selinuxfs (rw,relatime)
tmpfs on /tmp type tmpfs (rw,seclabel,relatime)
tmpfs on /storage type tmpfs (rw,seclabel,relatime,mode=050,gid=1028)
tmpfs on /mnt/secure type tmpfs (rw,seclabel,relatime,mode=700)
tmpfs on /mnt/fuse type tmpfs (rw,seclabel,relatime,mode=775,gid=1000)
/dev/block/mmcblk0p7 on /cache type ext4 (rw,seclabel,relatime,user_xattr,barrier=1,journal_async_commit,data=ordered)
While in fstab.smdk4210:
Code:
# Android fstab file.
#<src> <mnt_point> <type> <mnt_flags and options> <fs_mgr_flags>
# The filesystem that contains the filesystem checker binary (typically /system) cannot
# specify MF_CHECK, and must come before any filesystems that do specify MF_CHECK
# data partition must be located at the bottom for supporting device encryption
/dev/block/mmcblk0p9 /system ext4 ro,noatime wait
/dev/block/mmcblk0p7 /cache ext4 noatime,nosuid,nodev,journal_async_commit,errors=panic wait,check_spo
/dev/block/mmcblk0p1 /efs ext4 noatime,nosuid,nodev,journal_async_commit,errors=panic wait,check_spo
/dev/block/mmcblk0p10 /data ext4 noatime,nosuid,nodev,discard,noauto_da_alloc,journal_async_commit,errors=panic wait,check_spo,encryptable=/efs/metadata
/dev/block/mmcblk0p12 /preload ext4 noatime,nosuid,nodev,journal_async_commit wait
# vold-managed volumes ("block device" is actually a sysfs devpath)
/devices/platform/dw_mmc/mmc_host/mmc0/mmc0 auto auto defaults voldmanaged=sdcard0:11,nonremovable,noemulatedsd
/devices/platform/s3c-sdhci.2/mmc_host/mmc1 auto auto defaults voldmanaged=sdcard1:auto
/devices/platform/s3c_otghcd/usb auto auto defaults voldmanaged=usbdisk0:auto
# recovery
/dev/block/mmcblk0p5 /boot emmc defaults recoveryonly
/dev/block/mmcblk0p6 /recovery emmc defaults recoveryonly
/dev/block/mmcblk0p8 /modem emmc defaults recoveryonly
Odin'd & working again!
Many thanks to everyone who wanted to help this dumbass out! Much appreciated!
I think its strange I had to make /efs, and after reboot its seems gone:
Code:
~ # mount
mount
rootfs on / type rootfs (rw)
Click to expand...
Click to collapse
/ is rootfs which is a special instance of tempfs (which is a ram drive). nothing you put in / will survive a reboot.

[Fixed] Stuck in twrp recovery splash screen

Heya everyone,
I have rooted my XZ1 Compac quite a long time ago. Today I wanted to flash a new lineageos version. I booted into twrp, wiped cache,system,dalvik and data, and rebooted my phone because I forgot to put an additional zip on my sdcard. My intention was to remove the sdcard, add the file from my computer and flash the os+zips.
However now it is stuck in the twrp splash screen (with the red led burning). I am able to connect with adb, but rebooting in either bootloader or fastboot does nothing different. Fastboot is unable to connect.
Any ideas on how to fix this?
Edit; additional info: The bootloader still complains about being unlocked (as usual)...
Edit2: Adb reports:
13:34:10 in ~ [10009]
➜ adb devices
List of devices attached
BH904A5B9E recovery
Edit 3:
I also noticed I don't seem to have an recovery partition...
lilac:/ # df -h
Filesystem Size Used Avail Use% Mounted on
tmpfs 1.8G 1.0M 1.8G 1% /dev
tmpfs 1.8G 0 1.8G 0% /mnt
tmpfs 1.8G 0 1.8G 0% /apex
tmpfs 1.8G 4.0K 1.8G 1% /linkerconfig
tmpfs 1.8G 20K 1.8G 1% /tmp
/dev/block/sda53 352M 436K 352M 1% /cache
/dev/block/sda66 22G 79M 22G 1% /data
/dev/block/sda64 1.4G 4.5M 1.4G 1% /v
/dev/block/sda65 4.7G 20M 4.7G 1% /s
lilac:/ # mount
rootfs on / type rootfs (rw,seclabel)
tmpfs on /dev type tmpfs (rw,seclabel,nosuid,relatime,size=1889256k,nr_inodes=472314,mode=755)
devpts on /dev/pts type devpts (rw,seclabel,relatime,mode=600)
proc on /proc type proc (rw,relatime,gid=3009,hidepid=2)
sysfs on /sys type sysfs (rw,seclabel,relatime)
selinuxfs on /sys/fs/selinux type selinuxfs (rw,relatime)
tmpfs on /mnt type tmpfs (rw,seclabel,nosuid,nodev,noexec,relatime,size=1889256k,nr_inodes=472314,mode=755,gid=1000)
tmpfs on /apex type tmpfs (rw,seclabel,nosuid,nodev,noexec,relatime,size=1889256k,nr_inodes=472314,mode=755)
tmpfs on /linkerconfig type tmpfs (rw,seclabel,nosuid,nodev,noexec,relatime,size=1889256k,nr_inodes=472314,mode=755)
tmpfs on /mnt/installer type tmpfs (rw,seclabel,nosuid,nodev,noexec,relatime,size=1889256k,nr_inodes=472314,mode=755
,gid=1000)
tmpfs on /mnt/androidwritable type tmpfs (rw,seclabel,nosuid,nodev,noexec,relatime,size=1889256k,nr_inodes=472314,mo
de=755,gid=1000)
none on /sys/fs/cgroup type cgroup2 (rw,nosuid,nodev,noexec,relatime)
none on /dev/cpuctl type cgroup (rw,nosuid,nodev,noexec,relatime,cpu)
none on /dev/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset,noprefix,release_agent=/sbin/cpuset_release_agent)
none on /dev/memcg type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
none on /dev/stune type cgroup (rw,nosuid,nodev,noexec,relatime,schedtune)
none on /acct type cgroup (rw,relatime,cpuacct)
tmpfs on /tmp type tmpfs (rw,seclabel,relatime,size=1889256k,nr_inodes=472314)
pstore on /sys/fs/pstore type pstore (rw,seclabel,relatime)
none on /config type configfs (rw,relatime)
adb on /dev/usb-ffs/adb type functionfs (rw,relatime)
/dev/block/sda53 on /cache type ext4 (rw,seclabel,nosuid,nodev,noatime,noauto_da_alloc,data=ordered)
/dev/block/sda66 on /data type ext4 (rw,seclabel,nosuid,nodev,noatime,noauto_da_alloc,data=ordered)
/dev/block/sda64 on /v type ext4 (ro,seclabel,relatime,data=ordered)
/dev/block/sda65 on /s type ext4 (ro,seclabel,relatime,data=ordered)
lilac:/ # cd /dev/block/by-name/
lilac:/dev/block/by-name # ls
FOTAKernel boot devinfo hypbak modemst2 sda system vbmeta
LTALabel cache diag keymaster msadp sdb toolsfv vendor
Qnovo cmnlib dpo keymasterbak oem sdc tz xbl
TA cmnlib64 dsp keystore persist sec tzbak xblbak
abl cmnlib64bak frp limits pmic splash tzxfl xfl
ablbak cmnlibbak fsc logfs pmicbak ssd tzxflattest xflbak
apdp ddr fsg misc rdimage sti tzxflattestbak xflkeystore
appslog devcfg fsmetadata modem rpm storsec tzxflbak xflkeystorebak
bluetooth devcfgbak hyp modemst1 rpmbak storsecbak userdata
And twrp does not want to start:
lilac:/dev/block/by-name # twrp fixperms
TWRP does not appear to be running. Waiting for TWRP to start . . .
Fixed by doing:
adb push twrp.img /dev/block/bootdevice/by-name/FOTAKernel

Categories

Resources