Quantcast
Channel: Linux Device Hacking
Viewing all articles
Browse latest Browse all 3247

[Dockstar] Installing Debian without rescue image (1 reply)

$
0
0
Hey there,

I had Arch Linux running on my old Dockstar for a long time. But since a couple of years the box was stored in the shelf and I cannot find the USB storage device any longer. So I was trying to install Debian on a usb key and boot it but without success. I have access to the serial console and also managed to setup the netconsole for uboot.

The current uboot environment reads like:
arcNumber=2097
baudrate=115200
bootargs=console=ttyS0,115200 root=/dev/sda1 rootdelay=10 rootfstype=ext2 mtdparts=orion_nand:1M(u-boot),4M(uImage),32M(rootfs),-(data) loglevel=7 netconsole=6666@192.168.178.200/eth0,6666@192.168.178.215/00:24:d7:4e:af:1c
bootcmd=run bootcmd_usb; usb stop; run rescue_bootcmd; reset
bootdelay=10
console=ttyS0,115200
ethact=egiga0
ethaddr=00:10:75:1A:DC:CE
fileaddr=1000000
filesize=1BA0000
force_rescue=0
force_rescue_bootcmd=if test $force_rescue -eq 1 || ext2load usb 0:1 0x1700000 /rescueme 1 || fatload usb 0:1 0x1700000 /rescueme.txt 1; then run rescue_bootcmd; fi
if_netconsole=ping $serverip
init=/usr/lib/systemd/systemd
ipaddr=192.168.178.200
led_error=orange blinking
led_exit=green off
led_init=green blinking
mainlineLinux=yes
mtdids=nand0=orion_nand
mtdparts=mtdparts=orion_nand:1M(u-boot),4M(uImage),32M(rootfs),-(data)
ncip=192.168.178.100
partition=nand0,2
pogo_bootcmd=if fsload uboot-original-mtd0.kwb; then go 0x800200; fi
preboot=run if_netconsole start_netconsole
rescue_bootcmd=if test $rescue_installed -eq 1; then run rescue_set_bootargs; nand read.e 0x800000 0x100000 0x400000; bootm 0x800000; else run pogo_bootcmd; fi
rescue_installed=0
rescue_set_bootargs=setenv bootargs console=$console ubi.mtd=2 root=ubi0:rootfs ro rootfstype=ubifs $mtdparts $rescue_custom_params
serverip=192.168.178.100
start_netconsole=setenv ncip $serverip; setenv bootdelay 10; setenv stdin nc; setenv stdout nc; setenv stderr nc; version;
stderr=nc
stdin=nc
stdout=nc
ubifs_bootcmd=run ubifs_set_bootargs; if ubi part data && ubifsmount rootfs && ubifsload 0x800000 /boot/uImage && ubifsload 0x1100000 /boot/uInitrd; then bootm 0x800000 0x1100000; fi
ubifs_mtd=3
ubifs_set_bootargs=setenv bootargs console=$console ubi.mtd=$ubifs_mtd root=ubi0:rootfs rootfstype=ubifs $mtdparts $ubifs_custom_params
usb=0:1
usb_boot=mw 0x800000 0 1; ext2load usb $usb_device 0x800000 /boot/uImage; if ext2load usb $usb_device 0x1100000 /boot/uInitrd; then bootm 0x800000 0x1100000; else bootm 0x800000; fi
usb_bootcmd=run usb_init; run usb_set_bootargs; run usb_boot
usb_custom_params=loglevel=7 netconsole=6666@192.168.178.200/eth0,6666@192.168.178.215/00:24:d7:4e:af:1c
usb_device=0:1
usb_init=run usb_scan
usb_root=/dev/sda1
usb_root_label=my-rootfs
usb_rootdelay=10
usb_rootfs=UUID=d65382b6-c396-4a42-a42e-512e25edb2af
usb_rootfstype=ext2
usb_scan=usb_scan_done=0;for scan in $usb_scan_list; do run usb_scan_$scan; if test $usb_scan_done -eq 0 && ext2load usb $usb 0x800000 /boot/uImage 1; then usb_scan_done=1; echo "Found bootable drive on usb $usb"; setenv usb_device $usb; setenv usb_root /dev/$dev; fi; done
usb_scan_1=usb=0:1 dev=sda1
usb_scan_2=usb=1:1 dev=sdb1
usb_scan_3=usb=2:1 dev=sdc1
usb_scan_4=usb=3:1 dev=sdd1
usb_scan_list=1 2 3 4
usb_set_bootargs=setenv bootargs console=$console root=$usb_root rootdelay=$usb_rootdelay rootfstype=$usb_rootfstype $mtdparts $usb_custom_params

When I execute run usb_boot I receive:
Loading file "/boot/uImage" from usb device 0:1 (usbda1)
Failed to mount ext2 filesystem...
** Bad ext2 partition or disk - usb 0:1 **
Loading file "/boot/uInitrd" from usb device 0:1 (usbda1)
Failed to mount ext2 filesystem...
** Bad ext2 partition or disk - usb 0:1 **
Wrong Image Format for bootm command
ERROR: can't get kernel image!

The usb device has been prepared with an ext2 filesystem and I copied https://github.com/pepaslabs/bodhi-kirkwood-rootfs-mirror/releases/tag/4.12.1 onto it.

Any ideas what I should do/check?

Cheers
Oleg

P.S. Forgot to mention that the device is currently not booting anything. When I just let uboot run through I get
U-Boot 2011.12 (Feb 12 2012 - 21:33:07)
Seagate FreeAgent DockStar
arm-none-linux-gnueabi-gcc (Sourcery G++ Lite 2009q3-67) 4.4.1
GNU ld (Sourcery G++ Lite 2009q3-67) 2.19.51.20090709
Hit any key to stop autoboot:  0 
## Error: "bootcmd_usb" not defined
stopping USB..
### JFFS2 loading 'uboot-original-mtd0.kwb' to 0x800000
Scanning JFFS2 FS: ........  read_nand_cached: error reading nand off 0x1348400 size 8192 bytes
read_nand_cached: error reading nand off 0x1480000 size 8192 bytes                                                                     done.
read_nand_cached: error reading nand off 0x1348c00 size 8192 bytes
### JFFS2 load complete: 524288 bytes loaded to 0x800000
## Starting application at 0x00800200 ...

Viewing all articles
Browse latest Browse all 3247

Trending Articles