[PATCH] x86: check for gpt header in platform_check_image
Jonas Lochmann
openwrt at jonaslochmann.de
Wed Jan 14 11:40:03 PST 2026
Am Mon, Jan 12, 2026 at 04:36:11PM -0700, schrieb Philip Prindeville:
> While you're in there, can you fix the partition table stuff so that /var can be made persistent?
That's completly unrelated to this topic.
> Possibly adding a package that converts a system that didn't have a
> persistent /var to one that creates a partition out of the remaining
> free space, formats it, creates the appropriate subdirectories, and
> writes out an /etc/fstab entry...
That's a very bad design idea. This is a very bad fit for an extra
package and adjusting the partition layout by installing a package
is a bad idea like programatically updating the fstab file. We
don't have systemd and its mount units here, but there are other
methods to mount something.
The traditional GPT is too unflexible for that - the OpenWrt image
size could change. Or you have your custom partition first and OpenWrt
in the end so that shrinking the extra partition later is possible.
So to make the extra partition possible, the sysupgrade process
would need to extract the new efi and system partition to replace
this partitions only. Then you can do what you want with the
remaining disk - as long as no one increases the partition sizes
because updates would fail then.
More information about the openwrt-devel
mailing list