Forum

You must be logged in to post Login Register

Search 
Search Forums:


 




Input/output error trying to dd Android /dev/block devices

UserPost

4:07 pm
February 25, 2009


ahoog

Admin

Chicago, IL

posts 12

1

Post edited 1:05 pm – February 26, 2009 by ahoog


I'm trying to grab a dd image of any block device on an Android (G1) phone.  What I have done so far is to access the G1 using adb shell:

root@wintermute:/home/ahoog# /home/ahoog/src/android-sdk-linux_x86-1.0_r2/tools/adb shell

and then try to use /system/bin/dd or the busybox dd (at /data/busybox/dd) to image one of the block devices.  From mount you can see several:


# mount
rootfs on / type rootfs (ro)
tmpfs on /dev type tmpfs (rw,mode=755)
devpts on /dev/pts type devpts (rw,mode=600)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
tmpfs on /sqlite_stmt_journals type tmpfs (rw,size=4096k)
/dev/block/mtdblock3 on /system type yaffs2 (ro)
/dev/block/loop0 on /system/modules type cramfs (ro)
/dev/block/loop1 on /system/xbin type cramfs (ro)
/dev/block/mtdblock5 on /data type yaffs2 (rw,nosuid,nodev)
/dev/block/mtdblock4 on /cache type yaffs2 (rw,nosuid,nodev)
/dev/block/mmcblk0p1 on /sdcard type vfat (rw, dirsync, nosuid, nodev, noexec, uid=1000, gid=1000, fmask=0711, dmask=0700, codepage=cp437, iocharset=iso8859-1, utf8)

I chose /cache as it is small.  So I ran:

# dd if=/dev/block/mtdblock4 of=/sdcard/mtdblock4.dd

And in with both dd's it failed with:

dd: /dev/block/mtdblock4: Input/output error

dmesg output said:

<4>[ 3292.088103] msm_nand_read_oob: unsupported ops->len, 512
<3>[ 3292.088613] end_request: I/O error, dev mtdblock4, sector 0
<3>[ 3292.089436] Buffer I/O error on device mtdblock4, logical block 0
<4>[ 3292.089955] msm_nand_read_oob: unsupported ops->len, 512
<3>[ 3292.090779] end_request: I/O error, dev mtdblock4, sector 8
<3>[ 3292.091237] Buffer I/O error on device mtdblock4, logical block 1
<4>[ 3292.092061] msm_nand_read_oob: unsupported ops->len, 512
<3>[ 3292.092488] end_request: I/O error, dev mtdblock4, sector 16
<3>[ 3292.093282] Buffer I/O error on device mtdblock4, logical block 2
<4>[ 3292.093739] msm_nand_read_oob: unsupported ops->len, 512
<3>[ 3292.094533] end_request: I/O error, dev mtdblock4, sector 24
<3>[ 3292.094960] Buffer I/O error on device mtdblock4, logical block 3
<4>[ 3292.096272] msm_nand_read_oob: unsupported ops->len, 512
<3>[ 3292.096730] end_request: I/O error, dev mtdblock4, sector 0
<3>[ 3292.097554] Buffer I/O error on device mtdblock4, logical block 0

Any recommendations?


11:52 am
March 16, 2009


ahoog

Admin

Chicago, IL

posts 12

2

Post edited 4:53 pm – March 16, 2009 by ahoog
Post edited 4:53 pm – March 16, 2009 by ahoog


With some help from g1-hackers, the solution is to use the devices in /dev/mtd/ instead.  So, something along the lines of:


dd if=/dev/mtd/mtd4 of=/sdcard/mtd4.dd bs=4096


worked just fine. A quick look at the YAFFS2 file system revealed something interesting…I wrote about it at:


http://chicago-ediscovery.com/…..silly.html


-Andrew Hoog

Search 

About the viaForensics forum

Most Users Ever Online:

21


Currently Online:

1 Guest

Forum Stats:

Groups: 1

Forums: 2

Topics: 9

Posts: 27

Membership:

There are 293 Members

There has been 1 Guest

There is 1 Admin

There are 0 Moderators

Top Posters:

Stuck CAPS – 4

CHickman – 3

minpostbox03 – 3

cristyb7 – 1

kurt38 – 1

aobama52 – 1

Administrators: ahoog (12 Posts)