[OpenWrt-Devel] [RFC] Pre-seeded files/directories for UBIFS
Ralph Sennhauser
ralph.sennhauser at gmail.com
Sat May 20 17:04:19 EDT 2017
Hi Richard,
On Sat, 20 May 2017 21:57:36 +0200
Richard Weinberger <richard at nod.at> wrote:
> Ralph,
>
> Am 20.05.2017 um 21:36 schrieb Ralph Sennhauser:
> >>> These days I had an interesting discussion with Christoph about
> >>> overlayfs and its burden. The main use-case of overlayfs in
> >>> combination with UBIFS is having a squashfs as lower and UBIFS as
> >>> upper directory. Such that all changes to the read-only squashfs
> >>> go into UBIFS. Upon a factory reset all files within the UBIFS
> >>> will be removed and the merged directory is clean again.
> >>> Christoph argued that such a functionality could be achieved
> >>> without overlayfs if the filesystem supported something like
> >>> pre-seeded files or directories. This would lower memory
> >>> pressure and complexity.
> >>
> >> As you may know, OpenWrt/LEDE have been using this scheme for many
> >> years now (before it was named overlayfs, this was called mini
> >> fanout overlay ~10 yrs ago) with squashfs + jffs2 before on P-NOR
> >> flashes. There are still devices like those that benefit from
> >> squashfs(ro)+jffs2(rw), so while bringing a similar functionality
> >> using UBIFS exclusively would be interesting, it would still make
> >> Linux distribution want to support a more generic scheme which is
> >> using overlayfs as well.
> >>
> >
> > There is also the size consideration. Unless a seeded ubifs can get
> > close to squashfs in terms of compression there would still be a
> > use-case for squashfs with an ubifs overlay. My current root as
> > ubifs instead of squashfs is 76.8% bigger.
>
> You seem to misunderstand this feature, the goal is not to void all
> uses of squashfs.
> I'm pretty sure for the LEDE usecase squashfs is the better choice.
Probably depends on the device but is beyond the point. Just wanted to
mention in response to the main point being the factory reset of the
squashfs + ubifs overlay setup that size is just as important or even
more important at least for some.
Whether you want to implement and maintain another solution to the
factory reset problem in ubifs which falls short of full snapshot
support is up to you.
Ralph
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
More information about the openwrt-devel
mailing list