View Single Post
Old 06-29-2016, 10:39 AM   #5
eschwartz
Ex-Helpdesk Junkie
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
Some relevant logs from IRC (Thursday, June 23):

Spoiler:
Quote:
1:08:53 PM - damon12: hi. I may have broken eMMC in my Kindle Paperwhite 3, just curious if anyone has Kindle Paperwhite 3 partition dump for share
1:09:23 PM - damon12: million thanks
1:09:59 PM - staphoent: i have a pw3, wouldnt have a clue how to share that though
1:11:07 PM - Glorfindel is now known as Glorfindel-gone.
1:12:32 PM - damon12: If it is jail-broken and has usbnet installed, you may access it by SSH, dump the partition by dd and save to /mnt/us, then use scp to copy
1:14:05 PM - damon12: If it is not jail-broken but you have TTL, you may boot into DIAGS mode, use dd to dump to mnt/us, then boot back to main mode and copy by usb cable
1:14:26 PM - staphoent: lol it is jail-broken, has usb net installed, dont know how to access by ssh, dont know how to dump by dd or use scp
1:16:02 PM - damon12: let me write a quick tutorial
1:16:16 PM - staphoent: go ahead
1:17:43 PM - damon12: forgot it is already written here
1:17:43 PM - damon12: https://wiki.mobileread.com/wiki/Kind...USB_Networking
1:18:00 PM - damon12: are you using Linux or Mac or Windows?
1:18:23 PM - staphoent: mac
1:18:38 PM - staphoent: i already have usb networking up and running
1:19:39 PM - damon12: does "ssh root@192.168.15.244" in terminal show something?
1:20:51 PM - damon12: password is either blank or "mario" (without quotes)
1:21:30 PM - staphoent: i have it set up to this stage= [root@kindle /]#
1:21:50 PM - damon12: then please type this
1:22:01 PM - damon12: dd /dev/mmcblk0p1 /mnt/us/p1.img
1:22:09 PM - damon12: it may takes a while
1:22:47 PM - staphoent: just gives me a list of options
1:23:38 PM - staphoent: [root@kindle /]# dd /dev/mmcblk0p1 /mnt/us/p1.img BusyBox v1.17.1 (2016-04-17 11:24:55 PDT) multi-call binary. Usage: dd [if=FILE] [of=FILE] [bs=N] [count=N] [skip=N] [seek=N] Copy a file with converting and formatting Options: if=FILE Read from FILE instead of stdin of=FILE Write to FILE instead of stdout bs=N Read and write N bytes at a time count=N Co
1:24:29 PM - damon12: sorry, my bad
1:24:40 PM - damon12: should be this
1:24:40 PM - damon12: dd if=/dev/mmcblk0p1 of=/mnt/us/p1.img
1:25:10 PM - damon12: after this one is finished, then please run these two also
1:25:14 PM - damon12: dd if=/dev/mmcblk0p2 of=/mnt/us/p2.img
1:25:17 PM - damon12: dd if=/dev/mmcblk0p3 of=/mnt/us/p3.img
1:26:08 PM - damon12: One remindar, I assume you have at least 700M free space.
1:26:28 PM - damon12: For new Kindle, it should be around 2G free
1:28:41 PM - damon12: After all commands have been finished, please enter "exit" to quit ssh
1:29:23 PM - staphoent: how can i check my space through usb networking
1:29:30 PM - staphoent: as i do have a lot of files on there
1:30:22 PM - damon12: you may "cd /mnt/us", then "df -h ."
1:31:04 PM - damon12: It should show you how many space left (hopefully my memory is correct)
1:34:04 PM - staphoent: i guess im looking at mnt/base-us?
1:35:30 PM - damon12: would you copy what you see when running "mount"
1:35:56 PM - damon12: sorry, my PW3 is broken and I can't confirm if it should be "mnt/base-us" or "mnt/us"
1:36:11 PM - damon12: "mount" should give me some hints
1:36:32 PM - staphoent: [root@kindle /]# cd /mnt/us [root@kindle us]# df -h Filesystem Size Used Available Use% Mounted on /dev/root 437.4M 314.8M 100.6M 76% / tmpfs 251.4M 100.0K 251.3M 0% /dev tmpfs 251.4M 0 251.4M 0% /dev/shm tmpfs 32.0M 1.8M 30.2M 6% /var /dev/loop/2 2.5M 2.5M 0 100% /usr/share/X11
1:38:58 PM - damon12: does "df -h ." work?
1:39:04 PM - damon12: (there is a dot at the end)
1:40:33 PM - staphoent: it says use 31%
1:40:36 PM - staphoent: should be fine then
1:41:17 PM - staphoent: want me to run those commands u sent me?
1:41:40 PM - damon12: yes, please
1:42:14 PM - staphoent: ran first one but nothing happening atm
1:42:49 PM - damon12: so it finished in a few seconds?
1:42:58 PM - staphoent: no jsut displayed a blank line
1:43:47 PM - damon12: does it show the prompt "[root@kindle us]" under the command you type?
1:43:54 PM - staphoent: no
1:44:02 PM - staphoent: not responding to anything with that
1:44:03 PM - damon12: then it is running, be patient
1:44:31 PM - staphoent: [root@kindle /]# dd if=/dev/mmcblk0p1 of=/mnt/us/p1.img
1:44:38 PM - staphoent: then two blank lines
1:45:24 PM - damon12: the first file will be around 500M, so it takes some times
1:45:41 PM - damon12: the second and third will be much smaller
1:45:44 PM - staphoent: how did you break your emmc?
1:46:44 PM - damon12: not sure, I SSHed my kindle and install some programs, change boot logo and try to add custom language. Then after restart, it can't open any books
1:47:01 PM - staphoent: lol
1:47:14 PM - staphoent: are you tempted by the oasis?
1:47:53 PM - damon12: and usbnet never start again, so I use TTL to "fix" it
1:48:08 PM - staphoent: 921600+0 records in 921600+0 records out 471859200 bytes (450.0MB) copied, 351.452832 seconds, 1.3MB/s
1:48:38 PM - damon12: after some trials, it stucks at bootloader and said cannot access the flash chip
1:48:45 PM - staphoent: thats annoying
1:48:49 PM - staphoent: run the second ?
1:49:04 PM - damon12: yes please
1:49:21 PM - damon12: and my PW3 cannot enter fast boot mode too
1:49:35 PM - staphoent: ahh right, and these image files will fix that?
1:49:58 PM - staphoent: [root@kindle /]# dd if=/dev/mmcblk0p2 of=/mnt/us/p2.img 131072+0 records in 131072+0 records out 67108864 bytes (64.0MB) copied, 38.205392 seconds, 1.7MB/s [root@kindle /]#
1:50:20 PM - damon12: the file should be able to fix it if my flash chip is just corrupted.
1:50:28 PM - staphoent: ok
1:50:40 PM - damon12: but if it is physically damaged (e.g. electrostatic shock), I will need a new chip
1:50:41 PM - staphoent: do you know much about how the pw3 system works?
1:50:47 PM - damon12: but I need the files anyway
1:50:50 PM - staphoent: ok
1:50:57 PM - damon12: I am quite new to linux
1:51:03 PM - staphoent: ahh right
1:51:16 PM - damon12: only know it depends strongly on webkit and pillow
1:51:33 PM - staphoent: im trying desperately to disable the flash to black/update function on my pw3
1:51:37 PM - staphoent: but having a nightmare
1:51:43 PM - staphoent: all three have finished
1:52:08 PM - damon12: then please enter "exit"
1:52:17 PM - damon12: finally, these three
1:52:20 PM - damon12: scp root@192.168.15.244:/mnt/p1.img $HOME/Desktop/p1.img
1:52:29 PM - damon12: scp root@192.168.15.244:/mnt/p2.img $HOME/Desktop/p2.img
1:52:31 PM - damon12: scp root@192.168.15.244:/mnt/p3.img $HOME/Desktop/p3.img
1:52:52 PM - damon12: After all finished, you should see three files appear in your Deskop
1:53:01 PM - staphoent: port 22 conection refused
1:53:31 PM - damon12: are you under Terminal? (not ssh)
1:53:43 PM - staphoent: Users-Mac-mini:~ user$
1:55:40 PM - damon12: you are in the right place. but not sure why it shows error
1:55:49 PM - damon12: give me a few minutes
1:55:55 PM - staphoent: k
1:57:40 PM - damon12: just curious if you can connect the Kindle in "USB Mass Storage Mode"?
1:58:05 PM - damon12: (i.e. It appears as a flash drive in your Mac)
1:58:29 PM - staphoent: i can connect it as i normally do i.e to load pdfs through usb
1:58:36 PM - staphoent: but will that display the img files?
1:59:05 PM - damon12: yes, it should show that 3 files you just created
1:59:58 PM - staphoent: ok got them
2:00:58 PM - damon12: then please zip all of them in one file, and upload to any free file hosting site, and send me the link. Thank you for your help
2:01:11 PM - damon12: Btw, you may keep those files just in case your friends need them
2:01:59 PM - staphoent: can i use that dd thing to download the rest of the system files from my kindle?
2:02:07 PM - damon12: The img file will NOT contain any of your personal information (e.g. S/N etc), so it is safe to share it.
2:02:08 PM - staphoent: i really want to look at some of the configuration files
2:02:35 PM - damon12: p1.img and p2.img contains the system files
2:02:42 PM - damon12: you may play with it, but with care
2:02:57 PM - staphoent: as in configurations for the waveforms of the screen?
2:03:55 PM - damon12: p3.img is the file for rescue mode. I don't recommend touching it.
2:04:19 PM - damon12: yes, should be in p1 or p2
2:04:39 PM - staphoent: ok
2:04:49 PM - staphoent: its not letting me take p1 from thek indle
2:04:57 PM - staphoent: it says error 36 cannot be read
2:05:31 PM - damon12: oh....
2:06:04 PM - staphoent: how do i open/look inside these files
2:06:11 PM - damon12: what is the file size?
2:06:48 PM - damon12: you may mount it under Linux, I guess MacOSX should work too
2:06:59 PM - staphoent: 471.9
2:07:17 PM - damon12: Would you try copying again?
2:07:34 PM - staphoent: yeah i can try
2:07:41 PM - staphoent: its not letting memoun them in mac
2:08:05 PM - damon12: so all three files failed?
2:08:23 PM - staphoent: what i mean is, in kterm in my kindle i can find lots of configureation files under /mnt-us/proc
2:08:30 PM - staphoent: id like to look at them on my comp
2:08:30 PM - staphoent: no
2:08:34 PM - staphoent: just the first one
2:08:37 PM - staphoent: the other two i can copy
2:10:29 PM - damon12: sorry then we may need to create the first file again
2:10:32 PM - damon12: ssh root@192.168.15.244
2:10:36 PM - damon12: dd if=/dev/mmcblk0p1 of=/mnt/us/p1.img
2:10:48 PM - staphoent: it says [root@kindle kvncviewer]# dd if=/dev/mmcblk0p1 of=/mnt/us/p1.img dd: writing '/mnt/us/p1.img': Read-only file system 1+0 records in 0+0 records out 0 bytes (0B) copied, 0.118817 seconds, 0B/s [root@kindle kvncviewer]# dd if=/dev/mmcblk0p1 of=/mnt/us/p1.img dd: can't open '/mnt/us/p1.img': Stale file handle [root@kindle kvncviewer]#
2:11:10 PM - damon12: dd if=/dev/mmcblk0p1 of=/mnt/us/p1a.img
2:11:19 PM - damon12: this time let's call the file "p1a.img"
2:11:34 PM - damon12: probably MacOSX locked the file p1.img up
2:11:49 PM - staphoent: can you delete the last one from here, because i may not have enough space now
2:11:57 PM - damon12: ohh, yes
2:12:07 PM - damon12: you can delete p1.img, p2.img and p3.img
2:12:16 PM - damon12: since p1.img is broken, p2 and p3 already copied
2:12:23 PM - staphoent: well then i have to go back to usb storage mode
2:12:30 PM - staphoent: is there anyway to delete it through shh
2:12:36 PM - damon12: yes
2:12:49 PM - damon12: rm -rf /mnt/us/p1.img
2:13:05 PM - staphoent: rm: can't stat '/mnt/us/p1.img': Stale file handle
2:13:46 PM - staphoent: you know u can downlaod the whole firmware form amazons website
2:15:06 PM - damon12: it seems the p1.img has been deleted but Linux does not know
2:15:10 PM - damon12: It should be safe to proceed
2:15:29 PM - damon12: I guess those firmware from amazon contains updates only. Not complete image
2:15:46 PM - damon12: would you advise the link so I can have a look?
2:16:06 PM - staphoent: dd: can't open '/mnt/us/p1a.img': Stale file handle
2:16:31 PM - damon12: then you may need to run fsck under MacOSX
2:16:50 PM - damon12: to fix the possible filesystem problem
2:16:50 PM - staphoent: http://www.amazon.com/gp/help/custom...deId=200203720
2:16:52 PM - staphoent: a few pages down
2:16:58 PM - staphoent: filesystem problem?
2:17:30 PM - damon12: yes, FAT partition is easily corrupted
2:17:48 PM - damon12: yes, FAT partition can be easily corrupted
2:18:48 PM - damon12: Sorry that it is 2:18am now, I have to go bed and wish to see you soon.
2:19:24 PM - staphoent: is that a problem with my kindle?
2:19:31 PM - staphoent: or just the files u put on there
3:34:31 PM - eschwartz: damon12: The firmware update images contain the whole rootfs for the main system, but they don't contain the diags partition or the bootloader code.
3:35:08 PM - eschwartz: I see you found MadMAXXX's "Unbrick a PW3 (Fastboot)" thread.
3:35:46 PM - staphoent: i think hes sleeping lol
3:41:12 PM - eschwartz: So he will be able to catch up when he reconnects, no big deal.
3:41:46 PM - eschwartz: damon12 has a working uboot, according to the MobileRead thread.
3:41:56 PM - staphoent: ah cool
3:42:09 PM - eschwartz: So all he needs (I think) is a diags kernel + image
3:42:21 PM - staphoent: how do you stay logged when ur computers off?
3:42:35 PM - eschwartz: Then he can boot to that and flash the main rootfs.img extracted from a standard Amazon update.
3:42:46 PM - eschwartz: You don't have to turn your computer off.
3:42:57 PM - staphoent: are those the image files he was getting me to obtain?
3:42:58 PM - eschwartz: Or you can use a bouncer to keep you connected.
3:43:01 PM - staphoent: ahhh ok
3:43:09 PM - staphoent: got you
3:43:23 PM - eschwartz: mmcblk0p1 is rootfs.img so you can skip that, actually.
3:43:31 PM - staphoent: ok
3:43:36 PM - staphoent: ive got the other two
3:43:42 PM - staphoent: if he still needs them
3:44:03 PM - eschwartz: mmcblk0p2 should be the diags partition.



Particularly:

Quote:
1:45:44 PM - staphoent: how did you break your emmc?
1:46:44 PM - damon12: not sure, I SSHed my kindle and install some programs, change boot logo and try to add custom language. Then after restart, it can't open any books
1:47:53 PM - damon12: and usbnet never start again, so I use TTL to "fix" it
1:48:38 PM - damon12: after some trials, it stucks at bootloader and said cannot access the flash chip
Not that it matters how that partition got corrupted, of course.

...

@damon12,

staphoent is still hanging out on IRC, and he says he got the necessary partition image copied for you. But you haven't revisited there after asking...

Last edited by eschwartz; 06-29-2016 at 10:41 AM.
eschwartz is offline   Reply With Quote