WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: CubieBoard, Install to NAND  (Read 7953 times)

Offline MapHtH

  • WikiUser
  • *
  • Posts: 28
CubieBoard, Install to NAND
« on: June 06, 2013, 05:21:46 AM »
Is it possible to install this on NAND in some way?

I've tried the livesuit but it doesn't work.

Offline roberts

  • Administrator
  • Hero Member
  • *****
  • Posts: 7361
  • Founder Emeritus
Re: CubieBoard, Install to NAND
« Reply #1 on: June 17, 2013, 05:15:50 AM »
AFAIK livesuit is a Windows program. I don't have or use Windows.
Installing to nand should be possible with proper changes to the appropriate boot files.
There is nothing inherit in the system that should prevent such.
10+ Years Contributing to Linux Open Source Projects.

Offline MapHtH

  • WikiUser
  • *
  • Posts: 28
Re: CubieBoard, Install to NAND
« Reply #2 on: January 30, 2015, 08:44:12 AM »
Yeah, I know that this is ancient, but can anyone help?

What scripts I would need to edit?
I followed this: http://www.cubieforums.com/index.php/topic,73.msg235.html#msg235
and this: http://linux-sunxi.org/Cubieboard/Installing_on_NAND

but it won't work.

bin file you can download here because it is gone from cubieboard forums.

Offline MapHtH

  • WikiUser
  • *
  • Posts: 28
Re: CubieBoard, Install to NAND
« Reply #3 on: February 07, 2015, 04:50:09 AM »
Do I need to compile my own uboot files?

Offline MapHtH

  • WikiUser
  • *
  • Posts: 28
Re: CubieBoard, Install to NAND
« Reply #4 on: February 12, 2015, 04:25:09 AM »
Now, I know that I need to modify boot.scr.
The problem is that if I use the following settings:

Code: [Select]
setenv bootargs console=${console} init=/init rootwait panic=${panic} loglevel=${loglevel} ${extraargs}
ext4load nand 0:2 0x43000000 boot/script.bin
ext4load nand 0:2 0x48000000 boot/uImage
ext4load nand 0:2 0x43100000 boot/uCore
bootm 0x48000000 0x43100000

and the image is set so that u-boot and other nand bootable files are on the fat partition 1 (nanda) and the kernel uImage, uCore, script.bin, uEnv.txt and boot.scr are on an ext4 partition (nandb)
However, whenever I use the posted boot.scr, it says something like wrong partition and it can't load any of the files, so it loads the kernel instead (and loads it from ext4 partition which means that it can read it), but nothing else which leads to a constant reboot.

Now, a question, does ext4load load partitions which need to be named linux way (nand1, nand2...) or can it read the android partition names (nanda, nandb...)?
How could I make this work? Do I need to use a different command to load the files?

Thanks

Offline MapHtH

  • WikiUser
  • *
  • Posts: 28
Re: CubieBoard, Install to NAND
« Reply #5 on: February 12, 2015, 05:42:38 AM »
Why can't I edit my post? Anyway, sorry for triple post.

Here's the u-boot serial output:

Code: [Select]
HELLO! BOOT0 is starting!
boot0 version : 1.5.0
dram size =1024
Succeed in opening nand flash.
Succeed in reading Boot1 file head.
The size of Boot1 is 0x00056000.
The file stored in 0X00000000 of block 2 is perfect.
Check is correct.
Ready to disable icache.
Succeed in loading Boot1.
Jump to Boot1.
[       0.177] boot1 version : 1.5.0
[       0.177] pmu type = 3
[       0.179] bat vol = 0
[       0.210] axi:ahb:apb=3:2:2
[       0.210] set dcdc2=1400, clock=1008 successed
[       0.212] key
[       0.225] no key found
[       0.225] flash init start
[       0.265] flash init finish
[       0.267] fs init ok
[       0.268] fattype FAT12
[       0.268] fs mount ok
[       0.274] script finish
[       0.275] power finish
[       0.284] BootMain start
[       0.284] 0
[       0.316] key value = 0
[       0.316] recovery key high 6, low 4
[       0.317] unable to find fastboot_key key_max value
[       0.325] test for multi os boot with display
[       0.327] logo name is invalid or dont need show logo
[       0.332] load kernel start
[       0.359] load kernel successed
[       0.359] start address = 0x4a000000
[       0.361] jump to


U-Boot 2013.01-05530-g8843079-dirty (Feb 04 2013 - 02:41:41) Allwinner Technology

Board: Cubieboard
I2C:   ready
DRAM:  1 GiB
NAND:  0 MiB
MMC:   SUNXI SD/MMC: 0
MMC init failed
Using default environment

In:    serial
Out:   serial
Err:   serial
Net:   wemac
Hit any key to stop autoboot:  0
179 bytes read in 14 ms (11.7 KiB/s)
Loaded environment from /uEnv.txt
330 bytes read in 14 ms (22.5 KiB/s)
Jumping to /boot.scr
## Executing script at 44000000
** Invalid partition 2 **
** Invalid partition 2 **
** Invalid partition 2 **
Wrong Image Format for bootm command
ERROR: can't get kernel image!
4484836 bytes read in 282 ms (15.2 MiB/s)
## Booting kernel from Legacy Image at 48000000 ...
   Image Name:   Linux-3.0.42
   Created:      2013-02-09   2:41:39 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    4484772 Bytes = 4.3 MiB
   Load Address: 40008000
   Entry Point:  40008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK

Starting kernel ...

<6>Initializing cgroup subsys cpuset
<5>Linux version 3.0.42 (root@testing) (gcc version 4.5.2 (Sourcery G++ Lite 2011.03-41) ) #3 PREEMPT Fri Feb 8 18:38:58 PST 2013
CPU: ARMv7 Processor [413fc082] revision 2 (ARMv7), cr=10c5387d
CPU: VIPT nonaliasing data cache, VIPT aliasing instruction cache
Machine: sun4i
<6>Memory Reserved:
<6>     SYS  : 0x43000000 - 0x4300ffff  (  64 kB)
<6>     VE   : 0x44000000 - 0x48ffffff  (  80 MB)
<6>     G2D  : 0x58000000 - 0x58ffffff  (  16 MB)
<6>     LCD  : 0x5a000000 - 0x5bffffff  (  32 MB)
Memory policy: ECC disabled, Data cache writeback
<6>BROM Ver: 1100 1100 1623
<6>chip-id: A10 (AW1623 revision C)
<7>On node 0 totalpages: 262144
<7>free_area_init_node: node 0, pgdat c084a1dc, node_mem_map c090f000
<7>  Normal zone: 1280 pages used for memmap
<7>  Normal zone: 0 pages reserved
<7>  Normal zone: 162560 pages, LIFO batch:31
<7>  HighMem zone: 768 pages used for memmap
<7>  HighMem zone: 97536 pages, LIFO batch:31
<7>pcpu-alloc: s0 r0 d32768 u32768 alloc=1*32768
<7>pcpu-alloc: [0] 0
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 260096
<5>Kernel command line: console=tty0 root=/dev/nandb rootwait loglevel=3 panic=10 disp.screen0_output_mode=EDID:1280x720p60 hdmi.audio=EDID:0 nozswap nortc host=BuildServer restore=nandb home=nandb tce=nandb opt=nandb
<6>PID hash table entries: 4096 (order: 2, 16384 bytes)
<6>Dentry cache hash table entries: 131072 (order: 7, 524288 bytes)
<6>Inode-cache hash table entries: 65536 (order: 6, 262144 bytes)
<6>Memory: 1024MB = 1024MB total
<5>Memory: 899128k/899128k available, 149448k reserved, 393216K highmem
<5>Virtual kernel memory layout:
    vector  : 0xffff0000 - 0xffff1000   (   4 kB)
    fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)
    DMA     : 0xffc00000 - 0xffe00000   (   2 MB)
    vmalloc : 0xe8800000 - 0xf0000000   ( 120 MB)
    lowmem  : 0xc0000000 - 0xe8000000   ( 640 MB)
    pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
    modules : 0xbf000000 - 0xbfe00000   (  14 MB)
      .init : 0xc0008000 - 0xc0036000   ( 184 kB)
      .text : 0xc0036000 - 0xc0807000   (8004 kB)
      .data : 0xc0808000 - 0xc0853af0   ( 303 kB)
       .bss : 0xc0853b14 - 0xc090e868   ( 748 kB)
<6>SLUB: Genslabs=11, HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
<6>NR_IRQS:96 nr_irqs:96 96
<6>timer0: Periodic Mode
<6>Console: colour dummy device 80x30
<6>console [tty0] enabled
<6>Calibrating delay loop... <c>1001.88 BogoMIPS (lpj=5009408)
<6>pid_max: default: 32768 minimum: 301
<6>Mount-cache hash table entries: 512
<6>Initializing cgroup subsys cpuacct
<6>Initializing cgroup subsys devices
<6>Initializing cgroup subsys freezer
<6>Initializing cgroup subsys blkio
<6>CPU: Testing write buffer coherency: ok
<6>hw perfevents: enabled with ARMv7 Cortex-A8 PMU driver, 5 counters available
<6>devtmpfs: initialized
<6>print_constraints: dummy:
<6>NET: Registered protocol family 16
<6>hw-breakpoint: debug architecture 0x4 unsupported.
[ccmu] try to set apb1 parent to sata_pll failed!
SOFTWINNER DMA Driver, (c) 2003-2004,2006 Simtec Electronics
<6>Initialize DMAC OK
<6>bio: create slab <bio-0> at 0
<5>SCSI subsystem initialized
<7>libata version 3.00 loaded.
<6>usbcore: registered new interface driver usbfs
<6>usbcore: registered new interface driver hub
<6>usbcore: registered new device driver usb
<6>Advanced Linux Sound Architecture Driver Version 1.0.24.
<6>Bluetooth: Core ver 2.16
<6>NET: Registered protocol family 31
<6>Bluetooth: HCI device and connection manager initialized
<6>Bluetooth: HCI socket layer initialized
<6>Bluetooth: L2CAP socket layer initialized
<6>Bluetooth: SCO socket layer initialized
Init eGon pin module V2.0
<6>Switching to clocksource aw 64bits couter
<6>cfg80211: Calling CRDA to update world regulatory domain
<5>FS-Cache: Loaded
<6>CacheFiles: Loaded
<6>Switched to NOHz mode on CPU #0
[usb_manager]: CONFIG_USB_SW_SUN4I_USB0_OTG
[sw_hcd0]: usb host driver initialize........
[sw_udc]: udc_init: version 20080411
[sw_udc]: usb_vbase  = 0xf1c13000
[sw_udc]: sram_vbase = 0xf1c00000
[sw_udc]: open_usb_clock
udc->driver is null, udc is need not stop
<6>NET: Registered protocol family 2
<6>IP route cache hash table entries: 32768 (order: 5, 131072 bytes)
<6>TCP established hash table entries: 131072 (order: 8, 1048576 bytes)
<6>TCP bind hash table entries: 65536 (order: 6, 262144 bytes)
<6>TCP: Hash tables configured (established 131072 bind 65536)
<6>TCP reno registered
<6>UDP hash table entries: 512 (order: 1, 8192 bytes)
<6>UDP-Lite hash table entries: 512 (order: 1, 8192 bytes)
<6>NET: Registered protocol family 1
<6>RPC: Registered named UNIX socket transport module.
<6>RPC: Registered udp transport module.
<6>RPC: Registered tcp transport module.
<6>RPC: Registered tcp NFSv4.1 backchannel transport module.
[pm]aw_pm_init!
<6>audit: initializing netlink socket (disabled)
<5>type=2000 audit(0.279:1): initialized
highmem bounce pool size: 64 pages
<5>VFS: Disk quotas dquot_6.5.2
Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
<6>squashfs: version 4.0 (2009/01/31) Phillip Lougher
<6>NTFS driver 2.1.30 [Flags: R/W].
<6>fuse init (API version 7.16)
<6>msgmni has been set to 988
<6>alg: No test for stdrng (krng)
<6>Block layer SCSI generic (bsg) driver version 0.4 loaded (major 253)
<6>io scheduler noop registered
<6>io scheduler deadline registered
<6>io scheduler cfq registered (default)
<6>sunxi disp driver loaded (/dev/disp api 1.0)
<6>Serial: 8250/16550 driver, 8 ports, IRQ sharing disabled
<6>serial8250.0: ttyS0 at MMIO 0x1c28000 (irq = 1) is a U6_16550A
[uart]: used uart info.: 0x05
<6>sunxi-uart.0: ttyS0 at MMIO 0x1c28000 (irq = 1) is a U6_16550A
[uart]: serial probe 0, membase   (null) irq 1 mapbase 0x01c28000
<6>sunxi-uart.2: ttyS1 at MMIO 0x1c28800 (irq = 3) is a U6_16550A
[uart]: serial probe 2, membase   (null) irq 3 mapbase 0x01c28800
<7>G2D: drv_g2d_init
<6>G2D: g2dmem: g2d_start=58000000, g2d_size=1000000
<6>G2D: head:d8000000,tail:d9000000
<6>G2D: Module initialized.major:251
<6>brd: module loaded
<6>loop: module loaded
[NAND]nand driver, init.
cmu_clk is 480
nand clk init end
offset 0xc:  0x26141
offset 0x14:  0x8200000b
[NAND] nand gpio_request
[NAND] nand driver version: 0x2 0x9
nand interrupte register ok
ret of NFC_ChangMode is 0
dma_hdle  is 0
dma_hdle  is 10000008
cmu_clk is 480
nand clk init end
offset 0xc:  0x26141
offset 0x14:  0x82000007
The 0 disk name = DEVICE, class name = NAND, disk start = 0, disk size = 7979008
The 1 disk name = boot, type = 0, class name = DISK, disk size = 1016
The 2 disk name = root, type = 0, class name = DISK, disk size = 0
The 2 disk size = 7977984
part total count = 3
<6> nand: unknown partition table
<6> nanda:
<6> nandb: unknown partition table
<6>benn: nand probe enter
[NAND]nand driver, ok.
<6>sw_ahci sw_ahci.0: controller can't do PMP, turning off CAP_PMP
<4>sw_ahci sw_ahci.0: forcing PORTS_IMPL to 0x1
<6>sw_ahci sw_ahci.0: AHCI 0001.0100 32 slots 1 ports 3 Gbps 0x1 impl platform mode
<6>sw_ahci sw_ahci.0: flags: ncq sntf pm led clo only pio slum part ccc
<6>scsi0 : sw_ahci_platform
<6>ata1: SATA max UDMA/133 mmio [mem 0x01c18000-0x01c18fff] port 0x100 irq 56
<6>wemac Ethernet Driver, V1.01 in file:drivers/net/sun4i/sun4i_wemac.c
<6>[EMAC] ahb clk enable
<6>[EMAC] ahb gate clk: 0x2026141
<6>ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
<6>ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[sw-ehci1]: open clock
[sw-ehci1]: Set USB Power ON
<6>sw-ehci sw-ehci.1: SW USB2.0 'Enhanced' Host Controller (EHCI) Driver
<6>sw-ehci sw-ehci.1: new USB bus registered, assigned bus number 1
<6>sw-ehci sw-ehci.1: irq 39, io mem 0xf1c14000
<6>sw-ehci sw-ehci.1: USB 0.0 started, EHCI 1.00
<6>hub 1-0:1.0: USB hub found
<6>hub 1-0:1.0: 1 port detected
[sw-ohci1]: open clock
<6>sw-ohci sw-ohci.1: SW USB2.0 'Open' Host Controller (OHCI) Driver
<6>sw-ohci sw-ohci.1: new USB bus registered, assigned bus number 2
<6>sw-ohci sw-ohci.1: irq 64, io mem 0xf1c14400
<6>hub 2-0:1.0: USB hub found
<6>hub 2-0:1.0: 1 port detected
[sw-ehci2]: open clock
[sw-ehci2]: Set USB Power ON
<6>sw-ehci sw-ehci.2: SW USB2.0 'Enhanced' Host Controller (EHCI) Driver
<6>sw-ehci sw-ehci.2: new USB bus registered, assigned bus number 3
<6>sw-ehci sw-ehci.2: irq 40, io mem 0xf1c1c000
<6>sw-ehci sw-ehci.2: USB 0.0 started, EHCI 1.00
<6>hub 3-0:1.0: USB hub found
<6>hub 3-0:1.0: 1 port detected
[sw-ohci2]: open clock
<6>sw-ohci sw-ohci.2: SW USB2.0 'Open' Host Controller (OHCI) Driver
<6>sw-ohci sw-ohci.2: new USB bus registered, assigned bus number 4
<6>sw-ohci sw-ohci.2: irq 65, io mem 0xf1c1c400
<6>ata1: SATA link down (SStatus 0 SControl 300)
<6>hub 4-0:1.0: USB hub found
<6>hub 4-0:1.0: 1 port detected
<6>Initializing USB Mass Storage driver...
<6>usbcore: registered new interface driver usb-storage
<6>USB Mass Storage support registered.
<6>usbcore: registered new interface driver ums-alauda
<6>usbcore: registered new interface driver ums-cypress
<6>usbcore: registered new interface driver ums-datafab
<6>usbcore: registered new interface driver ums_eneub6250
<6>usbcore: registered new interface driver ums-freecom
<6>usbcore: registered new interface driver ums-isd200
<6>usbcore: registered new interface driver ums-jumpshot
<6>usbcore: registered new interface driver ums-karma
<6>usbcore: registered new interface driver ums-onetouch
<6>usbcore: registered new interface driver ums-realtek
<6>usbcore: registered new interface driver ums-sddr09
<6>usbcore: registered new interface driver ums-sddr55
<6>usbcore: registered new interface driver ums-usbat
<6>mousedev: PS/2 mouse device common for all mice
sunxi RTC version 0.1
<6>sunxi-rtc sunxi-rtc: sunxi_rtc_probe tmp_data = 380248073
[RTC] ERR: Set LOSC to external failed!!!
[RTC] WARNING: Rtc time will be wrong!!
<6>using rtc device, rtc, for alarms<6>sunxi-rtc sunxi-rtc: rtc core: registered rtc as rtc0
<6>i2c /dev entries driver
!!! base_Addr = 0xe88d4c00
config i2c gpio with gpio_config api
twi0, apb clock = 24000000
<6>axp_mfd 0-0034: AXP (CHIP ID: 0x41) detected
<6>I2C: i2c-0: AW16XX I2C adapter
**********start************
0x40
0xf8
0x28
0x0
0x0
**********end************
!!! base_Addr = 0xe88d6000
twi1, apb clock = 24000000
<6>I2C: i2c-1: AW16XX I2C adapter
**********start************
0x40
0xf8
0x58
0x0
0x0
**********end************
!!! base_Addr = 0xe88d8400
twi2, apb clock = 24000000
<6>I2C: i2c-2: AW16XX I2C adapter
**********start************
0x40
0xf8
0x58
0x0
0x0
**********end************
<6>lirc_dev: IR Remote Control driver registered, major 250
<6>IR NEC protocol handler initialized
<6>IR RC5(x) protocol handler initialized
<6>IR RC6 protocol handler initialized
<6>IR JVC protocol handler initialized
<6>IR Sony protocol handler initialized
<6>IR RC5 (streamzap) protocol handler initialized
<6>IR LIRC bridge handler initialized
<6>Linux video capture interface: v2.00
[cedar dev]: install start!!!
[cedar dev]: install end!!!
[ace_drv] start!!!
[ace_drv] init end!!!
[pa_drv] start!!!
[pa_drv] init end!!!
<6>print_constraints: axp20_ldo1: 1300 mV
<6>print_constraints: axp20_ldo2: 1800 <--> 3300 mV at 3000 mV
<6>print_constraints: axp20_ldo3: 700 <--> 3500 mV at 2800 mV
<6>print_constraints: axp20_ldo4: 1250 <--> 3300 mV at 2800 mV
<6>print_constraints: axp20_buck2: 700 <--> 2275 mV at 1400 mV
<6>print_constraints: axp20_buck3: 700 <--> 3500 mV at 1250 mV
<6>print_constraints: axp20_ldoio0: 1800 <--> 3300 mV at 2800 mV
<6>input: axp20-supplyer as /devices/platform/sun4i-i2c.0/i2c-0/0-0034/axp20-supplyer.28/input/input0
<6>Bluetooth: HCI UART driver ver 2.2
<6>Bluetooth: HCI H4 protocol initialized
<6>Bluetooth: HCI BCSP protocol initialized
<6>Bluetooth: HCILL protocol initialized
<6>cpuidle: using governor ladder
<6>cpuidle: using governor menu
[mmc_pm]: no sdio card used in configuration
[mmc]: sunximmc_init
[mmc]: sunxi mmc controller using config : 0x9
[mmc]: sunxi-mmc.0: pdev->name: sunxi-mmc, pdev->id: 0
[mmc]: mmc 0 power off !!
[mmc]: mmc0 Probe: base:0xe88e0000 irq:32 dma:0 pdes:0xe7bfc000, ret 0.
[mmc]: sunxi-mmc.3: pdev->name: sunxi-mmc, pdev->id: 3
[mmc]: mmc 3 power off !!
[mmc]: mmc3 Probe: base:0xe88e2000 irq:35 dma:0 pdes:0xe7000000, ret 0.
<6>usbcore: registered new interface driver usbhid
<6>usbhid: USB HID core driver
<6>zram: num_devices not specified. Using default: 1
<6>zram: Creating 1 devices ...
enter sun4i Audio codec!!!
<6>sun4i audio support initialized
sun4i Audio codec successfully loaded..
<6>asoc: sndhdmi <-> sun4i-hdmiaudio.0 mapping ok
<6>ALSA device list:
<6>  #0: sun4i-CODEC  Audio Codec
<6>  #1: sun4i-sndhdmi
<6>IPv4 over IPv4 tunneling driver
<6>TCP cubic registered
<6>Initializing XFRM netlink socket
<6>NET: Registered protocol family 10
<6>NET: Registered protocol family 17
<6>NET: Registered protocol family 15
<6>Bluetooth: RFCOMM TTY layer initialized
<6>Bluetooth: RFCOMM socket layer initialized
<6>Bluetooth: RFCOMM ver 1.11
<6>Bluetooth: BNEP (Ethernet Emulation) ver 1.3
<6>Bluetooth: BNEP filters: protocol multicast
<6>802.1Q VLAN Support v1.8
[mmc_pm]: No sdio card, please check your config !!
<6>VFP support v0.3: implementor 41 architecture 3 part 30 variant c rev 3
<5>Registering SWP/SWPB emulation handler
<6>registered taskstats version 1
<6>Console: switching to colour frame buffer device 240x67
<4>regulator_init_complete: axp20_buck3: incomplete constraints, leaving on
<4>regulator_init_complete: axp20_buck2: incomplete constraints, leaving on
<4>regulator_init_complete: axp20_ldo4: incomplete constraints, leaving on
<4>regulator_init_complete: axp20_ldo3: incomplete constraints, leaving on
<4>regulator_init_complete: axp20_ldo2: incomplete constraints, leaving on
<4>regulator_init_complete: axp20_ldo1: incomplete constraints, leaving on
<3>sunxi-rtc sunxi-rtc: hctosys: unable to read the hardware clock
<6>VFS: Mounted root (ext2 filesystem) on device 93:16.
<6>devtmpfs: error mounting -2
<6>Freeing init memory: 184K
<0>Kernel panic - not syncing: No init found.  Try passing init= option to kernel. See Linux Documentation/init.txt for guidance.
Backtrace:
[<c0040fe0>] (dump_backtrace+0x0/0x110) from [<c05ed904>] (dump_stack+0x18/0x1c)
 r6:c006f71c r5:c002e590 r4:c0856cf0 r3:00000000
[<c05ed8ec>] (dump_stack+0x0/0x1c) from [<c05ed97c>] (panic+0x74/0x194)
[<c05ed908>] (panic+0x0/0x194) from [<c0036438>] (init_post+0xa8/0xd8)
 r3:00000000 r2:e7b57900 r1:c0e05ae0 r0:c075d4ac
 r7:00000013
[<c0036390>] (init_post+0x0/0xd8) from [<c0008bac>] (kernel_init+0x18c/0x194)
 r4:c002e590 r3:00000000
[<c0008a20>] (kernel_init+0x0/0x194) from [<c006f71c>] (do_exit+0x0/0x74c)
 r5:c0008a20 r4:00000000
<0>Rebooting in 10 seconds..

Online Rich

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 5237
Re: CubieBoard, Install to NAND
« Reply #6 on: February 12, 2015, 07:06:50 AM »
Hi MapHtH
Quote
Why can't I edit my post?
You can only edit your post if you do it within 30 minutes of posting.

Offline bmarkus

  • Administrator
  • Hero Member
  • *****
  • Posts: 6853
    • My Community Forum
Re: CubieBoard, Install to NAND
« Reply #7 on: February 12, 2015, 09:34:36 AM »
Béla
Ham Radio callsign: HA5DI

"Amateur Radio: The First Technology-Based Social Network."

Offline MapHtH

  • WikiUser
  • *
  • Posts: 28
Re: CubieBoard, Install to NAND
« Reply #8 on: February 13, 2015, 12:11:34 AM »
Oh, ok.

Anyway, if anyone wants to know, I solved it.
I found a way to install and boot everything from nand so if anyone is interested, I can share the files.

The only caveat is the fact that you can't use both sd card and nand because the u-boot will keep looking for boot files on your sd card and won't skip to next boot device once it can't find them.
So, this is useful if you are using the cubieboard as a server for something and don't need too much space (the way I'm using it).

The greatest advantage is that nand is lightning fast compared to sd cards, and if you need fast responses (like if you are using a web server or something like that) it's fantastic.

The only thing now that I'd like to figure out is how to make other arguments in uEnv.txt work because those like nodhcp and tz won't work. They break something and the core ignores all the arguments and boots with defaults without restoring and using even the tce, home, opt and restore arguments.
« Last Edit: February 13, 2015, 12:21:44 AM by MapHtH »

Offline beerstein

  • Hero Member
  • *****
  • Posts: 519
Re: CubieBoard, Install to NAND
« Reply #9 on: February 13, 2015, 02:54:10 AM »
Great to hear that!
I am interested in the files. If possible please e-mail me a zip within a personal message or is it allowed to post them here.?
How did you manage it?
t(w)o be(ers) or not t(w)o be(ers) that is the question

Offline fangis

  • WikiUser
  • *
  • Posts: 37
Re: CubieBoard, Install to NAND
« Reply #10 on: February 13, 2015, 01:42:10 PM »
+1 interested!
well done!
Were you able to keep files in your nand or you had to delete everything to install the linux image?

Offline fangis

  • WikiUser
  • *
  • Posts: 37
Re: CubieBoard, Install to NAND
« Reply #11 on: February 18, 2015, 09:24:13 AM »
Ok , fair enough, you already have been ignored when you asked for help,
and now you enjoy your victory silently ;) I know the feeling.

Anyway I read the info you have shown and it looks straightforward - I will give it a try. If i manage to do a linux install to nand (not necessarily tinycore) I will be happy.
Have you seen also there are ready to use linux images with nand install scripts?
take care

Offline MapHtH

  • WikiUser
  • *
  • Posts: 28
Re: CubieBoard, Install to NAND
« Reply #12 on: February 18, 2015, 09:52:06 AM »
Actually, I've sent you both PM's.

There are a lot of images but there wasn't anything about tiny core and the one with cubian is only for cubian, not for a small distro like dcore.
The only thing that needed to be modified was boot.scr. When I actually used my head, I found out the solution  ;)

You can analyze what's in the script and you can install anything this way, not just tiny core.

However, like I wrote in the PM, you can't keep anything that's on NAND already, you need to back it up and restore it.
I will publish the script here if there is interest and if it isn't against the rules or something. Mods/Admins?
« Last Edit: February 18, 2015, 09:56:27 AM by MapHtH »

Online Rich

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 5237
Re: CubieBoard, Install to NAND
« Reply #13 on: February 18, 2015, 09:59:44 AM »
Hi MapHtH
Quote
I will publish the script here if there is interest and if it isn't against the rules or something. Mods/Admins?
You can attach a script or place it between code tags.

Offline MapHtH

  • WikiUser
  • *
  • Posts: 28
Re: CubieBoard, Install to NAND
« Reply #14 on: February 18, 2015, 11:20:29 AM »
Hi Rick
thanks

Here goes:
Code: [Select]
#!/bin/sh

umount /mnt/nanda
umount /mnt/nandb

wget http://tinycorelinux.net/dCore/armv7/Allwinner-A10/uImage
wget http://tinycorelinux.net/dCore/armv7/Allwinner-A10/uCore

[ -f uEnv.txt ] && rm uEnv.txt
[ -f cubie_nand_uboot_partition_image.bin ] && rm cubie_nand_uboot_partition_image.bin
[ -f boot.scr ] && rm boot.scr
[ -f script.bin ] && rm script.bin

wget http://tinycorelinux.net/dCore/armv7/Allwinner-A10/uEnv.txt
wget http://oldmenatplay.no-ip.biz/files/tinycore/cubie/cubie_nand_uboot_partition_image.bin
wget http://oldmenatplay.no-ip.biz/files/tinycore/cubie/boot.scr
wget http://oldmenatplay.no-ip.biz/files/tinycore/cubie/script.bin

dd bs=4096 if=./cubie_nand_uboot_partition_image.bin of=/dev/nand
sync; sleep 10
sudo rebuildfstab

mkfs.ext4 /dev/nandb
sync; sleep 10
sudo rebuildfstab

mount /dev/nandb
mkdir /mnt/nandb/boot
cp uImage uCore uEnv.txt script.bin boot.scr /mnt/nandb/boot/.
umount /mnt/nandb

It ain't perfect but it works. If anyone has suggestions, feel free to advise :)

I'd like to thank the whole Tiny core team for making Tiny Core and helping me get into the world of Linux. Also, Roberts script helped me to make my own.