Subject: Re: FFS journal (mounting just a sub-directory from a filesystem)
To: der Mouse <mouse@Rodents.Montreal.QC.CA>
From: Greg A. Woods <woods@weird.com>
List: tech-kern
Date: 07/23/2006 16:27:15
--pgp-sign-Multipart_Sun_Jul_23_16:27:12_2006-1
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: quoted-printable

At Sat, 22 Jul 2006 16:27:37 -0400 (EDT),
der Mouse wrote:
>=20
> Altneratively...some time ago, I wrote code that allows me to mount an
> FFS such that the directory that becomes the mount-point root is not
> necessarily the root of the filesystem in the partition.  For example,
> if I have a parititon containing an all-in-one-partition NetBSD
> install, I could mount just its /usr subtree somewhere.

That's a really cool idea!  I've thought in more abstract terms about
something similar ever since I was first exposed to unix.

> This is relevant because there's no reason why we couldn't have a
> journaling FFS set up such that the root of the on-disk filesystem
> contains, say, directories "deleted" and "root", and then have
> "deleted" used internally with "root" being the root of what you see
> when it's mounted.  No hacks to fsck_ffs required; all that changes is
> the mount code, so that when mounted journaled, those two directories
> are required and handled appropriately.  Oh, and newfs_ffs should
> probably be made capable of pre-creating those directories.

Indeed in this application your idea sounds like a perfect solution.

--=20
						Greg A. Woods

H:+1 416 218-0098 W:+1 416 489-5852 x122 VE3TCP RoboHack <woods@robohack.ca>
Planix, Inc. <woods@planix.com>       Secrets of the Weird <woods@weird.com>

--pgp-sign-Multipart_Sun_Jul_23_16:27:12_2006-1
Content-Type: application/pgp-signature
Content-Transfer-Encoding: 7bit

-----BEGIN PGP SIGNATURE-----
Version: PGPfreeware 5.0i for non-commercial use
MessageID: DYipTGyD8wWt6o8jLltw7rBrkQejVLjn

iQA/AwUBRMPbomJ7XxTCWceFEQL8OACg6PFHeMsj2KeY8JSXp2ALILcyJ6sAoIwL
hrn09rF7XuSAvLNLAkmsRZHj
=PMSv
-----END PGP SIGNATURE-----

--pgp-sign-Multipart_Sun_Jul_23_16:27:12_2006-1--