From owner-freebsd-current@FreeBSD.ORG Tue Nov 2 21:00:09 2004 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B050516A4CF for ; Tue, 2 Nov 2004 21:00:09 +0000 (GMT) Received: from smtp.cegetel.net (mf00.sitadelle.com [212.94.174.77]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4998943D5C for ; Tue, 2 Nov 2004 21:00:09 +0000 (GMT) (envelope-from tataz@sitadelle.com) Received: from droopy.tech.sitadelle.com (213-223-184-193.dti.cegetel.net [213.223.184.193]) by smtp.cegetel.net (Postfix) with ESMTP id CD03E6718C; Tue, 2 Nov 2004 22:00:07 +0100 (CET) Received: by droopy.tech.sitadelle.com (Postfix, from userid 1000) id 6F222FC00E; Tue, 2 Nov 2004 22:00:23 +0100 (CET) Date: Tue, 2 Nov 2004 22:00:23 +0100 From: Jeremie Le Hen To: Jeremie Le Hen Message-ID: <20041102210023.GM10641@sitadelle.com> References: <27404.1099146185@critter.freebsd.dk> <4183A771.7080906@liwing.de> <20041102130412.GI10641@sitadelle.com> <20041102122439.J33456@sasami.jurai.net> <20041102174632.GL10641@sitadelle.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20041102174632.GL10641@sitadelle.com> User-Agent: Mutt/1.5.6+20040907i cc: current@freebsd.org Subject: Re: HEADSUP: Filesystem rototiling over X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 02 Nov 2004 21:00:09 -0000 > > Why not use the -F option of mount(8)/umount(8)? > > Mostly because I was not aware about it :-). But anyway it is not > usable with my configuration because : > > * I do not run my jails by executing `/etc/rc'. > > * There is a chicken and egg problem here since /sbin/ > (where mount(8) stands) would have to be manually > sync'ed with the host, and I don't want that (I just > want to `make DESTDIR=/jail/named distribtion' the > first time, and then reduce as tight as possible the > administrative overhead caused by jails). Ok, a friend of mine pointed me out that I misunderstood what you said. It is indeed possible to use the -F option of mount(8)/umount(8) from the host system : let's say we have a jail called "named". We can have a rc.conf(5) variable called "jail_named_fstab" which will define the fstab(5) file to use for this particular jail. The following patch nullifies the previous one, since it does not require to add the -c option to mount(8)/umount(8). It adds two variables to default/rc.conf : jail_example_mount_enable="NO" jail_example_fstab="" When the first one is made true, then rc.d/jail will mount (resp. umount) the filesystems described in the file pointed by the second one when the jail will be started (resp. stopped). If the second one is left empty, then it will default to "/etc/fstab.${jail}". http://jeremie.le-hen.org/~tataz/patches/FreeBSD/jail_mount.patch (Note that I didn't have time to test it on my own system, but the patch itself is pretty simple and should work immediately.) Regards, PS: Once the patch has been successfuly tested by either me or someone else, should I send a PR ? -- Jeremie LE HEN aka TtZ/TataZ jeremie.le-hen@sitadelle.com ttz@sitadelle.com Hi! I'm a .signature virus! Copy me into your ~/.signature to help me spread!