Author Topic: LiveSuit with lubuntu-server-nand.img - exiting prematurely  (Read 11052 times)

Offline D_NRW

  • Jr. Member
  • **
  • Posts: 65
  • Karma: +3/-0
    • View Profile
    • Dan-And
LiveSuit with lubuntu-server-nand.img - exiting prematurely
« on: December 23, 2013, 08:08:02 am »
Hi,

I am trying to flash the lubuntu image  (http://dl.cubieboard.org/software/a20-cubieboard/lubuntu/cb-a20-lubuntu-12.10-v1.06/cb2-lubuntu-server-20131026/ ) to the nand to the cubieboard 2 (A20) board.

However I have a weird issue, which I can not explain.

Here is my log:
MacOS daniel$ sudo ./LiveSuit
library file path: /Users/daniel/Downloads/LiveSuit_ForMac/LiveSuit.app/Contents/MacOS/plgvector.dll
library file path: /Users/daniel/Downloads/LiveSuit_ForMac/LiveSuit.app/Contents/MacOS/LangPlg.dll
LoadFile 24
Open 253: Language file format is Unicode little endian
library file path: /Users/daniel/Downloads/LiveSuit_ForMac/LiveSuit.app/Contents/MacOS/LiveProc.Plg
library file path: /Users/daniel/Downloads/LiveSuit_ForMac/LiveSuit.app/Contents/MacOS/plgvector.dll
library file path: /Users/daniel/Downloads/LiveSuit_ForMac/LiveSuit.app/Contents/MacOS/luaeFex.dll
DeviceThreadEntryForMac called
Register./luaBase.dll l_RegAllFun Sucess!
Register./luaeFex.dll l_RegAllFun Sucess!
Register./luadec.dll l_RegAllFun Sucess!
IMAGEWTY
ItemTableSize = 1048576
Closing image now!

Clos image OK!

./AllWinnerDevice.cpp Fex_Open 604
Found allwinner usb device (vendor 7994, product 61416), location id fd130000
Found 1 devices
Register./luaBase.dll l_RegAllFun Sucess!
Register./luaeFex.dll l_RegAllFun Sucess!
Register./luadec.dll l_RegAllFun Sucess!
IMAGEWTY
ItemTableSize = 1048576
Closing image now!

Clos image OK!

./AllWinnerDevice.cpp Fex_Open 604
Found allwinner usb device (vendor 7994, product 61416), location id fd130000
Found 1 devices
./AllWinnerDevice.cpp Fex_Open 604
Found allwinner usb device (vendor 7994, product 61416), location id fd130000
Found 1 devices
[Tl_Msg]Init : imgFilePath=/Users/daniel/Downloads/LiveSuit_ForMac/lubuntu-server-nand.img, imgLen=[0, 1068358656], workMode=8

IMAGEWTY
ItemTableSize = 1048576
./buffer.cpp, pBuffer = 0x10482d004, nLen = 16380, crc32 = 4174770694[Tl_Msg]Down index[1] start

[Tl_Msg]partName=bootloader, pktSubType=BOOTLOADER_FEX00, verifyFile=VBOOTLOADER_FEX0

[Tl_Msg]partAddrHigInSec=0x0, partAddrLowInSec=0x8000, partSzHigInSec=0x0, partSzLowInSec=0x20000

[Tl_Msg]isEncrypt=false, toVerify=true

[Tl_Msg]Down index[1] end

[Tl_Msg]Down index[2] start

[Tl_Msg]partName=rootfs, pktSubType=ROOTFS_FEX000000, verifyFile=VROOTFS_FEX00000

[Tl_Msg]partAddrHigInSec=0x0, partAddrLowInSec=0x28000, partSzHigInSec=0x0, partSzLowInSec=0x400000

[Tl_Msg]isEncrypt=false, toVerify=true

[Tl_Msg]Down index[2] end

[Tl_Msg]Down number is 2

[Tl_Msg]sec[platform]

[Tl_Msg]sec[card2_boot_para]

0x10482d000, 541, 4, =40x10482d000, 540, 2, =2[Tl_Msg]sec[card_boot]

[Tl_Msg]sec[target]

[Tl_Msg]sec[dram_para]

[Tl_Msg]sec[DllInfo]

[Tl_Msg]sec[uart_para]

[Tl_Msg][platform]

[Tl_Msg]eraseflag           = 0x0

[Tl_Msg]

[Tl_Msg][card2_boot_para]

[Tl_Msg]sdc_clk             = port:PC7<3><1>

[Tl_Msg]card_line           = 0x4

[Tl_Msg]sdc_d0              = port:PC8<3><1>

[Tl_Msg]card_ctrl           = 0x2

[Tl_Msg]sdc_cmd             = port:PC6<3><1>

[Tl_Msg]sdc_d2              = port:PC10<3><1>

[Tl_Msg]sdc_d3              = port:PC11<3><1>

[Tl_Msg]card_high_speed     = 0x1

[Tl_Msg]sdc_d1              = port:PC9<3><1>

[Tl_Msg]

[Tl_Msg][card_boot]

[Tl_Msg]logical_start       = 0xa000

[Tl_Msg]

[Tl_Msg][target]

[Tl_Msg]storage_type        = 0x0

[Tl_Msg]

[Tl_Msg][dram_para]

[Tl_Msg]dram_baseaddr       = 0x40000000

[Tl_Msg]dram_chip_density   = 0xffffffff

[Tl_Msg]dram_size           = 0xffffffff

[Tl_Msg]dram_rank_num       = 0xffffffff

[Tl_Msg]dram_io_width       = 0xffffffff

[Tl_Msg]dram_tpr0           = 0x42d899b7

[Tl_Msg]dram_cas            = 0x9

[Tl_Msg]dram_odt_en         = 0x0

[Tl_Msg]dram_tpr1           = 0xa090

[Tl_Msg]dram_zq             = 0x7f

[Tl_Msg]dram_bus_width      = 0xffffffff

[Tl_Msg]dram_tpr4           = 0x1

[Tl_Msg]dram_emr3           = 0x0

[Tl_Msg]dram_clk            = 0x1e0

[Tl_Msg]dram_emr2           = 0x10

[Tl_Msg]dram_emr1           = 0x4

[Tl_Msg]dram_tpr5           = 0x0

[Tl_Msg]dram_tpr3           = 0x0

[Tl_Msg]dram_type           = 0x3

[Tl_Msg]dram_tpr2           = 0x22a00

[Tl_Msg]

[Tl_Msg][DllInfo]

[Tl_Msg]

[Tl_Msg][uart_para]

[Tl_Msg]uart_debug_rx       = port:PB23<2><1><default><default>

[Tl_Msg]uart_debug_port     = 0x0

[Tl_Msg]uart_debug_tx       = port:PB22<2><1><default><default>

[Tl_Msg]

[Tl_Msg]Init end

[Tl_Msg]fel in: dev[fd130000]

./AllWinnerDevice.cpp Fex_Open 604
Found allwinner usb device (vendor 7994, product 61416), location id fd130000
Found 1 devices
[Tl_Msg]platform id checked OK

[Tl_Msg]To down sys para

[Tl_Msg]To down and Run fes1-1

[Tl_Msg]To clear fes aide log

[Tl_Msg]To down and Run fes1-2

[Tl_Msg]To clear fes aide log

[Tl_Msg]OK test fel Down and Up in len=8192

[Tl_Msg]OK to test dram

[Tl_Msg]Update dram size to 2048MBytes

2013-12-23 13:54:30.861 LiveSuit[431:507] modalSession has been exited prematurely - check for a reentrant call to endModalSession:
[Tl_Msg]nMsgRet=1


[Tl_Msg]To down fes2_1

[Tl_Msg]To down fes2_2

[Tl_Msg]To clear fes aide log

[Tl_Msg]not hasRetLog

[Tl_Msg]Fel end

Fel Thread Finished!

----------------


That's it. As you can see, I have tried to flash on my Mac, so that I can show you this log. I also tried the PhoenixSuite on Windows, but the effect is the same (Sadly, I have no logs to share on the Windows system).

What confuses me: Why does it update the dram size to 2048mb ?
I assume that this causes the break in the process.


Offline rose28357

  • Hero Member
  • *****
  • Posts: 567
  • Karma: +28/-0
    • View Profile
Re: LiveSuit with lubuntu-server-nand.img - exiting prematurely
« Reply #1 on: December 23, 2013, 06:59:47 pm »
2 GByte is used by Cubietruck. Maybe a copy error for a A20 Image ?

Saegematz

  • Guest
Re: LiveSuit with lubuntu-server-nand.img - exiting prematurely
« Reply #2 on: December 24, 2013, 12:56:33 am »
hi!
I have the same error in Windows with PhönixSuite.
I downloaded the image.img correct and PhönixSuite makes everytime an error.
I downloaded the Image.img.gz and decoded it. The Image have the size of 2GB
and then PhönixSuite has no error and the Image was working. I think the same as
rose. The Image Size is to small. After unpack the image.img.gz the Image has
the name Image.img. Try this way maybe.
Cu

Offline D_NRW

  • Jr. Member
  • **
  • Posts: 65
  • Karma: +3/-0
    • View Profile
    • Dan-And
Re: LiveSuit with lubuntu-server-nand.img - exiting prematurely
« Reply #3 on: December 24, 2013, 02:30:30 am »
Hi,

No I don't think it is the wrong image.
I checked it twice:

$ du -hs lubuntu-server-nand.img*
1019M   lubuntu-server-nand.img
295M   lubuntu-server-nand.img.gz

$ md5 lubuntu-server-nand.img.gz
MD5 (lubuntu-server-nand.img.gz) = 3dc1a001be92696d85079b1c2fc1161c

$ cat lubuntu-server-nand.img.gz.md5
3dc1a001be92696d85079b1c2fc1161c  /back2/new_sdk/linux-sdk/release/cb2-lubuntu-server-20131026/lubuntu-server-nand.img.gz

It is the same file, as it is available at:
http://dl.cubieboard.org/software/a20-cubieboard/lubuntu/cb-a20-lubuntu-12.10-v1.06/cb2-lubuntu-server-20131026/


Does anyone have another idea how I could get more debug data or even manually flash the /dev/nand with the lubuntu-12.10 image on the cubieboard, while I am running another linux from the sd card ?




Saegematz

  • Guest
Re: LiveSuit with lubuntu-server-nand.img - exiting prematurely
« Reply #4 on: December 24, 2013, 03:20:13 am »
Try format befor flashing.
Try a USB Hub with external current.
Maybe the current is to less.
Cu

Offline rose28357

  • Hero Member
  • *****
  • Posts: 567
  • Karma: +28/-0
    • View Profile
Re: LiveSuit with lubuntu-server-nand.img - exiting prematurely
« Reply #5 on: December 26, 2013, 03:18:42 am »
Try a USB Hub with external current.
Maybe the current is to less.
To flash the nand i connect both cable (power and micro USB) to two USB ports of the same pc. Then i press FEL button and Reset buttom at the same time. Release the Reset button first, wait a second then release FEL. Phönix will start immediatly with download to the cubietruck.

This setup grands a good power supply during flashing with micro USB.

But that is not the point of this thread. Your cubieboard image for A20 seems to have a Cubietruck (2 Gigabyte RAM) kernel configuraton. It will never work for you.

I dont know were the dram size is set. For UImage it would be in the fex file.
« Last Edit: December 26, 2013, 03:24:54 am by rose28357 »

Offline jobarjo

  • Newbie
  • *
  • Posts: 19
  • Karma: +0/-0
    • View Profile
Re: LiveSuit with lubuntu-server-nand.img - exiting prematurely
« Reply #6 on: January 08, 2014, 05:43:25 pm »
I also can't flash any ubuntu images under both linux and windows.
I can flash only android.

I also use 3 usb ports for powering. (a double usb to micro usb cable, and the usb power cable)

Tried livesuit 3.05 and 3.06, and phoenixsuit 1.0.6 and 1.0.8

Offline rose28357

  • Hero Member
  • *****
  • Posts: 567
  • Karma: +28/-0
    • View Profile
Re: LiveSuit with lubuntu-server-nand.img - exiting prematurely
« Reply #7 on: January 09, 2014, 12:54:55 am »
Which Lubuntu-Version from which link do you try to flash to nand ?
Maybe it isnthe wrong image.

Offline GeorgeIoak

  • Jr. Member
  • **
  • Posts: 52
  • Karma: +1/-0
    • View Profile
Re: LiveSuit with lubuntu-server-nand.img - exiting prematurely
« Reply #8 on: January 13, 2014, 11:18:25 pm »
There seems to be a problem with only some CB2 and flashing linaro to NAND. What works is if you first flash an older Android, I used version 1.04 and then you are able to flash the linaro image into NAND.

Here’s what the NAND partitions look like when you flash Android 1.06 (boot from SD Card and inspect the NAND)

Code: [Select]
linaro@cubieboard2:~/sunxi-tools$ sudo ./nand-part
check partition table copy 0: mbr: version 0xffffffff, magic ÿÿÿÿÿÿÿÿ
magic ÿÿÿÿÿÿÿÿ is not softw311
check partition table copy 1: mbr: version 0xffffffff, magic ÿÿÿÿÿÿÿÿ
magic ÿÿÿÿÿÿÿÿ is not softw311
check partition table copy 2: mbr: version 0xffffffff, magic ÿÿÿÿÿÿÿÿ
magic ÿÿÿÿÿÿÿÿ is not softw311
check partition table copy 3: mbr: version 0xffffffff, magic ÿÿÿÿÿÿÿÿ
magic ÿÿÿÿÿÿÿÿ is not softw311
all partition tables are bad!
check partition table copy 0: mbr: version 0xffffffff, magic ÿÿÿÿÿÿÿÿ
magic ÿÿÿÿÿÿÿÿ is not softw411
check partition table copy 1: mbr: version 0xffffffff, magic ÿÿÿÿÿÿÿÿ
magic ÿÿÿÿÿÿÿÿ is not softw411
check partition table copy 2: mbr: version 0xffffffff, magic ÿÿÿÿÿÿÿÿ
magic ÿÿÿÿÿÿÿÿ is not softw411
check partition table copy 3: mbr: version 0xffffffff, magic ÿÿÿÿÿÿÿÿ
magic ÿÿÿÿÿÿÿÿ is not softw411
all partition tables are bad!
linaro@cubieboard2:~/sunxi-tools$


linaro@cubieboard2:~$ sudo cat /proc/partitions
major minor  #blocks  name

  93        0    3989504 nand
179        0    7761920 mmcblk0
179        1      12288 mmcblk0p1
179        2    3858944 mmcblk0p2
After flashing cb_a20_android42_v1.04_8188eu-ddr432-en_US.img, and booting linaro from the SD Card and ran nand-part again. This time the partitions are read.

Code: [Select]
linaro@cubieboard2:~/sunxi-tools$ sudo ./nand-part
check partition table copy 0: mbr: version 0x00000200, magic softw411
magic softw411 is not softw311
check partition table copy 1: mbr: version 0x00000000, magic
magic          is not softw311
check partition table copy 2: mbr: version 0x00000000, magic
magic          is not softw311
check partition table copy 3: mbr: version 0x00000000, magic
magic          is not softw311
all partition tables are bad!
check partition table copy 0: mbr: version 0x00000200, magic softw411
OK
check partition table copy 1: mbr: version 0x00000200, magic softw411
OK
check partition table copy 2: mbr: version 0x00000200, magic softw411
OK
check partition table copy 3: mbr: version 0x00000200, magic softw411
OK
mbr: version 0x00000200, magic softw411
11 partitions
partition  1: class =         DISK, name =   bootloader, partition start =    32768, partition size =    32768 user_type=0
partition  2: class =         DISK, name =          env, partition start =    65536, partition size =    32768 user_type=0
partition  3: class =         DISK, name =         boot, partition start =    98304, partition size =    32768 user_type=0
partition  4: class =         DISK, name =       system, partition start =   131072, partition size =  1048576 user_type=2
partition  5: class =         DISK, name =         data, partition start =  1179648, partition size =  1048576 user_type=2
partition  6: class =         DISK, name =         misc, partition start =  2228224, partition size =    32768 user_type=0
partition  7: class =         DISK, name =     recovery, partition start =  2260992, partition size =    65536 user_type=0
partition  8: class =         DISK, name =        cache, partition start =  2326528, partition size =   655360 user_type=2
partition  9: class =         DISK, name =      private, partition start =  2981888, partition size =    32768 user_type=0
partition 10: class =         DISK, name =       databk, partition start =  3014656, partition size =   524288 user_type=0
partition 11: class =         DISK, name =        UDISK, partition start =  3538944, partition size =  4194304 user_type=0
check partition table copy 0: mbr: version 0x00000200, magic softw411
OK
check partition table copy 1: mbr: version 0x00000200, magic softw411
OK
check partition table copy 2: mbr: version 0x00000200, magic softw411
OK
check partition table copy 3: mbr: version 0x00000200, magic softw411
OK
mbr: version 0x00000200, magic softw411
11 partitions
partition  1: class =         DISK, name =   bootloader, partition start =    32768, partition size =    32768 user_type=0
partition  2: class =         DISK, name =          env, partition start =    65536, partition size =    32768 user_type=0
partition  3: class =         DISK, name =         boot, partition start =    98304, partition size =    32768 user_type=0
partition  4: class =         DISK, name =       system, partition start =   131072, partition size =  1048576 user_type=2
partition  5: class =         DISK, name =         data, partition start =  1179648, partition size =  1048576 user_type=2
partition  6: class =         DISK, name =         misc, partition start =  2228224, partition size =    32768 user_type=0
partition  7: class =         DISK, name =     recovery, partition start =  2260992, partition size =    65536 user_type=0
partition  8: class =         DISK, name =        cache, partition start =  2326528, partition size =   655360 user_type=2
partition  9: class =         DISK, name =      private, partition start =  2981888, partition size =    32768 user_type=0
partition 10: class =         DISK, name =       databk, partition start =  3014656, partition size =   524288 user_type=0
partition 11: class =         DISK, name =        UDISK, partition start =  3538944, partition size =  4194304 user_type=0
For some reason the PhoenixSuit flash took longer than normal but it did work and I’ve confirmed the image boots and I’m able to use it. Normal flashes take ~3 minutes but this time it took close to 7 minutes to flash the linaro image.

Offline jobarjo

  • Newbie
  • *
  • Posts: 19
  • Karma: +0/-0
    • View Profile
Re: LiveSuit with lubuntu-server-nand.img - exiting prematurely
« Reply #9 on: January 19, 2014, 11:34:24 am »
thanks for the suggestion

I tried to flash android 1.04 from here
http://linux-sunxi.org/A20-Cubieboard/Nand_Images
and here
http://dl.cubieboard.org/software/a20-cubieboard/android/cb_a20_android42_v1.04_8188eu-en_US.img

(they are the same : md5: 62d59e42c4acda2f08578b1f3a78317b)

flash fails with linux LiveSuit 3.06 (latest android still works). Will try Windows.
 
Finally, I think I will try the nand driver and nand-part.

I think I found some instructions here
http://www.cubieforums.com/index.php/topic,511.msg2408.html#msg2408
(looks a little messy or outdated)

It would be nice to maintain an updated wiki for this.