From owner-freebsd-arch@FreeBSD.ORG Tue Oct 10 15:21:32 2006 Return-Path: X-Original-To: freebsd-arch@FreeBSD.ORG Delivered-To: freebsd-arch@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 512F016A4A0; Tue, 10 Oct 2006 15:21:32 +0000 (UTC) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (lurza.secnetix.de [83.120.8.8]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0D49143DD6; Tue, 10 Oct 2006 15:21:25 +0000 (GMT) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (bmtuhk@localhost [127.0.0.1]) by lurza.secnetix.de (8.13.4/8.13.4) with ESMTP id k9AFLJhX033186; Tue, 10 Oct 2006 17:21:24 +0200 (CEST) (envelope-from oliver.fromme@secnetix.de) Received: (from olli@localhost) by lurza.secnetix.de (8.13.4/8.13.1/Submit) id k9AFLJSX033185; Tue, 10 Oct 2006 17:21:19 +0200 (CEST) (envelope-from olli) Date: Tue, 10 Oct 2006 17:21:19 +0200 (CEST) Message-Id: <200610101521.k9AFLJSX033185@lurza.secnetix.de> From: Oliver Fromme To: freebsd-arch@FreeBSD.ORG, matteo@FreeBSD.ORG In-Reply-To: <20061001101143.GB94004@kaiser.sig11.org> X-Newsgroups: list.freebsd-arch User-Agent: tin/1.8.2-20060425 ("Shillay") (UNIX) (FreeBSD/4.11-STABLE (i386)) X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-2.1.2 (lurza.secnetix.de [127.0.0.1]); Tue, 10 Oct 2006 17:21:25 +0200 (CEST) Cc: Subject: Re: RFC: use of mdmfs "new" options in fstab X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd-arch@FreeBSD.ORG, matteo@FreeBSD.ORG List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 10 Oct 2006 15:21:32 -0000 This email is a bit old, but nobody else has commented, so ... Matteo Riondato wrote: > During the years, mdmfs(8) has got many options which are not > available in the "mount_mfs" compatibility mode (activated by > specifing -C on the command line or by calling mount_mfs). > > This means that it's impossible to use mdmfs "new" option in fstab, > which is quite limiting. Yes, it's a real PITA. For example, I would like to mount several memory file systems from within fstab, but I don't need nor want soft-updates. Howver, the -S option is not available for mount_mfs. (On a related note, I also don't want the .snap directory to appear on those memory file systems. newfs(8) has the -n option to suppress it, but mdmfs doesn't.) > I think there are two possibilities to solve this: > > 1) install mdmfs as mount_md (or mount_$something) and teach mount to > recognize it. See attached mdmfsmakefile_mount.c.diff . This will > allow to specify the following line in fstab (the -P option is not > available in compatability mode): > > md /usr/jail/jail1 md ro,-P,-F/usr/jailmd/jail1.md 0 0 > > 2)disable bug-for-bug compatibility with mount_mfs when the > program name is "mount_mfs" or "mfs". The "-C" otion will still be > available for those who want compatibility. See attached > mdmfs.c.diff . > > I would prefer option #2, but any comment is really appreciated. Personally, I would love to see #2 committed (and MFCed). There's only one thing which could cause breakage: When mdmfs is called as mount_mfs (hence -C is implied), the option -p 1777 is the default, which is appropriate for /tmp. People who have mount_mfs in their fstab and expect that default behaviour will be surprised to see that their /tmp suddenly isn't mode 1777 anymore. Therefore I propose that your patch #2 be slightly modified: When mdmfs is called as mount_mfs, don't imply -C (hence all options are available), but do imply -p 1777. Then it shouldn't break any existing usages, as far as I can imagine. Best regards Oliver -- Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing Dienstleistungen mit Schwerpunkt FreeBSD: http://www.secnetix.de/bsd Any opinions expressed in this message may be personal to the author and may not necessarily reflect the opinions of secnetix in any way. PI: int f[9814],b,c=9814,g,i;long a=1e4,d,e,h; main(){for(;b=c,c-=14;i=printf("%04d",e+d/a),e=d%a) while(g=--b*2)d=h*b+a*(i?f[b]:a/5),h=d/--g,f[b]=d%g;}