I've got a pogoplug E02 that's been happily running ALARM since installed back in 2013 (important as this is prior to the new U-Boot). It's running the latest linux-kirkwood kernel, 4.4.219-1-ARCH.
Today, on reboot after pacman updates, haveged service failed to start. In diagnosing the haveged issue, I found that there is alternative kernel, linux-kirkwood-dt, but, as the PKGBUILD states, this kernel requires a new version of U-Boot.
Looking at U-Boot, I went ahead and installed the uboot-pogo_e02 package and said yes to flashing the update to NAND:
$this->bbcode_second_pass_code('', '
A new U-Boot version needs to be flashed to NAND.
Do you want to do this now? [y|N]
y
Erasing 128 Kibyte @ 60000 -- 100 % complete
Erasing 128 Kibyte @ c0000 -- 100 % complete
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
Writing data to block 6 at offset 0xc0000
')
On reboot, the pogoplug is unresponsive.
I got netconsole working, here's what it says:
$this->bbcode_second_pass_code('', '
U-Boot 2016.09.01-1 (Oct 10 2016 - 23:12:58 -0600) Arch Linux ARM
Pogo E02
gcc (GCC) 6.2.1 20160830
GNU ld (GNU Binutils) 2.27
Hit any key to stop autoboot: 0
starting USB...
USB0: USB EHCI 1.00
scanning bus 0 for devices... 4 USB Device(s) found
scanning usb for storage devices... 1 Storage Device(s) found
USB device 0:
Device 0: Vendor: SanDisk Rev: 1.26 Prod: Cruzer Fit
Type: Hard Disk
Capacity: 15267.0 MB = 14.9 GB (31266816 x 512)
... is now current device
usb found on device 0
Checking for: /boot/uEnv.txt ...
** File not found /boot/zImage **
4623320 bytes read in 353 ms (12.5 MiB/s)
loading /boot/dtbs/kirkwood-pogo_e02.dtb ...
** File not found /boot/dtbs/kirkwood-pogo_e02.dtb **
7764291 bytes read in 486 ms (15.2 MiB/s)
Booting uImage with initrd
## Booting kernel from Legacy Image at 00810000 ...
Image Name: Linux-4.4.219-1-ARCH
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 4623256 Bytes = 4.4 MiB
Load Address: 00008000
Entry Point: 00008000
Verifying Checksum ... OK
')
And that's it.
I've read thru many forum posts and the closest issue I found was https://archlinuxarm.org/forum/viewtopic.php?f=53&t=7742&start=10. As mentioned there, I mounted the drive (USB flash) on a different computer and used journalctl to see if the kernel was booting and what activity might have been logged, but nothing has been logged since the journal stopped when I rebooted after U-Boot flashed to NAND. While mounted, I also confirmed that /boot/uImage is identical the same file from the package.
Here's the U-Boot env from netconsole (with some value redacted):
$this->bbcode_second_pass_code('', '
bootcmd=run startboot;run bootubi
bootdir=/boot
bootfilem=uImage
bootfilez=zImage
bootubi=echo Trying to boot from NAND ...;if run mountubi; then ubifsload ${loadaddr} /boot/zImage;ubifsload ${fdtaddr} /boot/dtbs/${fdtfile};ubifsumount; setenv bootargs console=${console} ubi.mtd=1 root=ubi0:rootfs ro rootfstype=ubifs rootwait ${mtdparts};bootz ${loadaddr} - ${fdtaddr};fi
console=ttyS0,115200
ethact=egiga0
fdtaddr=0x800000
fdtdir=/boot/dtbs
fdtfile=kirkwood-pogo_e02.dtb
loadaddr=0x810000
loadfdt=echo loading ${fdtdir}/${fdtfile} ...; load ${devtype} ${bootpart} ${fdtaddr} ${fdtdir}/${fdtfile}
loadimage=load ${devtype} ${bootpart} ${loadaddr} ${bootdir}/${bootfilez} || load ${devtype} ${bootpart} ${loadaddr} ${bootdir}/${bootfilem}
loadrd=load ${devtype} ${bootpart} ${rdaddr} ${bootdir}/${rdfile}
mainargs=setenv bootargs console=${console} ${mtdparts} root=${root} rw rootwait ${optargs} ${ncargs}
mountubi=ubi part rootfs; ubifsmount ubi0:rootfs
mtdids=nand0=orion_nand
mtdparts=mtdparts=orion_nand:1M(u-boot),-(rootfs)
ncip=10.10.10.5
ncipk=10.10.10.4
netconsole=on
rdaddr=0x1100000
rdfile=initramfs-linux.img
startboot=usb start; for devtype in usb ; do setenv devnum 0; while ${devtype} dev ${devnum}; do echo ${devtype} found on device ${devnum}; setenv bootpart ${devnum}:1; echo Checking for: ${bootdir}/uEnv.txt ...; if test -e ${devtype} ${bootpart} ${bootdir}/uEnv.txt; then load ${devtype} ${bootpart} ${loadaddr} ${bootdir}/uEnv.txt; env import -t ${loadaddr} ${filesize}; echo Loaded environment from ${bootdir}/uEnv.txt; echo Checking if uenvcmd is set ...; if test -n ${uenvcmd}; then echo Running uenvcmd ...; run uenvcmd; fi; fi; if run loadimage; then if env exists root; then echo root has been defined by user; else part uuid ${devtype} ${bootpart} uuid; setenv root PARTUUID=${uuid}; fi; run mainargs; if run loadfdt; then if run loadrd; then bootz ${loadaddr} ${rdaddr}:${filesize} ${fdtaddr}; else bootz ${loadaddr} - ${fdtaddr}; fi; else if run loadrd; then echo Booting uImage with initrd; bootm ${loadaddr} ${rdaddr}:${filesize}; else bootm ${loadaddr}; fi; fi; else echo No kernel found; fi; setexpr devnum ${devnum} + 1; done; done;
ethaddr=00:xx:xx:xx:xx:xx
serverip=xxx.xxx.xxx.xxx
ipaddr=xxx.xxx.xxx.xxx
if_netconsole=ping $serverip
start_netconsole=setenv ncip $serverip; setenv bootdelay 10; setenv stdin nc; setenv stdout nc; setenv stderr nc; version;
preboot=run if_netconsole start_netconsole
')
Note that the correct ethaddr is set in the env.
Is there anything I can do from netconsole to see where things are failing? Kernel command line?
TIA