Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FS#2715 - sysupgrade fails no matter what image is given on Raspberry Pi 4 #7510

Closed
openwrt-bot opened this issue Jan 4, 2020 · 2 comments
Closed
Labels

Comments

@openwrt-bot
Copy link

kyli:

sysupgrade stopped working on Raspberry Pi 4 (64-bit ARM) since commit b9f3af7.

BusyBox v1.31.1 () built-in shell (ash)


| |.-----.-----.-----.| | | |.----.| |_
| - || _ | -| || | | || || |
|
_____|| |
||||___||| |____|
|
| W I R E L E S S F R E E D O M

OpenWrt SNAPSHOT, r11811-b9f3af7c89

=== WARNING! =====================================
There is no root password defined on this device!
Use the "passwd" command to set up a new password
in order to prevent unauthorized SSH logins.

root@OpenWrt:/# sysupgrade /tmp/openwrt-brcm2708-bcm2711-rpi-4-squashfs-sysupgra
de.img.gz
Reading partition table from bootdisk...
zcat: write error: Broken pipe
zcat: write: Broken pipe
Reading partition table from image...
Saving config files...
Commencing upgrade. Closing all shell sessions.
{
"error": {
"message": "Firmware image couldn't be validated"
}
}
Command failed: Unknown error
root@OpenWrt:/#

Its parent commit b04ccdb works fine.

BusyBox v1.31.1 () built-in shell (ash)


| |.-----.-----.-----.| | | |.----.| |_
| - || _ | -| || | | || || |
|
_____|| |
||||___||| |____|
|
| W I R E L E S S F R E E D O M

OpenWrt SNAPSHOT, r11810-b04ccdb1e8

=== WARNING! =====================================
There is no root password defined on this device!
Use the "passwd" command to set up a new password
in order to prevent unauthorized SSH logins.

root@OpenWrt:/# sysupgrade /tmp/openwrt-brcm2708-bcm2711-rpi-4-squashfs-sysupgra
de.img.gz
Reading partition table from bootdisk...
zcat: write error: Broken pipe
zcat: write: Broken pipe
Reading partition table from image...
Saving config files...
Commencing upgrade. Closing all shell sessions.
[ 54.993816] reboot: Restarting system

On first generation of Raspberry Pi (32-bit ARM), sysupgrade works past commit b9f3af7.

From the commit message, symptoms observed and the code [[https://lxr.openwrt.org/source/procd/system.c#L588|here]], I'm guessing the upgrade of libubox broke something related to blobmsg, causing error only on certain platforms. (64-bit systems maybe?) This will potentially leave these systems with no easy way to upgrade their firmware.

To reproduce, just build a Raspberry Pi 4 from snapshot image

https://downloads.openwrt.org/snapshots/targets/brcm2708/bcm2711/openwrt-brcm2708-bcm2711-rpi-4-squashfs-factory.img.gz

and then run sysupgrade with

https://downloads.openwrt.org/snapshots/targets/brcm2708/bcm2711/openwrt-brcm2708-bcm2711-rpi-4-squashfs-sysupgrade.img.gz

@openwrt-bot
Copy link
Author

ynezz:

Here is a fix posted for review https://patchwork.ozlabs.org/patch/1217175/ and I would be very grateful if you could test complete patch series https://patchwork.ozlabs.org/project/openwrt/list/?series=150989 (available as procd package version bump here https://gitlab.com/ynezz/openwrt/commit/a4731713fd0de84507d91a2bc504123d1d875ffb) on the RPi-4 and give me your //Tested-by: // if it works, so I can push it soon. More details about the issue can be found here http://lists.infradead.org/pipermail/openwrt-devel/2019-December/020878.html

@openwrt-bot
Copy link
Author

kyli:

Thank you very much for the patch! Tested and works on RPi-4.

BusyBox v1.31.1 () built-in shell (ash)


| |.-----.-----.-----.| | | |.----.| |_
| - || _ | -| || | | || || |
|
_____|| |
||||___||| |____|
|
| W I R E L E S S F R E E D O M

OpenWrt SNAPSHOT, r11887-a4731713fd

=== WARNING! =====================================
There is no root password defined on this device!
Use the "passwd" command to set up a new password
in order to prevent unauthorized SSH logins.

root@OpenWrt:/# sysupgrade /tmp/openwrt-brcm2708-bcm2711-rpi-4-squashfs-sysupgra
de.img.gz
Reading partition table from bootdisk...
zcat: write error: Broken pipe
zcat: write: Broken pipe
Reading partition table from image...
Saving config files...
Commencing upgrade. Closing all shell sessions.
[ 35.185732] EXT4-fs (loop0): re-mounted. Opts: (null)
[ 48.943816] reboot: Restarting system

Tested-by: Kuan-Yi Li kyli@abysm.org

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant