From owner-freebsd-hackers@FreeBSD.ORG Mon Nov 30 11:51:47 2009 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2BE831065676 for ; Mon, 30 Nov 2009 11:51:47 +0000 (UTC) (envelope-from freebsd-hackers@m.gmane.org) Received: from lo.gmane.org (lo.gmane.org [80.91.229.12]) by mx1.freebsd.org (Postfix) with ESMTP id DB74C8FC1C for ; Mon, 30 Nov 2009 11:51:46 +0000 (UTC) Received: from list by lo.gmane.org with local (Exim 4.50) id 1NF4nB-0007oA-K2 for freebsd-hackers@freebsd.org; Mon, 30 Nov 2009 12:51:45 +0100 Received: from lara.cc.fer.hr ([161.53.72.113]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 30 Nov 2009 12:51:45 +0100 Received: from ivoras by lara.cc.fer.hr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 30 Nov 2009 12:51:45 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-hackers@freebsd.org From: Ivan Voras Date: Mon, 30 Nov 2009 12:51:31 +0100 Lines: 22 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: lara.cc.fer.hr User-Agent: Thunderbird 2.0.0.23 (X11/20090928) In-Reply-To: Sender: news Subject: Re: [patch] Improved jail fstab functionality inside rc.d (needs testers and review) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 30 Nov 2009 11:51:47 -0000 Merijn Verstraaten wrote: > My apologies if these are the wrong lists for this sort of thing but it > was unclear to me where else to go with additions like this. > > I just finished hacking /etc/rc.d/jail to fix my two pet peeves, > currently the rc framework only accepts a single fstab file per jail and > (worse!) there is no way to specify the mountpoints in these fstab files > relative to the jails root. This makes sharing of mounts (for example > all my jails nullfs mounting the same ports tree) very cumbersome. > > This patch should allow you to specify multiple fstab files in the > jail_fstab and jail__fstab variables and mount these in order. In > addition the patch mangles the fstab files in such a way that any > mountpoint in the fstab files starting with the text "ROOT" will have > "ROOT" replaced with the jails rootdir. For example the following > situation: > rc.conf: > jail_test_rootdir="/usr/jails/test" > jail_test_fstab="/usr/jails/fstab /usr/jails/fstab.test" Ah, so you want a single fstab file to be usable for multiple jails, which have identical fs structures. Nice idea.