Date: Sun, 25 Mar 2001 11:36:50 +0300 From: Peter Pentchev <roam@orbitel.bg> To: Bruce Evans <bde@zeta.org.au> Cc: Dima Dorfman <dima@unixfreak.org>, Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>, freebsd-hackers@FreeBSD.ORG, freebsd-fs@FreeBSD.ORG Subject: Re: Displaying options for current NFS mounts Message-ID: <20010325113649.D36335@ringworld.oblivion.bg> In-Reply-To: <Pine.BSF.4.21.0103251411210.33345-100000@besplex.bde.org>; from bde@zeta.org.au on Sun, Mar 25, 2001 at 02:18:43PM %2B1000 References: <20010324221539.A025A3E09@bazooka.unixfreak.org> <Pine.BSF.4.21.0103251411210.33345-100000@besplex.bde.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, Mar 25, 2001 at 02:18:43PM +1000, Bruce Evans wrote: > On Sat, 24 Mar 2001, Dima Dorfman wrote: > > > I tried to export this stuff in struct statfs, but ran into a problem: > > I'd need the complete definitions of <fs>_args in <sys/mount.h>, but I > > can't include, e.g., <nfs/nfs.h> because the latter includes the > > former (<sys/mount.h>)! > > mount.h used to know too much about all sorts of filesystems, but this > was fixed in 4.4BSD. It is impossible for mount.h or mount(8) to know > about all file systems, since filesystems can be dynamically loaded, > and ugly for it to know about more than 1 (or 0 -- ffs is too special). > > > The patch below kind of implements this functionality. I only export > > nfs_args (not <otherfs>_args), and I only modified mount(8) to print > > the NFS version, but printing the transport and others is simple from > > there. To work around the above problem, I pasted the struct nfs_args > > definition into mount.h. It is *horribly* ugly, but it does work. > > Only mount_foofs can reasonably know about the options for foofs. > perhaps mount(8) could fork-exec mount_foofs(8) to print options for > foofs. <bikeshed type=question value="mostly stupid"> Or could mount(8) invoke a couple of sysctl's to get a string representation of each mountpoint's mount options? </bikeshed> G'luck, Peter -- I am the thought you are now thinking. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-fs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010325113649.D36335>