UCI config migration across OpenWrt releases
Eric
evil.function at proton.me
Tue Apr 14 09:31:53 PDT 2026
On Tuesday, April 14th, 2026 at 06:18, Tanjeff Moos <Tanjeff.Moos at westermo.com> wrote:
> On 4/14/26 01:58, Eric wrote:
> > For the most part, crossing one version works just fine. Most
> > packages these days use a uci-defaults script to upgrade their
> > config if there are any changes, although of course you'll no
> > doubt find exceptions somewhere.
>
> As I understand it, uci-default scripts run only on first boot (after a
> factory reset) and are then deleted. How can they run during/after an
> upgrade?
>
> Regards, Tanjeff
>
Hi Tanjeff,
The post install script fires off some actions that run any new
package-specific uci-defaults that were delivered in the package.
Scan down to the middle of this function, you'll see where it
picks them up, right after it handles any kmods and applies the
sysctl settings...
https://github.com/openwrt/openwrt/blob/main/package/base-files/files/lib/functions.sh#L377
Eric
More information about the openwrt-devel
mailing list