New OpenWrt rootfs format: ubifs volume with squashfs & overlay dir

Rafał Miłecki zajec5 at gmail.com
Mon Jan 3 03:21:01 PST 2022


On some UBI-aware devices, firmware file can contain only kernel & 1
UBI volume. It means we can't use:
1. rootfs UBI volume with squashfs
2. rootfs_data UBI volume with ubifs (for overlay)

Note: creating rootfs_data dynamically is not an option as that
wouldn't be wiped out properly while flashing new firmware with
bootloader.


The only solution idea we have is to build ubifs volume with:
1. /root.squashfs
2. /overlay/
and include such ubifs volume in firmware image file for selected devices.

That of course will require initramfs with user-space handling mounting above.

I'm planning to start working on that now. If anyone is willing to
help that's highly appreciated as I'm not well familiar with that
topic. If you can think of any better / simpler solution, please let
me know *now*.


Above solution suggested by Olivier in the e-mail thread:
Identifying UBI volume instance / storing UBI volume metadata
http://lists.openwrt.org/pipermail/openwrt-devel/2021-December/037308.html

My previous request for help in e-mail:
rootfs_data on UBI-aware devices
http://lists.openwrt.org/pipermail/openwrt-devel/2021-December/037304.html
didn't result in any ideas.

--
Rafał



More information about the linux-mtd mailing list