[OpenWrt-Devel] [RFC PATCH] sysupgrade: introduce compatibility version for devices

Adrian Schmutzler mail at adrianschmutzler.de
Fri Jun 5 12:25:13 EDT 2020



On 5 June 2020 14:27:24 CEST, "Bjørn Mork" <bjorn at mork.no> wrote:
>I haven't even bother to try to write any code to see if this is
>feasible, but anyway...
>
>I wonder if there might be more flexible and user-friendly ways to
>handle upgrade incompatibilities if we are allowed to use code/metadata

I see the appeal of this idea, but executing _code_ from an image before it's properly verified sounds like a security issue to me. 

>from the new image in the sysupgrade process?  Instead of just
>providing
>a version number with some simple semantics like you describe, the new
>image could provide a script snippet or similar which codifies a more
>precise description of the incompatibility. And even a solution, if
>there is one.

Sounds a little too much for my taste at first look. 

>
>For the DSA example, such a script could (optionally?) move an
>incompatible config/network out of the way, while leaving all other
>settings untouched.  Preserving e.g. wireless config has a lot of
>value.

We don't even have a general conversion script for DSA, and I don't think there will be much desire to provide and maintain individual solutions. Partial config preservation will be even more work, particularly since packages will add them in an unforeseeable way. 

So, providing a warning seems achievable to me, and everything beyond could be provided via other resources (e.g. in the Wiki), as the educated (and warned) user could always force-flash and copy an external script just aiming at e.g. DSA migration... 

But thanks for your input, I'm actually still widening my view on this. 

Best

Adrian

>With the possibily to cancel the upgrade, it would even attempt an
>incomplete conversion.  IMHO, the main reason we can't do automatic DSA
>conversion is because there will be failures.  But this isn't critical
>if it is detected prior to upgrading.
>
>Just a few random thoughts.  Since you are about to fundamentally
>improve sysupgrade anyway ;-)
>
>
>Bjørn
>
>_______________________________________________
>openwrt-devel mailing list
>openwrt-devel at lists.openwrt.org
>https://lists.openwrt.org/mailman/listinfo/openwrt-devel

_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


More information about the openwrt-devel mailing list