Date: Thu, 25 Jun 1998 03:50:52 +0900 (JST) From: amakawa@sf.t.u-tokyo.ac.jp To: FreeBSD-gnats-submit@FreeBSD.ORG Subject: conf/7054: bad default value of ${fs} for type:=host in /etc/amd.map Message-ID: <199806241850.DAA00894@nebula.sf.t.u-tokyo.ac.jp>
next in thread | raw e-mail | index | archive | help
>Number: 7054 >Category: conf >Synopsis: bad default value of ${fs} for type:=host in /etc/amd.map >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Wed Jun 24 12:00:01 PDT 1998 >Last-Modified: >Originator: Amakawa Shuhei >Organization: Univ. of Tokyo >Release: FreeBSD 2.2.6-RELEASE i386 >Environment: FreeBSD 2.2.6-RELEASE i386 >Description: The default value of ${fs} for type:=host given in /etc/amd.map causes clash between the mount tree for network host file system (type:=host) and that for network filesystem (type:=nfs). >How-To-Repeat: Suppose `ns' is an NFS server, exporting `/export/usr'. Use the following map for `/amnt'. ----------------------------------------------------------------- tmp type:=nfs;rhost:=ns;rfs:=/export/usr/tmp ----------------------------------------------------------------- Then you can access `ns:/export/usr/tmp' via `/amnt/tmp' and `/host/ns/export/usr/tmp'. Now, do the following. % cd /amnt/tmp % df . Filesystem 1K-blocks Used Avail Capacity Mounted on ns:/export/usr/tmp 3945840 2096272 1770652 54% /a/ns/export/usr/tmp ~~~~~~~~~~~~~~~~~~~~ OK. % cd /host/ns/export/usr/tmp % df . Filesystem 1K-blocks Used Avail Capacity Mounted on ns:/export/usr/tmp 3945840 2096272 1770652 54% /a/ns/export/usr ~~~~~~~~~~~~~~~~ This means /amnt/tmp is shadowed. % cd /amnt/tmp % df . Filesystem 1K-blocks Used Avail Capacity Mounted on ns:/export/usr/tmp 3945840 2096272 1770652 54% /a/ns/export/usr ~~~~~~~~~~~~~~~~ Shadowed indeed. % amq -u /amnt/tmp % amq -u /host/ns % cd /amnt/tmp /amnt/tmp: No such file or directory. Ugh! >Fix: I suggest `/host' be appended to fs because this map is used for the network *host* filesystem (type:=host). The clash can be thus avoided. Note that the manual page (info amd) suggests "fs:=${autodir}/${rhost}/root", but the same suggestion is given for the network group filesystem (type:=nfsx). So I suppose the better solution is to use "fs:=${autodir}/${rhost}/host" for type:=host and "fs:=${autodir}/${rhost}/nfsx" for type:=nfsx. ----8<---- snip ----8<---- *** amd.map.org Mon Jun 15 11:10:29 1998 --- amd.map Thu Jun 25 02:45:59 1998 *************** *** 1,2 **** ! /defaults type:=host;fs:=${autodir}/${rhost};rhost:=${key} * opts:=rw,grpid,resvport,nfsv2,nosuid,nodev --- 1,2 ---- ! /defaults type:=host;fs:=${autodir}/${rhost}/host;rhost:=${key} * opts:=rw,grpid,resvport,nfsv2,nosuid,nodev ---->8---- snip ---->8---- >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199806241850.DAA00894>