Welcome! Log In Create A New Profile

Advanced

After update to u-boot 2016.05-tld-1 on NSA325v1 is not booting

Posted by machnetz 
After update to u-boot 2016.05-tld-1 on NSA325v1 is not booting
November 29, 2016 07:08AM
Hi there,

I've been reading here for a long time and I dared yesterday to change the u-boot from 1.1.4 on one of my two NSA325v1. So I used a serial connection to my Mac and updated the u-boot as described in this article: http://forum.doozan.com/read.php?3,12381 With nandwrite the expected output was right:
Writing data to block 0 at offset 0x0 
Writing data to block 1 at offset 0x20000 
Writing data to block 2 at offset 0x40000 
Writing data to block 3 at offset 0x60000
But now I'm in trouble at step B, after a reboot the system shows the following:
U-Boot 2016.05-tld-1 (Jun 12 2016 - 13:48:40 -0700)
ZyXEL NSA325 2-Bay Power Media Server

SoC:   Kirkwood 88F6282_A1
DRAM:  512 MiB
WARNING: Caches not enabled
NAND:  128 MiB
In:    serial
Out:   serial
Err:   serial
Net:   egiga0
MV88E1318 PHY initialized on egiga0
Hit any key to stop autoboot:  0
starting USB...
USB0:   USB EHCI 1.00
scanning bus 0 for devices... 3 USB Device(s) found
       scanning usb for storage devices... 1 Storage Device(s) found

Partition Map for USB device 0  --   Partition Type: EFI

Part    Start LBA       End LBA         Name
        Attributes
        Type GUID
        Partition GUID
  1     0x00000022      0x0079b15e      "Microsoft basic data"
        attrs:  0x0000000000000000
        type:   ebd0a0a2-b9e5-4433-87c0-68b6b72699c7
        guid:   c1d82d0b-dafe-47ba-a20a-7c116fb4c695
loading envs from usb 0 ...
reading /boot/uEnv.txt
** Unable to read file /boot/uEnv.txt **
Failed to mount ext2 filesystem...
** Unrecognized filesystem type **
Failed to mount ext2 filesystem...
** Unrecognized filesystem type **
Wrong Image Format for bootm command
Error occured, error code = 112
ERROR: can't get kernel image!
stopping USB..

Reset IDE: Bus 0: OK Bus 1: OK
  Device 0: Model: WDC WD10EADS-11M2B2  Firm: 80.00A80 Ser#:  WD-WCAV5D830190
            Type: Hard Disk
            Supports 48-bit addressing
            Capacity: 953869.7 MB = 931.5 GB (1953525168 x 512)
  Device 1: Model: Hitachi HDS721010CLA332  Firm: JP4OA3EA Ser#: JP2911HD188TZC
            Type: Hard Disk
            Supports 48-bit addressing
            Capacity: 953869.7 MB = 931.5 GB (1953525168 x 512)
** File not found /boot/uImage **
** File not found /boot/uInitrd **
Wrong Image Format for bootm command
Error occured, error code = 112
ERROR: can't get kernel image!
resetting ...
So - what where my configs (with the old u-boot from marvel):
cat /etc/fw_env.config
 
# Configuration file for fw_(printenv/saveenv) utility.
# Up to two entries are valid, in this case the redundand
# environment sector is assumed present.
# Notice, that the "Number of sectors" is ignored on NOR.

# MTD device name       Device offset   Env. size       Flash sector size       Number of sectors
# NAND example
/dev/mtd1		0x0000		0x20000		0x20000			4
cat /proc/mtd
 
dev:    size   erasesize  name
mtd0: 00100000 00020000 "uboot"
mtd1: 00080000 00020000 "uboot_env"
mtd2: 00080000 00020000 "key_store"
mtd3: 00080000 00020000 "info"
mtd4: 00a00000 00020000 "etc"
mtd5: 00a00000 00020000 "kernel_1"
mtd6: 02fc0000 00020000 "rootfs1"
mtd7: 00a00000 00020000 "kernel_2"
mtd8: 02fc0000 00020000 "rootfs2"
I'm not shure how I'm flashing now the default u-boot envs into the image. Which are these envs? Which files must located where? Or I'm totally wrong? So it would be great if someone could help me and lead me to the right way ;-)

Kind regards, machnetz



Edited 1 time(s). Last edit at 11/29/2016 07:09AM by machnetz.
Re: After update to u-boot 2016.05-tld-1 on NSA325v1 is not booting
November 29, 2016 03:03PM
machnetz,

> I've been reading here for a long time and I dared
> yesterday to change the u-boot from 1.1.4 on one
> of my two NSA325v1. So I used a serial connection
> to my Mac and updated the u-boot as described in
> this article:
> http://forum.doozan.com/read.php?3,12381 With
> nandwrite the expected output was right:

> Writing data to block 0 at offset 0x0
> Writing data to block 1 at offset 0x20000
> Writing data to block 2 at offset 0x40000
> Writing data to block 3 at offset 0x60000


> U-Boot 2016.05-tld-1 (Jun 12 2016 - 13:48:40
> -0700)
> ZyXEL NSA325 2-Bay Power Media Server
>
> SoC: Kirkwood 88F6282_A1
> DRAM: 512 MiB
> WARNING: Caches not enabled
> NAND: 128 MiB
> In: serial
> Out: serial
> Err: serial
> Net: egiga0
> MV88E1318 PHY initialized on egiga0
> Hit any key to stop autoboot: 0
> starting USB...
> USB0: USB EHCI 1.00
> scanning bus 0 for devices... 3 USB Device(s)
> found
> scanning usb for storage devices... 1
> Storage Device(s) found
>
> Partition Map for USB device 0 -- Partition
> Type: EFI
>
> Part Start LBA End LBA Name
> Attributes
> Type GUID
> Partition GUID
> 1 0x00000022 0x0079b15e "Microsoft
> basic data"
> attrs: 0x0000000000000000
> type:
> ebd0a0a2-b9e5-4433-87c0-68b6b72699c7
> guid:
> c1d82d0b-dafe-47ba-a20a-7c116fb4c695
> loading envs from usb 0 ...
> reading /boot/uEnv.txt
> ** Unable to read file /boot/uEnv.txt **

So far so good. Everything is OK. U-boot has booted successfully.


> Failed to mount ext2 filesystem...
> ** Unrecognized filesystem type **
> Failed to mount ext2 filesystem...
> ** Unrecognized filesystem type **
> Wrong Image Format for bootm command
> Error occured, error code = 112
> ERROR: can't get kernel image!
> stopping USB..
>

Here, your envs are set to boot from USB first. But that USB does not have a Debian rootfs.

> Reset IDE: Bus 0: OK Bus 1: OK
> Device 0: Model: WDC WD10EADS-11M2B2 Firm:
> 80.00A80 Ser#: WD-WCAV5D830190
> Type: Hard Disk
> Supports 48-bit addressing
> Capacity: 953869.7 MB = 931.5 GB
> (1953525168 x 512)
> Device 1: Model: Hitachi HDS721010CLA332 Firm:
> JP4OA3EA Ser#: JP2911HD188TZC
> Type: Hard Disk
> Supports 48-bit addressing
> Capacity: 953869.7 MB = 931.5 GB
> (1953525168 x 512)

So u-boot tried to boot from the HDDs.

> ** File not found /boot/uImage **
> ** File not found /boot/uInitrd **
> Wrong Image Format for bootm command
> Error occured, error code = 112
> ERROR: can't get kernel image!
> resetting ...

The HDD does not have a Debian rootfs on it either.

>So - what where my configs (with the old
> u-boot from marvel):
> cat /etc/fw_env.config
> # Configuration file for fw_(printenv/saveenv)
> utility.
> # Up to two entries are valid, in this case the
> redundand
> # environment sector is assumed present.
> # Notice, that the "Number of sectors" is ignored
> on NOR.
>
> # MTD device name Device offset Env. size
> Flash sector size Number of sectors
> # NAND example
> /dev/mtd1 0x0000 0x20000 0x20000 4


> cat /proc/mtd
> dev: size erasesize name
> mtd0: 00100000 00020000 "uboot"
> mtd1: 00080000 00020000 "uboot_env"
> mtd2: 00080000 00020000 "key_store"
> mtd3: 00080000 00020000 "info"
> mtd4: 00a00000 00020000 "etc"
> mtd5: 00a00000 00020000 "kernel_1"
> mtd6: 02fc0000 00020000 "rootfs1"
> mtd7: 00a00000 00020000 "kernel_2"
> mtd8: 02fc0000 00020000 "rootfs2"

The above are only in effect while you are in Debian.


> I'm not shure how I'm flashing now the default
> u-boot envs into the image. Which are these envs?
> Which files must located where? Or I'm totally
> wrong? So it would be great if someone could help
> me and lead me to the right way ;-)
>

Have you created the Debian rootfs on USB or HDD using this instruction (the USB Debian rootfs must be plugged in before you reboot) :
http://forum.doozan.com/read.php?2,12096

Quote

Updated 20 Feb 2016:

This Debian-4.4.0-kirkwood-tld-1-rootfs-bodhi.tar.bz2 is to keep in sync with kernel Linux-4.4.0-kirkwood-tld-1.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: After update to u-boot 2016.05-tld-1 on NSA325v1 is not booting
December 01, 2016 06:14AM
Hi bodhi,

> Have you created the Debian rootfs on USB or HDD
> using this instruction (the USB Debian rootfs must
> be plugged in before you reboot) :
> http://forum.doozan.com/read.php?2,12096
> 
> 
Quote

Updated 20 Feb 2016: > > This > Debian-4.4.0-kirkwood-tld-1-rootfs-bodhi.tar.bz2 > is to keep in sync with kernel > Linux-4.4.0-kirkwood-tld-1.
Not until my 1st posting. Now I've set up a virtualized Debian8 environment and done the steps above. My uImage creation works good:
root@debian:/boot# mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-4.8.0-kirkwood-tld-1 -d vmlinuz-4.8.0-kirkwood-tld-1 uImage 
Image Name:   Linux-4.8.0-kirkwood-tld-1
Created:      Thu Dec  1 11:17:23 2016
Image Type:   ARM Linux Kernel Image (uncompressed)
Data Size:    3228976 Bytes = 3153.30 kB = 3.08 MB
Load Address: 00008000
Entry Point:  00008000
but the creation of uInitrd is nork working:
root@debian:/boot# mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-4.8.0-kirkwood-tld-1 -d initrd.img-4.8.0-kirkwood-tld-1 uInitrd
mkimage: Can't open initrd.img-4.8.0-kirkwood-tld-1: No such file or directory
I cannot find any file named "initrd.img*" in the shared linux-4.8.0-kirkwood-tld-1-bodhi.tar.bz2 file. This file is not here:
root@debian:/boot# ls -al initrd*
ls: cannot access initrd*: No such file or directory
Have I overlooked something important?
Regards, machnetz
Re: After update to u-boot 2016.05-tld-1 on NSA325v1 is not booting
December 01, 2016 03:30PM
machnetz,

Quote

Not until my 1st posting. Now I've set up a virtualized Debian8 environment and done the steps above. My uImage creation works good:

Don't do it in a VM. Kernel installation should be done in the live system.

After you've created the rootfs 4.4, plug it in the NSA325 box and boot with it. While logging in Debian, install kernel 4.8.3 (or 4.8.0) with

cd /boot
dpkg -i linux-image-4.8.3-kirkwood-tld-1_1.0_armel.deb

Now the initrd and vmlinuz will be available in /boot. And then do the mkimage for both uImage and uInitrd.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: After update to u-boot 2016.05-tld-1 on NSA325v1 is not booting
December 01, 2016 03:47PM
Hi bodhi,

Now the initrd and vmlinuz will be available in /boot. And then do the mkimage for both uImage and uInitrd.
Thx, ok - I'll try/do/check this it at the weekend.

machnetz
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: