View Single Post
Old 03-09-2012, 02:51 PM   #74
murz_07
Connoisseur
murz_07 began at the beginning.
 
Posts: 67
Karma: 10
Join Date: Feb 2012
Device: Kindle Touch SO
Quote:
Originally Posted by geekmaster View Post
As mentioned in other posts, RUNME.sh is launched by a custom /var/local/mntus.params script.

If you erase /var/local by copying /dev/zero to /dev/mmcblk0p3, you must reinstall my custom /var/local/mntus.params using my data.tar.gz you can download in my SelectBoot first post. Did you do that? If not, do it -- drop my data.tar.gz on your USB drive, then reboot to reinstall mntus.params, then reboot AGAIN so it will run. When it runs, it looks for /mnt/us/RUNME.sh and *no* RUNME.done file.

Remember, to write /dev/mmcblk0p1, you should boot diags, so be sure to have an ENABLE_DIAGS file along with the RUNME.sh.

You say that you did "data.tar.gz" but there are many variations. Did you use the one from my "SelectBoot" first post? If so, did you make sure there is NO RUNME.done file? Because my mntus.params creates RUNME.done just before running RUNME.sh, to prevent calling it multiple times, RUNME.sh can only run once, until RUNME.done is deleted.

If your main linux kernel is damaged, you need to boot to diags mode, and you might need MfgTool to do that. After the above steps, try booting diags using MfgTool.

So.. verify that you installed MY data.tar.gz and not one of the many others available. Then after TWO reboots look for RUNME.done on your USB drive. This MUST work unless both main and diags partitions are damaged or your main or diags kernels are damaged.

You can ALWAYS recover by booting to fastboot with MfgTool, and flashing the diags kernel and the diags partition (if both damaged) and then booting diags with MfgTool and running SSH or RUNME,sh with linux commands to fix the main system partition. The only way this cannot work is if you are flashing bad image copies, or if you have hardware problems.

At this time, unplugging a kindle USB port, or rebooting the host PC, makes it drop out of fastboot mode (although it identifies as a fastboot device, it sits at the bist> prompt on the serial port)). To use both MfgTool and fastboot, you need to run one of the Operating Systems in VIrtualBox and pass the kindle USB device through to the VM, or you need to run coLinux (but I have not tried coLinux USB support yet). We are working on getting a windows version of fastboot running so you can stay completely in windows, and a working linux sb_loader so you can stay completely in linux, with no need for both operating systems.
dmesg.log:
Code:
*** Thu Jan  1 00:00:03 UTC 1970 ***
*** export ***
export HOME='/'
export OLDPWD='/dev'
export PATH='/sbin:/bin:/usr/sbin:/usr/bin'
export PWD='/mnt/us'
export SHELL='/bin/sh'
export TERM='vt102'
export USER='root'
export VERBOSE='no'
export eink='fslepdc'
export prevlevel='N'
export runlevel='S'
*** idme ***
serial: B011
accel: 
mac: 28
mfg: CQ
pcbsn: 00614
config: 
bootmode: main
postmode: normal
*** df ***
Filesystem                Size      Used Available Use% Mounted on
/dev/root                62.2M     53.4M      5.7M  90% /
tmpfs                   124.9M      4.0K    124.9M   0% /dev
tmpfs                   124.9M         0    124.9M   0% /dev/shm
/dev/mmcblk0p3           31.0M     10.3M     19.1M  35% /var/local
/dev/loop/0               3.3G    648.8M      2.6G  19% /mnt/us
*** mount ***
rootfs on / type rootfs (rw)
/dev/root on / type ext3 (ro,noatime,nodiratime,data=writeback)
proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,relatime)
tmpfs on /dev type tmpfs (rw,relatime,mode=755)
tmpfs on /dev/shm type tmpfs (rw,relatime)
devpts on /dev/pts type devpts (rw,relatime,gid=5,mode=620)
tmpfs on /var type tmpfs (rw,relatime,size=0k)
/dev/mmcblk0p3 on /var/local type ext3 (rw,relatime,errors=continue,data=writeback)
/dev/loop/0 on /mnt/us type vfat (rw,noatime,nodiratime,fmask=0022,dmask=0022,codepage=cp437,iocharset=iso8859-1,errors=remount-ro)
*** /etc ***
drwxrwxr-x   14 root     root          1024 Jan  1  1970 .
drwxr-xr-x   14 root     root          1024 Jan  1  1970 ..
-rw-r--r--    1 root     root             4 Nov  9  2011 TZ
-rw-r--r--    1 root     root           199 Nov  9  2011 asound.conf
-rw-r--r--    1 root     root          1117 Nov  9  2011 asound.state
-rw-r--r--    1 root     root           100 Jan  1  1970 blkid.tab
drwxrwxr-x    2 root     root          1024 Nov  9  2011 default
-rw-r--r--    1 root     root          1175 Jan  1  1970 fstab
-rw-r--r--    1 root     root           746 Nov  9  2011 getty-diags
-rw-r--r--    1 root     root           272 Nov  9  2011 group
-rw-r--r--    1 root     root            33 Jan  1  1970 guid
-rw-r--r--    1 root     root             7 Nov  9  2011 hostname
-rw-r--r--    1 root     root            80 Nov  9  2011 hosts
drwxrwxr-x    2 root     root          1024 Nov  9  2011 init
drwxrwxr-x    2 root     root          1024 Nov  9  2011 init.d
-rw-r--r--    1 root     root           830 Nov  9  2011 inittab
-rw-r--r--    1 root     root          1180 Nov  9  2011 inputrc
-rw-r--r--    1 root     root            22 Nov  9  2011 issue
lrwxrwxrwx    1 root     root            18 Jan  1  1970 kdb -> /etc/kdb.src/yoshi
drwxrwxr-x    3 root     root          1024 Nov  9  2011 kdb.src
lrwxrwxrwx    1 root     root            29 Nov  9  2011 ld.so.cache -> /var/local/system/ld.so.cache
-rw-r--r--    1 root     root            14 Nov  9  2011 ld.so.conf
lrwxrwxrwx    1 root     root            20 Nov  9  2011 localtime -> /var/local/system/tz
-rw-r--r--    1 root     root          1035 Nov  9  2011 modprobe.conf
-rw-r--r--    1 root     root             5 Nov  9  2011 modules.conf
-rw-r--r--    1 root     root           106 Nov  9  2011 modules.yoshi
-rw-r--r--    1 root     root           285 Nov  9  2011 motd
lrwxrwxrwx    1 root     root            12 Nov  9  2011 mtab -> /proc/mounts
-rw-r--r--    1 root     root           429 Nov  9  2011 passwd
drwxrwxr-x    4 root     root          1024 Nov  9  2011 ppp
-rw-r--r--    1 root     root            22 Nov  9  2011 prettyversion.txt
-rw-r--r--    1 root     root           563 Nov  9  2011 profile
-rw-r--r--    1 root     root          1191 Nov  9  2011 protocols
-rw-r--r--    1 root     root           512 Nov  9  2011 random-seed
drwxrwxr-x    2 root     root          1024 Nov  9  2011 rc.d
drwxrwxr-x    2 root     root          1024 Nov  9  2011 rcS.d
lrwxrwxrwx    1 root     root            20 Nov  9  2011 resolv.conf -> /var/run/resolv.conf
drwxrwxr-x    2 root     root          1024 Nov  9  2011 resolv.d
-rw-r--r--    1 root     root           346 Jan  1  1970 shadow
-rw-r--r--    1 root     root           371 Nov  9  2011 shadow-
drwxrwxr-x    2 root     root          1024 Nov  9  2011 sysconfig
drwxrwxr-x    2 root     root          1024 Nov  9  2011 syslog-ng
-rw-r--r--    1 root     root           616 Nov  9  2011 tinyrot-files.conf
-rw-r--r--    1 root     root           867 Nov  9  2011 tinyrot.conf
drwxrwxr-x    3 root     root          1024 Nov  9  2011 udev
drwxrwxr-x    2 root     root          1024 Nov  9  2011 upstart
-rw-rw-r--    1 root     root            81 Nov  9  2011 version.txt
lrwxrwxrwx    1 root     root            20 Jan  1  1970 xorg.conf -> /var/local/xorg.conf
*** /etc/upstart ***
drwxrwxr-x    2 root     root          1024 Nov  9  2011 .
drwxrwxr-x   14 root     root          1024 Jan  1  1970 ..
-rwxr-xr-x    1 root     root          3499 Nov  9  2011 battery-diags
-rwxr-xr-x    1 root     root          9175 Nov  9  2011 bundlefuncs
-rwxr-xr-x    1 root     root          9333 Nov  9  2011 diags
-rwxr-xr-x    1 root     root          9652 Nov  9  2011 display
-rwxr-xr-x    1 root     root          2291 Nov  9  2011 firsttime
-rwxr-xr-x    1 root     root          2493 Nov  9  2011 framework
-rw-r--r--    1 root     root          8688 Nov  9  2011 functions
-rwxr-xr-x    1 root     root          1189 Nov  9  2011 init.sh
-rwxr-xr-x    1 root     root          8767 Nov  9  2011 makexconfig
-rwxr-xr-x    1 root     root          2557 Nov  9  2011 poll_daemons
-rwxr-xr-x    1 root     root          1608 Nov  9  2011 prereg
-rwxr-xr-x    1 root     root          5374 Nov  9  2011 userstore
-rwxr-xr-x    1 root     root          1746 Nov  9  2011 wan
-rwxr-xr-x    1 root     root          2117 Nov  9  2011 zforce
*** /usr/local ***
drwxrwxr-x    3 root     root          1024 Nov  9  2011 .
drwxrwxr-x    8 root     root          1024 Nov  9  2011 ..
drwxrwxr-x    2 root     root          1024 Nov  9  2011 bin
*** /usr/local/bin ***
drwxrwxr-x    2 root     root          1024 Nov  9  2011 .
drwxrwxr-x    3 root     root          1024 Nov  9  2011 ..
lrwxrwxrwx    1 root     root            28 Nov  9  2011 dbclient -> /usr/local/bin/dropbearmulti
lrwxrwxrwx    1 root     root            28 Nov  9  2011 dropbearconvert -> /usr/local/bin/dropbearmulti
lrwxrwxrwx    1 root     root            28 Nov  9  2011 dropbearkey -> /usr/local/bin/dropbearmulti
lrwxrwxrwx    1 root     root            28 Nov  9  2011 scp -> /usr/local/bin/dropbearmulti
-rwxr-xr-x    1 root     root          2771 Nov  9  2011 usbnetwork
-rwxr-xr-x    1 root     root          7180 Nov  9  2011 zforcediag
*** /usr/local/sbin ***
*** /var/local ***
drwxr-xr-x   11 default  default       1024 Feb 24  2012 .
drwxrwxr-x    9 root     root           180 Jan  1 00:00 ..
-rw-r--r--    1 root     root         77824 Aug  1  2011 appreg.db
drwxr-xr-x    2 root     root          1024 Aug  1  2011 audio
drwx------    3 root     root          1024 Aug  1  2011 blanket
-rw-r--r--    1 root     root         37888 Aug  1  2011 cc.db
drwxr-xr-x    4 root     root          1024 Aug  1  2011 eink
drwxr-xr-x    5 root     root          1024 Aug  1  2011 java
drwxr-xr-x    2 root     root          1024 Jan  1 00:08 log
drwxr-xr-x    4 root     root          1024 Aug  1  2011 purchase
drwxrwxr-x    2 root     root          1024 Aug  1  2011 reg
drwxr-xr-x    2 default  default       1024 Jan  1 00:07 system
drwxrwxr-x   13 root     root          1024 Aug  1  2011 waf
-rw-r--r--    1 root     root          1990 Aug  1  2011 xorg.conf
*** /var/local/wan ***
*** /var/local/system ***
drwxr-xr-x    2 default  default       1024 Jan  1 00:07 .
drwxr-xr-x   11 default  default       1024 Feb 24  2012 ..
-rw-r--r--    1 root     root             0 Aug  1  2011 factory_fresh
-rw-r--r--    1 root     root           160 Nov 10  2011 hid.csv
-rw-r--r--    1 root     root           375 Aug  1  2011 keyboard.conf
-rw-r--r--    1 root     root         36588 Aug  1  2011 ld.so.cache
-rw-r--r--    1 root     root           316 Jan 17  2012 locale
-rw-r--r--    1 root     root             0 Aug  1  2011 localvar_firstboot
-rwxr-xr-x    1 default  default       1147 Feb 24  2012 mntus.params
-rw-r--r--    1 root     root             2 Jan  1 00:00 vfat_bootup
-rw-r--r--    1 root     root           132 Aug  1  2011 wifid.conf
-rw-r--r--    1 root     root             1 Aug  1  2011 wireless_enable
*** /mnt/us ***
drwxr-xr-x    9 root     root          8192 Jan  1 00:00 .
drwxrwxr-x    9 root     root          1024 Jan  1  1970 ..
-rwxr-xr-x    1 root     root             0 Jan  1 00:00 RUNME.done
-rwxr-xr-x    1 root     root            93 Jan  1 00:00 RUNME.out
-rwxr-xr-x    1 root     root           168 Jan  1  1980 USBnet.xml
drwxr-xr-x    2 root     root          8192 Aug  1  2011 audible
drwxr-xr-x    2 root     root          8192 Feb 22  2012 bak
-rwxr-xr-x    1 root     root           796 Feb 24  2012 data.tar.gz
drwxr-xr-x    2 root     root          8192 Jan  1  1980 diagnostic_logs
drwxr-xr-x    4 root     root         16384 Aug  1  2011 documents
-rwxr-xr-x    1 root     root          8502 Jan  1 00:00 gmdiags.log
drwxr-xr-x    2 root     root          8192 Aug  1  2011 music
-rwxr-xr-x    1 root     root          1343 Feb 24  2012 runme.sh
drwxr-xr-x    5 root     root          8192 Aug  1  2011 system
drwxr-xr-x    4 root     root          8192 Jan  1  1980 tts
system: I mntroot:def:Making root filesystem writeable
*** /var/local/system/mntus.params ***
MNTUS_PART_START=16
MNTUS_PART_OFFSET=8192
MNTUS_FATSIZE=32

## use actual size from fdisk (minus 8KB offset):
let MNTUS_PART_SIZE="`fdisk -l|grep FAT32|awk '{print $4}'`-8"

## if invalid size (normal during main boot),
## then use known size for each serial number:
if [ $MNTUS_PART_SIZE -lt 1000000 ]; then
  SER4=`grep Serial /proc/cpuinfo|cut -b12-15`
  case $SER4 in
  "B004"|"B005"       ) MNTUS_PART_SIZE=3567224 ;; # DX
  "B006"|"B008"|"B00A") MNTUS_PART_SIZE=3205336 ;; # K3
  "B009"              ) MNTUS_PART_SIZE=3510232 ;; # DXG
  "B00E"              ) MNTUS_PART_SIZE=1423352 ;; # K4 (mini)
  "B00F"|"B011"       ) MNTUS_PART_SIZE=3377144 ;; # K5 (touch)
  *)
    ## unknown size, exit may erase USB Drive!
    eips -c
    eips  5 28 "This $SER4 Kindle is not supported..."
    eips 10 30 "(${MNTUS_PART_SIZE}KB USB Drive)"
    eips  7 32 "Removing installer files..."
    sleep 8
    ;;                   
  esac
fi

mount -o rw,noatime,nodiratime,offset=8192 /dev/mmcblk0p4 /mnt/us
[ -f /mnt/us/RUNME.sh -a ! -f /mnt/us/RUNME.done ] && (
  touch /mnt/us/RUNME.done
  sh /mnt/us/RUNME.sh 2>&1 >/mnt/us/RUNME.out
)
umount -d /mnt/us
system: I mntroot:def:Making root filesystem read-only
drwxr-xr-x    2 default  default       1024 Jan  1 00:07 .
drwxr-xr-x   11 default  default       1024 Feb 24  2012 ..
-rw-r--r--    1 root     root             0 Aug  1  2011 factory_fresh
-rw-r--r--    1 root     root           160 Nov 10  2011 hid.csv
-rw-r--r--    1 root     root           375 Aug  1  2011 keyboard.conf
-rw-r--r--    1 root     root         36588 Aug  1  2011 ld.so.cache
-rw-r--r--    1 root     root           316 Jan 17  2012 locale
-rw-r--r--    1 root     root             0 Aug  1  2011 localvar_firstboot
-rwxr-xr-x    1 default  default       1147 Feb 24  2012 mntus.params
-rw-r--r--    1 root     root             2 Jan  1 00:00 vfat_bootup
-rw-r--r--    1 root     root           132 Aug  1  2011 wifid.conf
-rw-r--r--    1 root     root             1 Aug  1  2011 wireless_enable
*** DONE. ***
*** Thu Jan  1 00:00:04 UTC 1970 ***
**************************
murz_07 is offline   Reply With Quote