Problem using multiple amd maps, and the "auto" fs type
W. Phillip Moore
moore at srl.mew.mei.co.jp
Wed Mar 27 15:45:29 AEST 1991
This is a question for amd experts. I have been using amd for about 6
months now, and I find it incredibly useful for managing the horrendous NFS
system we have (multiple servers / multiple clients). However, I find the
documentation to be cryptic at best. After experimenting for half a day or
more, I give up. If someone know how to do the following, please let me in
on the secret.
Here's the problem:
I run amd on several directories. One of them is /srl, via which I want to
access three different types of sub-directory: homes, group-use
directories, and directories for various CAD tools. I want to have three
subdirectories: /srl/{home,group,cad}, and since the list of individual
directories below these three will be rather long, I want to break up the
mount maps into three different files. What I've succesfully implemented
so far is this:
amd is started with the following arg's from /etc/rc at boot time.
/usr/etc/amd -a /nfs -l /var/log/amdlog /srl amd.srl
The map file amd.srl (which BTW is a NIS map) is:
====begin amd.srl========
/defaults opts:=rw,grpid,intr;type:=nfs
src host!=saturn;rhost:=saturn;rfs:=/ftp/pub \
host==saturn;type=link;fs=/ftp/pub
mail host!=saturn;rhost:=saturn;rfs:=/var/spool/mail
local host!=saturn;rhost:=saturn;rfs:=/export/local \
host==saturn;type=link;fs=/export/local
cad type:=auto;fs:=srl.cad;pref:=${key}/
group type:=auto;fs:=srl.group;pref:=${key}/
home type:=auto;fs:=srl.home;pref:=${key}/
====end amd.srl==========
And the map file for srl.home (also a NIS map) is:
====begin srl.home=======
/defaults type:=nfs;opts:=rw,grpid,intr
home/moore host!=terra;rhost:=terra;rfs:=/export/home/02;sublink:=${/key} \
host==terra;type=link;fs=/export/home/02/${/key}
====end srl.home=========
This works exactly like I want it to. The problem is I want to simplify
the srl.home map file, so that I don't need to include the pref:=${key}/
statement, and want to be able to have srl.home look something like:
====begin srl.home=======
/defaults type:=nfs;opts:=rw,grpid,intr
moore host!=terra;rhost:=terra;rfs:=/export/home/02;sublink:=${/key} \
host==terra;type=link;fs=/export/home/02/${/key}
====end srl.home=========
I have tried to simply change the auto entry for home in amd.srl to be:
home type:=auto;fs:=srl.home
and the amd manual claims the default value of "pref" is a null string, so
I though this would allow srl.home to contain entries like those I want.
Trying both sublink:=${/key} and sublink:=${key} in srl.home doesn't make
any difference either.
This may seem like a trivial point, but srl.home is going to contain an
entry for every user on the system (over 90 people now, close to 200 in the
near future), so keeping the map file as simple as possible is desirable.
Also, it just plain annoys me that I can't get this to do what I want.
Has anyone implemented a similar map system?? Jan-Simon Pendry lists a
silimar example on page 22 of the amd manual, but he only shows the auto
entry:
local type:=auto;fs:=local-map
and he doesn't show an example of what the contents of local-map are
supposed to (or can) look like.
RTFM's are of course welcome, and any advice would be appreciated.
W. Phillip Moore Phone: 06-908-1431
LSI Research Group FAX: 06-906-7251
Semiconductor Research Laboratory E-mail: moore at mew.mei.co.jp
Matsushita Electric Works, Ltd. 1048 Kadoma, Osaka 571, Japan
More information about the Comp.unix.questions
mailing list