From owner-freebsd-fs@FreeBSD.ORG Sun May 2 14:10:13 2004 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BF34A16A4CE for ; Sun, 2 May 2004 14:10:13 -0700 (PDT) Received: from afields.ca (afields.ca [216.194.67.132]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5519943D4C for ; Sun, 2 May 2004 14:10:13 -0700 (PDT) (envelope-from afields@afields.ca) Received: from afields.ca (localhost.afields.ca [127.0.0.1]) by afields.ca (8.12.6/8.12.9) with ESMTP id i42LABSd035258; Sun, 2 May 2004 17:10:11 -0400 (EDT) (envelope-from afields@afields.ca) Received: (from afields@localhost) by afields.ca (8.12.6/8.12.9/Submit) id i42LAA4n035257; Sun, 2 May 2004 17:10:10 -0400 (EDT) (envelope-from afields) Date: Sun, 2 May 2004 17:10:10 -0400 From: Allan Fields To: Siddharth Aggarwal , Poul-Henning Kamp Message-ID: <20040502211010.GA31553@afields.ca> References: <30551.1083480618@critter.freebsd.dk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <30551.1083480618@critter.freebsd.dk> User-Agent: Mutt/1.4i cc: freebsd-fs@freebsd.org Subject: Re: Debugging pseudo-disk driver on FreeBSD X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Allan Fields List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 May 2004 21:10:13 -0000 On Sun, May 02, 2004 at 08:50:18AM +0200, Poul-Henning Kamp wrote: > In message , 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@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