Re: Overlay writable filesystem over r/o partition [long]

Theodore Y. Ts'o (tytso@MIT.EDU)
Tue, 6 Jan 1998 15:52:48 -0500


Date: Mon, 05 Jan 1998 21:39:53 -0800
From: Ben Woodard <bwoodard@cisco.com>

You might want to take a look at a copy of "The design and
implemtation of the BSD 4.4 operating system." by Marshall Kirk
McKusick. I took a class about the interals of BSD from him last
semester and I will be taking the second semester of it starting in a
couple of weeks and there are many more things to consider when
stacking file systems on top of each other than you addressed. This is
not to say that you don't have a good idea. It is one thing that I
have sort targeted to implement in linux once I have come to
understand the linux source as well as I understand BSD. The
discussion in Kirk McKusick's book about stackable file systems is
quite good and covers most of the things that you need to consider in
implemting a system. They did a really good job in BSD they found that
they could stack file systems about 100 deep without much
overhead. Other attempts at stackable file systems such as Sun's
"Spring" operating system had abysmal performace at about 7 levels
deep. If you are truly interested. I wouldn't mind re-reading the
chapter and summarizing it for you.

It would be really, really, cool if someone could try to implement BSD's
unionfs for Linux. It's a really nice feature that we're missing in
Linux today.

About the only ugly part of BSD's unionfs is that it requires libc
support to avoid duplicate names from readdir(). The problem with doing
this in the kernel is that it's really hard to have the kernel throw out
duplicate names. (You can do it, but it would require lots of memory
allocations, which you'd really rather not do in the kernel.)

- Ted