[RFC] Pre-seeded files/directories for UBIFS

Richard Weinberger richard at nod.at
Sat May 20 11:48:18 PDT 2017


Am 20.05.2017 um 20:39 schrieb Florian Fainelli:
> Hello,
> On 05/20/2017 09:12 AM, Richard Weinberger wrote:
>> Hi!
>> 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.

UBIFS will still support overlayfs and adding a pre-seed mechanism
to UBIFS will not block generic solutions.
Maybe we can add a generic interface to VFS at some point if other filesystems
support that too. :-)


More information about the linux-mtd mailing list