From: Lou K. <lou...@gm...> - 2004-12-06 17:59:57
|
On Mon, 6 Dec 2004 18:02:35 +0100, Carlo Perassi <ca...@li...> wrote: > Hi. > I develop knopILS [1] a free software only italian variant of KNOPPIX. > Reading this article [2], I started thinking that fuse would be a good > candidate to do what Fabian Franz call an "overlay filesystem". > In a live-cd like KNOPPIX, you can't install program in (for example) > "/usr" because it is read only so, using the words of Franz, with an > "overlay fs" > > "You can overlay /usr with /ramdisk/usr, and although you can read all > files that lie in /usr, all file writes go to /ramdisk/usr." > > He lists four software that can do that job but they all have their > drawbacks. > Maybe fuse could be used to implement this "overlay fs" so I downloaded > it and tried the very first example (./fusexmp /mnt/test/ -d). On a > read-only folder in /mnt/test I expected it fails to touch a file but it > did. Anyway this is my first hour with fuse so it's not strange to have > to learn. > I'd like to know (apart from this little problem with touch) if you > think fuse could be helpful in such a project or something like this > already exists or could be modified to do the job. > Thanks a lot. I'd call that unioning. You can union anything you want into a destination which can be on tmp/ramdisk/wherever you want. mount -bind is no good, freebsd unionfs [1] is okay. i tried doing unioning with fuse, but you can guess what will happen when the binds grow. nevertheless its doable, if you dont get into the loop of what replaces what and what over what. The code for fuse should be very simple, forward all the writes to the ramdisk space. I think you can achieve that with modifying the fuse example. It could be done with FiST as well. [2] 9bind from v9fs would do the job very well. [3] but i dont think its ready. best, l 1. http://www.freebsd.org/cgi/man.cgi query=mount_unionfs&sektion=8&apropos=0&manpath=FreeBSD+5.3-RELEASE+and+Ports 2. http://www.filesystems.org/ 3. http://v9fs.sourceforge.net/ |