Date: Sun, 25 Mar 2001 14:18:43 +1000 (EST) From: Bruce Evans <bde@zeta.org.au> To: Dima Dorfman <dima@unixfreak.org> Cc: 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: <Pine.BSF.4.21.0103251411210.33345-100000@besplex.bde.org> In-Reply-To: <20010324221539.A025A3E09@bazooka.unixfreak.org>
next in thread | previous in thread | raw e-mail | index | archive | help
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. Bruce 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?Pine.BSF.4.21.0103251411210.33345-100000>