I am new to OpenWRT and not finding an answer to this. I have a reRouter CM4 1432 that came with 32GB of eMMC onboard storage. I flashed the drive with the latest release from the instructions from Seeed and I have a couple of questions.
Q1: Of the 32GB eMMC on the CM4. I am only using 3.71GiB, How do I expand the storage to use all of the storage?
Q2: It looks like there an update to 22.03.2, but when I extract the image from the gz file, it tells me this:
There are some data after the end of the payload data : openwrt-22.03.2-bcm27xx-bcm2711-rpi-4-squashfs-sysupgrade.img
If I try to upload the image, I this:
Image check failed:
Mon Nov 28 22:11:49 EST 2022 upgrade: Image metadata not present Mon Nov 28 22:11:49 EST 2022 upgrade: Use sysupgrade -F to override this check when downgrading or flashing to vendor firmware Mon Nov 28 22:11:49 EST 2022 upgrade: Reading partition table from bootdisk... cat: write error: Broken pipe Mon Nov 28 22:11:49 EST 2022 upgrade: Reading partition table from image... Partition layout has changed. Full image will be written. Image check failed.
So not a vanilla OpenWrt, but some vendor customized version.
Don't extract it, there is image meta-data attached to the end of the file - which indeed looks like garbage to gzip, but is nevertheless wanted by sysupgrade.
…as you can see here.
sysupgrade wants the compressed image file as-is, unmodified, with meta-data intact, just as you downloaded it.
I did not know that either. Does that apply to the usage of factory images of OpenWRT as well?
As at least some OpenWRT factory gz files have that as well.
The 'big' PC like targets with removable media support (x86, RPi, sunxi, rochchip, etc.) usually don't distinguish between factory and sysupgrade images, but ship combined ones instead. Decompress (ignore gzip's whining about the trailing garbage) and dd/ cat to a raw block device for the initial installation, sysupgrade the compressed file as-is for upgrading.