Announcement

Collapse
No announcement yet.

M8 Square - BRICKED - or not - faulty partition table?

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

    M8 Square - BRICKED - or not - faulty partition table?

    Greetings guys, I've recently purchased M8 square box, which worked great, last month or two.
    From what I see, it is common squared M8, pcb v0.92:



    But recently, while I was watching movie from usb stick, suddenly sound disappeared. To reset box, I've turn it off, and from that moment, the only thing that I can see is 'black screen'.

    Now, I've did some research (I'm total noob for android, but I'm somehow familiar to linux), and from what I've found, it isn't all lost - yet?! Searching this forum, I've found how to boot into TWRP, and from there, it was then, that I've found that I can not do a simple flash from zip, because I was getting 'can not mount /cache/recovery/...' errors on console. More net search, and I did found out that my partition table is corrupt. TWRP, and jumpering pcb. got me OTG over usb cable and I was able to drop into adb shell. Here are my console dumps:

    Code:
    # cat /proc/mtd
    
    
    dev:    size   erasesize  name
    mtd0: 00100000 00001000 "bootloader"
    mtd1: 00010000 00001000 "ubootenv"
    
    
    # cat /proc/partitions
    
    
    major minor  #blocks  name
    
    
      31        0       1024 mtdblock0
      31        1         64 mtdblock1
     179        0    7639040 mmcblk0
     179        1    7638016 mmcblk0p1
    
    
    # ls -la /dev/block/mmcblk*
    
    
    __bionic_open_tzdata: couldn't find any tzdata when looking for localtime!
    __bionic_open_tzdata: couldn't find any tzdata when looking for GMT!
    __bionic_open_tzdata: couldn't find any tzdata when looking for posixrules!
    brw------- root     root     179,   0 1998-11-05 18:19 mmcblk0
    brw------- root     root     179,   1 1998-11-05 18:19 mmcblk0p1
    
    
    # df
    
    
    Filesystem           1K-blocks      Used Available Use% Mounted on
    tmpfs                   778996       128    778868   0% /dev
    tmpfs                   778996        20    778976   0% /tmp
    
    
    # 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,ptmxmode=000)
    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)
    adb on /dev/usb-ffs/adb type functionfs (rw,relatime)
    
    
    # tail ./etc/recovery.fstab
    
    
    /logo           emmc        /dev/block/logo         flags=backup=1
    /misc           emmc        /dev/block/misc
    /recovery       emmc        /dev/block/recovery     flags=backup=1
    /boot           emmc        /dev/block/boot         flags=backup=1
    /cache          ext4        /dev/block/cache        flags=backup=1
    /system         ext4        /dev/block/system       flags=backup=1
    /data           ext4        /dev/block/data         flags=backup=1
    /sdcard         vfat        /data/media/0           flags=wipeingui;storage;display="Internal SD"
    /external_sd    vfat        /dev/block/mmcblk0p1    flags=wipeingui;storage;removable;display="External SD"
    /usb-otg        vfat        /dev/block/sda1    /dev/block/sda2    flags=display="USB OTG";removable;storage
    
    
    # tail ./etc/fstab
    
    
     /cache ext4 rw
     /system ext4 rw
     /data ext4 rw
     /sdcard vfat rw
     /dev/block/mmcblk0p1 /external_sd vfat rw
     /usb-otg vfat rw
    
    
    # fdisk -l /dev/block/mmcblk0 (external SD card, from which recovery is booted)
    
    
    Disk /dev/block/mmcblk0: 7822 MB, 7822376960 bytes
    5 heads, 13 sectors/track, 235047 cylinders
    Units = cylinders of 65 * 512 = 33280 bytes
    
    
                  Device Boot      Start         End      Blocks  Id System
    /dev/block/mmcblk0p1              32      235048     7638016   b Win95 FAT32
    
    
    # fdisk -l /dev/block/mmcblk0p1 
    
    
    Disk /dev/block/mmcblk0p1: 7821 MB, 7821328384 bytes
    4 heads, 16 sectors/track, 238688 cylinders
    Units = cylinders of 64 * 512 = 32768 bytes
    
    
                    Device Boot      Start         End      Blocks  Id System
    
    
    # fdisk -l /dev/block/mtdblock0 
    Unknown value(s) for: cylinders (settable in the extra functions menu)
    
    
    Disk /dev/block/mtdblock0: 1 MB, 1048576 bytes
    255 heads, 63 sectors/track, 0 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    
    
                    Device Boot      Start         End      Blocks  Id System
    /dev/block/mtdblock0p1               2         481     3855600   b Win95 FAT32
    
    
    # fdisk -l /dev/block/mtdblock1 
    
    
    Disk /dev/block/mtdblock1: 0 MB, 65536 bytes
    255 heads, 63 sectors/track, 0 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    
    
    Disk /dev/block/mtdblock1 doesn't contain a valid partition table
    Now, before I continue to mess around, I have few question to ask:

    • Can I, and how to make 'backup' of what is worth?
    • Is there any 'easy' way to restore partition table? (how about PIT file, and Odin maybe)
      talking about Odin, I've couldn't get windows drivers to work (using RK_DriverAssitant)
    • Would nandroid backup help in this situation? is there anyone willing to share nandoid backup with me?
    • fdisk ? howto?
    • some other tool?


    Hoping to get some feedback, anytime soon.
    thx
    Fish

    #2
    I have the same problem. Did you bridge the two pins next to the usb ports to enable otg? Did you use a standard usb cable? What do I need on my pc to attempt fixing?
    Thank you.

    Comment


      #3
      I think it's great that Fish has retrieved things at least this far. TWRP may be your saviour. If SShing can get as far as booting TWRP as well, that might save his box too.

      Give me 20 minutes to make a nandroid of CodeSnake's OpenElec on my M8. I'll post a link to my upload. If it works, I wouldn't bother with Android again. Linux makes the M8 fly.

      UPDATE: Here's the link:

      https://mega.co.nz/#!9R1xXQiA!R3N5Qk...7swXwo2PogCCog

      Unzip contents to a blank SD card (one file and one folder); insert card; boot into TWRP via toothpick method; select restore. MUST have a usb keyboard with trackpad or a usb mouse plugged in first to navigate TWRP (touch interface).
      Last edited by Zahir; 11-14-2014, 06:44.

      Comment


        #4
        Originally posted by SSThing View Post
        I have the same problem. Did you bridge the two pins next to the usb ports to enable otg? Did you use a standard usb cable? What do I need on my pc to attempt fixing?
        Thank you.
        I've jumpered those exact pins to enable OTG, take a look at fifth pic. You can use simple usb (A type male - male) cable.
        I'm using linux mint 17. no additional drivers required, with installed adb package. That's all you need.

        @Zahir - Oh, man, thanks a lot, for that backup!!! But, I'm afraid it's no go! I managed to drop to TWRP, but restore died with message: "E: Enable to find partition size for '/boot'"



        Guess, I need to re-partition internal storage after all?

        Anyways, thanks again for the effort. Hope someone else will come up with a way to do re-partitioning.

        thx
        Fish
        Last edited by fish; 11-14-2014, 14:10.

        Comment


          #5
          Originally posted by fish View Post
          Greetings guys, I've recently purchased M8 square box, which worked great, last month or two.
          From what I see, it is common squared M8, pcb v0.92:



          But recently, while I was watching movie from usb stick, suddenly sound disappeared. To reset box, I've turn it off, and from that moment, the only thing that I can see is 'black screen'.

          Now, I've did some research (I'm total noob for android, but I'm somehow familiar to linux), and from what I've found, it isn't all lost - yet?! Searching this forum, I've found how to boot into TWRP, and from there, it was then, that I've found that I can not do a simple flash from zip, because I was getting 'can not mount /cache/recovery/...' errors on console. More net search, and I did found out that my partition table is corrupt. TWRP, and jumpering pcb. got me OTG over usb cable and I was able to drop into adb shell. Here are my console dumps:

          Code:
          # cat /proc/mtd
          
          
          dev:    size   erasesize  name
          mtd0: 00100000 00001000 "bootloader"
          mtd1: 00010000 00001000 "ubootenv"
          
          
          # cat /proc/partitions
          
          
          major minor  #blocks  name
          
          
            31        0       1024 mtdblock0
            31        1         64 mtdblock1
           179        0    7639040 mmcblk0
           179        1    7638016 mmcblk0p1
          
          
          # ls -la /dev/block/mmcblk*
          
          
          __bionic_open_tzdata: couldn't find any tzdata when looking for localtime!
          __bionic_open_tzdata: couldn't find any tzdata when looking for GMT!
          __bionic_open_tzdata: couldn't find any tzdata when looking for posixrules!
          brw------- root     root     179,   0 1998-11-05 18:19 mmcblk0
          brw------- root     root     179,   1 1998-11-05 18:19 mmcblk0p1
          
          
          # df
          
          
          Filesystem           1K-blocks      Used Available Use% Mounted on
          tmpfs                   778996       128    778868   0% /dev
          tmpfs                   778996        20    778976   0% /tmp
          
          
          # 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,ptmxmode=000)
          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)
          adb on /dev/usb-ffs/adb type functionfs (rw,relatime)
          
          
          # tail ./etc/recovery.fstab
          
          
          /logo           emmc        /dev/block/logo         flags=backup=1
          /misc           emmc        /dev/block/misc
          /recovery       emmc        /dev/block/recovery     flags=backup=1
          /boot           emmc        /dev/block/boot         flags=backup=1
          /cache          ext4        /dev/block/cache        flags=backup=1
          /system         ext4        /dev/block/system       flags=backup=1
          /data           ext4        /dev/block/data         flags=backup=1
          /sdcard         vfat        /data/media/0           flags=wipeingui;storage;display="Internal SD"
          /external_sd    vfat        /dev/block/mmcblk0p1    flags=wipeingui;storage;removable;display="External SD"
          /usb-otg        vfat        /dev/block/sda1    /dev/block/sda2    flags=display="USB OTG";removable;storage
          
          
          # tail ./etc/fstab
          
          
           /cache ext4 rw
           /system ext4 rw
           /data ext4 rw
           /sdcard vfat rw
           /dev/block/mmcblk0p1 /external_sd vfat rw
           /usb-otg vfat rw
          
          
          # fdisk -l /dev/block/mmcblk0 (external SD card, from which recovery is booted)
          
          
          Disk /dev/block/mmcblk0: 7822 MB, 7822376960 bytes
          5 heads, 13 sectors/track, 235047 cylinders
          Units = cylinders of 65 * 512 = 33280 bytes
          
          
                        Device Boot      Start         End      Blocks  Id System
          /dev/block/mmcblk0p1              32      235048     7638016   b Win95 FAT32
          
          
          # fdisk -l /dev/block/mmcblk0p1 
          
          
          Disk /dev/block/mmcblk0p1: 7821 MB, 7821328384 bytes
          4 heads, 16 sectors/track, 238688 cylinders
          Units = cylinders of 64 * 512 = 32768 bytes
          
          
                          Device Boot      Start         End      Blocks  Id System
          
          
          # fdisk -l /dev/block/mtdblock0 
          Unknown value(s) for: cylinders (settable in the extra functions menu)
          
          
          Disk /dev/block/mtdblock0: 1 MB, 1048576 bytes
          255 heads, 63 sectors/track, 0 cylinders
          Units = cylinders of 16065 * 512 = 8225280 bytes
          
          
                          Device Boot      Start         End      Blocks  Id System
          /dev/block/mtdblock0p1               2         481     3855600   b Win95 FAT32
          
          
          # fdisk -l /dev/block/mtdblock1 
          
          
          Disk /dev/block/mtdblock1: 0 MB, 65536 bytes
          255 heads, 63 sectors/track, 0 cylinders
          Units = cylinders of 16065 * 512 = 8225280 bytes
          
          
          Disk /dev/block/mtdblock1 doesn't contain a valid partition table
          Now, before I continue to mess around, I have few question to ask:

          • Can I, and how to make 'backup' of what is worth?
          • Is there any 'easy' way to restore partition table? (how about PIT file, and Odin maybe)
            talking about Odin, I've couldn't get windows drivers to work (using RK_DriverAssitant)
          • Would nandroid backup help in this situation? is there anyone willing to share nandoid backup with me?
          • fdisk ? howto?
          • some other tool?


          Hoping to get some feedback, anytime soon.
          thx
          Fish

          Did you attempt to wipe or reformat the unmountable partitions using TWRP?

          The partition layout is usually hard coded in the kernel on Amlogic devices. Its not configured by a parameter file/partition like it is on Rockchip devices. Wiping or reformatting with TWRP may get your partitions mountable again. Then you should be flash it.

          ShaunMT
          Freaktab Rom Developer

          Subscribe To My Developer Thread For Updates On My Projects: ShaunMT

          https://www.paypalobjects.com/en_US/..._donate_SM.gif

          Comment


            #6
            @ShaunMT - thx for joining

            I've tried to wipe all partition and also to repair them in TWRP but nothing seem to work. Almost all off these actions end with messages like:



            I'm attaching my recovery.log

            recovery.zip

            I've managed to make backup of bootloader and ubootenv partitions which are the only ones that appear alive on mtd, ( also visible in recovery.fstab)

            this line, from recovery.log, concerns me a bit:
            Code:
            BOARD_HAS_NO_REAL_SDCARD := true
            I was wondering, is it possible to use dd to somehow dump entire partition (from healthy device)? (and also dump partition table)

            Comment


              #7
              Is there anyone, with working box, willing to execute this command in shell (adb) or whatever shell with busybox (from working android):

              Code:
              fdisk -l /dev/block/mmcblk0
              I should be able to do exact re-partitioning from that.

              Thanks.

              Comment


                #8
                Originally posted by fish View Post
                Is there anyone, with working box, willing to execute this command in shell (adb) or whatever shell with busybox (from working android):

                Code:
                fdisk -l /dev/block/mmcblk0
                I should be able to do exact re-partitioning from that.

                Thanks.
                I dont have my box yet is ordered but I will do this for you when I get it. Unless I have to open it to get into adb. Id rather not do that just yet. At saying that I dont think fdisk will cut it. Ill see if i can get a sfdisk. fdisk is really limited. Is there any way to open a terminal up from the box itself? Ill know more when i get the box.

                sfdisk -d /dev/block/mmcblk0 > partitions.txt #to dump
                sfdisk /dev/block/mmcblk0 < partitions.txt #to restore

                ill need to look into the boot img command when i get the box as well there could be custom flash format commands. Without the box in front if me is hard to tell whats going on. You might get the info you need if you open the image within the update.zip

                Comment


                  #9
                  Originally posted by grant2258 View Post
                  I dont have my box yet is ordered but I will do this for you when I get it. Unless I have to open it to get into adb. Id rather not do that just yet. At saying that I dont think fdisk will cut it. Ill see if i can get a sfdisk. fdisk is really limited. Is there any way to open a terminal up from the box itself? Ill know more when i get the box.

                  sfdisk -d /dev/block/mmcblk0 > partitions.txt #to dump
                  sfdisk /dev/block/mmcblk0 < partitions.txt #to restore

                  ill need to look into the boot img command when i get the box as well there could be custom flash format commands. Without the box in front if me is hard to tell whats going on. You might get the info you need if you open the image within the update.zip
                  Hey man, thanks for joining
                  I've tried your method from here
                  http://www.freaktab.com/showthread.p...square+em8+img
                  using bootcardmaker SD and finless 1.8 but no luck agian, can pass that bad partition table.

                  Now, I've also tried to pass that fdisk error (I was trying to recreate part table on mtdblock1)

                  Code:
                  Unknown value(s) for: cylinders (settable in the extra functions menu)
                  I found that parted may help but there isn't any in TWRP busybox dist.

                  I've also tried to flash in Windows, using USB Burning Tool.exe and PROBOX2-EX-20141015.img and probox2_cr_freaktab.img but they both failing at 6% when trying to 'download' bootloader.
                  Any chance getting stock SQ M8 img for using with USB Burning Tool ?

                  thx
                  Last edited by fish; 01-07-2015, 23:52.

                  Comment


                    #10
                    Ok, after consulting @grant2258 I'm using only this method:
                    • I'm connecting with usb (connecting usb for power didn't work) with external power attached, no sd card, while holding reset, with an ear pick
                    • this registers as World Cup device in Windows Device Manager
                    • using USB Burning Tool v2.0.0.140306, I'm trying to flash PROBOX2-EX-20141015.img
                    • process stops at 6%

                    take a look on this screencast (please download, no preview available, sorry) https://app.box.com/s/otioks0qwg6zezn6h6m6
                    and my log is here https://app.box.com/s/x153aalf8txyavbimudo

                    From here, if I reboot (without card) nothing happens, no blue light - nadda
                    if use SD with twrp on it, I can boot into recovery with screwed up partitions as before.


                    Comment


                      #11
                      Originally posted by fish View Post
                      Ok, after consulting @grant2258 I'm using only this method:
                      • I'm connecting with usb (connecting usb for power didn't work) with external power attached, no sd card, while holding reset, with an ear pick
                      • this registers as World Cup device in Windows Device Manager
                      • using USB Burning Tool v2.0.0.140306, I'm trying to flash PROBOX2-EX-20141015.img
                      • process stops at 6%

                      take a look on this screencast (please download, no preview available, sorry) https://app.box.com/s/otioks0qwg6zezn6h6m6
                      and my log is here https://app.box.com/s/x153aalf8txyavbimudo

                      From here, if I reboot (without card) nothing happens, no blue light - nadda
                      if use SD with twrp on it, I can boot into recovery with screwed up partitions as before.


                      step 1
                      untick erase bootloader
                      flash
                      power off

                      power box on see if it picks up without recovery
                      if it does
                      untick erase bootloader
                      flash
                      power off

                      if that dont work step 2

                      short nand pins (no sdcard) if box picks up
                      untick erase bootloader
                      flash
                      power off

                      if it fails youll need the to make a sdcard with usb flash bootimg (root of amtools) and copy the file think its something wps (it has strange chineese chars in it youll notice it right away) over to the sdcard
                      puts sdcard in (no need to hold recovery with nand pins shorted on my box anyway) .

                      did you try both usb ports? one should power you up uness you usb cable doesnt have the power lines. Did you try move the jumper the blue one on you usb ports this also changes from box to box its a pain with so many clones. But put it back to where it should be when your done or the box wont boot
                      Last edited by grant2258; 01-08-2015, 14:27.

                      Comment


                        #12
                        Ok, none of these steps did work.
                        I've tried simple flashing with turning off the power, then shortening the pins and same procedure, nothing worked. Then I've made sd card with u-boot (flashing using BootcardMaker) and usb刷机工具说明.wps on same card) that just gave me flashing blue led and no usb connection (world cup device) on both ports (with or without ext power). So if I ditch sd-card and just use usb cable and ext power I can get my device recognized as world cup device, and start flashing (I've tried 1.6 burning tool also). It always fails at 6% no matter what.
                        From burning log I can see that error code 0x31020302 Uboot阶段烧录分区2,加载命令执行失败, when translated to English, means 'download command return failure at Uboot Partition 2'. Is it possible that my flash is fried with no possibility to recover? Is it PROBOX2-EX-20141015.img a real sub for my box, where can I found/try other roms (img)?

                        thx

                        Comment


                          #13
                          Try the newest version of burning tools, it's at version 2.0.3 iirc

                          https://www.dropbox.com/s/nsinm600l8...3_x86.exe?dl=0
                          Last edited by wiz569; 01-27-2015, 16:50. Reason: adding link to usb burning tools v2.0.3 x86

                          Comment


                            #14
                            M8 Square - BRICKED - or not - faulty partition table?

                            Originally posted by fish View Post
                            Ok, none of these steps did work.
                            I've tried simple flashing with turning off the power, then shortening the pins and same procedure, nothing worked. Then I've made sd card with u-boot (flashing using BootcardMaker) and usb刷机工具说明.wps on same card) that just gave me flashing blue led and no usb connection (world cup device) on both ports (with or without ext power). So if I ditch sd-card and just use usb cable and ext power I can get my device recognized as world cup device, and start flashing (I've tried 1.6 burning tool also). It always fails at 6% no matter what.
                            From burning log I can see that error code 0x31020302 Uboot阶段烧录分区2,加载命令执行失败, when translated to English, means 'download command return failure at Uboot Partition 2'. Is it possible that my flash is fried with no possibility to recover? Is it PROBOX2-EX-20141015.img a real sub for my box, where can I found/try other roms (img)?

                            thx
                            What uboot did you use fish it needs to be the one at the root folder of the dir from the tools not the one in the sdcard folder. Did you try pressing the the recovery pin while shorting the nand pins before powering up as well? I'll need to find if there is something I can dump my nand before the box boots that I don't need to install if the above fails. If u have something post me a link ill dump the whole nand. I'll try adb from recovery at the weekend might not boot nand you never know

                            Comment

                            Working...
                            X