Message ID | 20190616113925.3434-2-freifunk@adrianschmutzler.de |
---|---|
State | Accepted |
Headers | show |
diff --git a/build_patches/openwrt/0001-sysupgrade-no-config-save.patch b/build_patches/openwrt/0001-Disable-OpenWrt-config-migration-mechanisms.patch similarity index 61% rename from build_patches/openwrt/0001-sysupgrade-no-config-save.patch rename to build_patches/openwrt/0001-Disable-OpenWrt-config-migration-mechanisms.patch index 0858aff2..884cf953 100644 --- a/build_patches/openwrt/0001-sysupgrade-no-config-save.patch +++ b/build_patches/openwrt/0001-Disable-OpenWrt-config-migration-mechanisms.patch @@ -1,20 +1,26 @@ From: Tim Niemeyer <tim@tn-x.org> Date: Sat, 8 Jul 2017 10:46:59 +0200 -Subject: sysupgrade no config save +Subject: Disable OpenWrt config migration mechanisms + +This disables all OpenWrt config migration mechanisms except for +files listed in /etc/sysupgrade.conf diff --git a/package/base-files/files/sbin/sysupgrade b/package/base-files/files/sbin/sysupgrade -index b75bd097f3..ddcfcd74e4 100755 +index b75bd097f3..8ad778fd69 100755 --- a/package/base-files/files/sbin/sysupgrade +++ b/package/base-files/files/sbin/sysupgrade -@@ -118,7 +118,7 @@ list_changed_conffiles() { +@@ -118,9 +118,9 @@ list_changed_conffiles() { add_uci_conffiles() { local file="$1" ( find $(sed -ne '/^[[:space:]]*$/d; /^#/d; p' \ - /etc/sysupgrade.conf /lib/upgrade/keep.d/* 2>/dev/null) \ + /etc/sysupgrade.conf 2>/dev/null) \ -type f -o -type l 2>/dev/null; - list_changed_conffiles ) | sort -u > "$file" +- list_changed_conffiles ) | sort -u > "$file" ++ ) | sort -u > "$file" return 0 + } + -- 2.11.0
Hallo Adrian,
passt. So hätte mein Patch auch ausgesehen, wenn ich mich nicht zu blöd angestellt hätte. :-D
Ggf. muss man das halt nochmal rebasen, je nachdem ob man sich für oder gegen Patch 1/3 entscheidet.
Reviewed-by: Fabian Bläse <fabian@blaese.de>
Fabian
Applied with rebase. > -----Original Message----- > From: franken-dev [mailto:franken-dev-bounces@freifunk.net] On Behalf Of > Adrian Schmutzler > Sent: Sonntag, 16. Juni 2019 13:39 > To: franken-dev@freifunk.net > Subject: [PATCH 2/3] build_patches: Remove additional config files preserved > during upgrade > > OpenWrt saves additional config (and other) files included with > list_changed_conffiles in /sbin/sysupgrade. > > This is only active since openwrt-18.06, since before that it was > suppressed by missing opkg. > > Since we expect to only save what is in sysupgrade.conf, remove > the additional file list (and thus regain pre-openwrt-18.06 > behavior). > > Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de> > --- > ...0001-Disable-OpenWrt-config-migration-mechanisms.patch} | 14 > ++++++++++---- > 1 file changed, 10 insertions(+), 4 deletions(-) > rename build_patches/openwrt/{0001-sysupgrade-no-config-save.patch => > 0001-Disable-OpenWrt-config-migration-mechanisms.patch} (61%) > > diff --git a/build_patches/openwrt/0001-sysupgrade-no-config-save.patch > b/build_patches/openwrt/0001-Disable-OpenWrt-config-migration- > mechanisms.p > atch > similarity index 61% > rename from build_patches/openwrt/0001-sysupgrade-no-config-save.patch > rename to > build_patches/openwrt/0001-Disable-OpenWrt-config-migration- > mechanisms.pat > ch > index 0858aff2..884cf953 100644 > --- a/build_patches/openwrt/0001-sysupgrade-no-config-save.patch > +++ > b/build_patches/openwrt/0001-Disable-OpenWrt-config-migration- > mechanisms.p > atch > @@ -1,20 +1,26 @@ > From: Tim Niemeyer <tim@tn-x.org> > Date: Sat, 8 Jul 2017 10:46:59 +0200 > -Subject: sysupgrade no config save > +Subject: Disable OpenWrt config migration mechanisms > + > +This disables all OpenWrt config migration mechanisms except for > +files listed in /etc/sysupgrade.conf > > diff --git a/package/base-files/files/sbin/sysupgrade > b/package/base-files/files/sbin/sysupgrade > -index b75bd097f3..ddcfcd74e4 100755 > +index b75bd097f3..8ad778fd69 100755 > --- a/package/base-files/files/sbin/sysupgrade > +++ b/package/base-files/files/sbin/sysupgrade > -@@ -118,7 +118,7 @@ list_changed_conffiles() { > +@@ -118,9 +118,9 @@ list_changed_conffiles() { > add_uci_conffiles() { > local file="$1" > ( find $(sed -ne '/^[[:space:]]*$/d; /^#/d; p' \ > - /etc/sysupgrade.conf /lib/upgrade/keep.d/* 2>/dev/null) \ > + /etc/sysupgrade.conf 2>/dev/null) \ > -type f -o -type l 2>/dev/null; > - list_changed_conffiles ) | sort -u > "$file" > +- list_changed_conffiles ) | sort -u > "$file" > ++ ) | sort -u > "$file" > return 0 > + } > + > -- > 2.11.0 > > -- > 2.11.0
OpenWrt saves additional config (and other) files included with list_changed_conffiles in /sbin/sysupgrade. This is only active since openwrt-18.06, since before that it was suppressed by missing opkg. Since we expect to only save what is in sysupgrade.conf, remove the additional file list (and thus regain pre-openwrt-18.06 behavior). Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de> --- ...0001-Disable-OpenWrt-config-migration-mechanisms.patch} | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) rename build_patches/openwrt/{0001-sysupgrade-no-config-save.patch => 0001-Disable-OpenWrt-config-migration-mechanisms.patch} (61%)