Debugging pseudo-disk driver on FreeBSD
Allan Fields
bsd at afields.ca
Sun May 2 14:10:13 PDT 2004
On Sun, May 02, 2004 at 08:50:18AM +0200, Poul-Henning Kamp wrote:
> In message <Pine.GSO.4.50L0.0405020024040.23508-100000 at faith.cs.utah.edu>, Siddharth Aggarwal writes:
> >
> >Hi,
> >
> >I am working on a Copy on Write disk driver on FreeBSD where I try to save
> >the state of a filesystem (/dev/ad0s3) to another device (/dev/ad0s4) by
> >making a virtual device that sits on top of these two (/dev/shd0).
>
> Are you doing this using GEOM under FreeBSD 5 ? If not you should start
> doing that now.
>
> --
> Poul-Henning Kamp | UNIX since Zilog Zeus 3.20
> phk at FreeBSD.ORG | TCP/IP since RFC 956
> FreeBSD committer | BSD since 4.3-tahoe
> Never attribute to malice what can adequately be explained by incompetence.
I agree that this should be a GEOM-based facility if it is targeted to
FreeBSD-5 as a device-level driver.
Additionally, there is the possibility to do this at the vnode level
using unions/overlays where heterogenous filesystem layouts are a
possibility. Vnode and device-level solutions both have their owm
merits. (What's also worth noting is the similarities in the two
approaches.)
For a copy-on-write scheme you might just as easily employ a union
mount as outlined in [1]. A previous post was made to this list
[2] on the topic of overlays and FreeBSD's union filesystem a while
back. Discussed in the thread is the need for heterogenous layouts.
Vnode-stacking allows rich semantics and operates above the filesystem
layer. I was attempting to make an argument for enhanced namespace
semantics.
While you may be able to find some interesting papers with regards
to vnode-stacking approaches to overlays at http://www.filesystems.org,
the fistgen template code is still in need of some work on the
FreeBSD side.
[1] J. S. Pendry, M. K Mckusick. Union Mounts in 4.4BSD-Lite.
USENIX Conference Proc. January 1995.
[2] [freebsd-fs] Re: Overlayfs for FiST?
(http://lists.freebsd.org/pipermail/freebsd-fs/2003-April/000090.html)
--
Allan Fields
Afields Research/AFRSL - http://afields.ca
BSDCan: May 2004, Ottawa - http://www.bsdcan.org
More information about the freebsd-fs
mailing list