From: Kyle Moffett <mrmacman_g4@mac.com>
To: Markus Klotzbuecher <mk@creamnet.de>
Cc: "Jörn Engel" <joern@wohnheim.fh-wedel.de>, linux-kernel@vger.kernel.org
Subject: Re: [ANNOUNCE] mini_fo-0.6.0 overlay file system
Date: Thu, 12 May 2005 23:18:36 -0400 [thread overview]
Message-ID: <2F200E69-465D-46ED-9D3A-5ED5C9FEAC9A@mac.com> (raw)
In-Reply-To: <20050512164413.GA14099@mary>
On May 12, 2005, at 12:44:13, Markus Klotzbuecher wrote:
> Hi Joern,
>
> On Thu, May 12, 2005 at 02:18:42PM +0200, Jörn Engel wrote:
>> Just out of curiosity: how do you perform the copy-up operation?
>> In-kernel copies of large files are a huge problem and for union-
>> mount
>> purposes, I'm clueless about how to fix things.
>>
>
> Basically I open the source and the target file on the lower file
> systems for reading and writing respectively, then read and write page
> sized chunks of data until all has been copied. Obviously not ideal
> for large files, but I had no better idea so far.
I've been thinking about a "-o union" mount option for a while now, and
I had a couple ideas on this topic.
1) This system should be a first-class VFS element, IE: -o union should
work on all filesystems, regardless of feature support. (As long as you
can read/write from/to the unioned fs and read from the underlying fs)
2) When forced to copy data, the copy should be done in the context of
whatever process is doing the "write" operation, and be interruptible,
etc. The end result is that if you union an nfs mount over another one,
it will just seem like a write to a big file takes a _really_ long time
to complete.
3) ext2/3 should get an extra flag for files and directories that
indicates nonresidence. This would be used by the VFS union layer to
map existence/nonexistence to the unioned filesystem (If it's ext2/3).
That way, if I later unmounted the unioned ext3 fs and remounted it
elsewhere without the underlying storage, I would be able to access the
parts of the directory structure and files that are resident, and the
rest would fail with a new error code ENONRESIDENT or similar.
For example, if I have two ext3 filesystems on /dev/hdb1 and /dev/hdb2,
then I could do this:
mount -t ext3 -o ro /dev/hdb1 /mnt
mount -t ext3 -o rw,union /dev/hdb2 /mnt
The on-disk structures might look like this:
/dev/hdb1:
foo/
bar => blocks(1-4)
baz => blocks(1-8)
oof/
xuuq => blocks(1-2)
/dev/hdb2:
foo/
bar => sparse,nonresident,blocks(2,4)
baz => sparse,nonresident,blocks(1-4,9-12)
quux => blocks(1-32)
oof/ => nonresident
mumble/
grumble => blocks(1-4)
The resultant view to the user:
/mnt
foo/
bar => blocks(1-4)
baz => blocks(1-12)
quux => blocks(1-32)
oof/
xuuq => blocks(1-2)
mumble/
grumble => blocks(1-4)
If they deleted /dev/hdb1, but still wanted whatever changes they had
made on /dev/hdb2, they could always get at them by remounting /dev/hdb2
somewhere _without_ "-o union", and use a modified tar to package up the
resident portions of files the same way it does for sparse files.
Naturally there would need to be a way to mark a sparse file's empty
spaces as nonresident if so desired when untarring.
Cheers,
Kyle Moffett
-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GCM/CS/IT/U d- s++: a18 C++++>$ UB/L/X/*++++(+)>$ P+++(++++)>$
L++++(+++) E W++(+) N+++(++) o? K? w--- O? M++ V? PS+() PE+(-) Y+
PGP+++ t+(+++) 5 X R? tv-(--) b++++(++) DI+ D+ G e->++++$ h!*()>++$
r !y?(-)
------END GEEK CODE BLOCK------
next prev parent reply other threads:[~2005-05-13 3:18 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-05-09 18:40 Markus Klotzbuecher
2005-05-10 6:07 ` Eric Lammerts
2005-05-10 15:29 ` Lee Revell
2005-05-10 15:42 ` Arjan van de Ven
2005-05-10 17:01 ` Markus Klotzbuecher
2005-05-12 12:18 ` Jörn Engel
2005-05-12 16:44 ` Markus Klotzbuecher
2005-05-13 3:18 ` Kyle Moffett [this message]
2005-05-13 8:01 ` Jörn Engel
2005-05-13 11:26 ` Kyle Moffett
2005-05-13 12:24 ` Jörn Engel
2005-05-13 20:57 ` Kyle Moffett
2005-05-13 12:49 ` Jan Blunck
2005-05-13 20:18 ` Markus Klotzbuecher
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2F200E69-465D-46ED-9D3A-5ED5C9FEAC9A@mac.com \
--to=mrmacman_g4@mac.com \
--cc=joern@wohnheim.fh-wedel.de \
--cc=linux-kernel@vger.kernel.org \
--cc=mk@creamnet.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®