return to first page linux journal archive
keywordscontents

Listing 1. Example AMD Map

/defaults       opts:nosuid,nodev
#
# This statement specifies the defaults; any
# variables set here apply to all entries
# unless overridden. I simply set two NFS
# options:
# nosuid = don't allow suid programs
# nodev  = don't allow device files
# 
doc	type:=nfs;rhost:=doc-server; \
                   rfs:=/usr/local/docs
# This statement is one of the simplest volume
# specifications. It assigns a location
# /u/doc, which maps to the directory
# /usr/local/docs on the machine 
# doc-server.  

home/crosby    host==cia;type:=link;fs:=/a/home/crosby \
                  host!=cia;type:=nfs;rhost:=cia;rfs:=/a/home/crosby

# This entry is slightly more complicated.
# It specifies information about my home 
# directory, on the machine cia. Basically,
# it accomplishes the same thing as the 
# preceding entry, except that when the machine
# in question is the host itself it simply acts
# as a symlink to the location rather then
# mounting it; thus, the performance problems
# of a machine mounting off of itself are
# avoided while at the same time single map
# for all hosts is allowed.

# Note that the directory is UFS mounted in the<\n> 
# same place that AMD would NFS mount it, 
# under /a.

tools   arch==pa-risc;wire==net1;type:=nfs;  \
                rhost:=nag;rfs:=/tools \
	arch==pa-risc;wire==net2;type:=nfs; \
                rhost:=nagina;rfs:=/tools \
	arch==dec-mips;wire==net1;type:=nfs; \
                rhost:=frisbee;rfs:=/tools \
	arch==dec-mips;wire==net2;type:=nfs; \
                rhost:=aerobie;rfs:=/tools \
	arch==i386;wire==net1;type:=nfs; \
                rhost:=hazelrah;rfs:=/tools \
	arch==i386;wire==net2;type:=nfs; \
                rhost:=pipkin;rfs:=/tools \
# This entry is quite complicated. It has a mount
# point that varies depending on which network the
# machine resides (the "wire" variable, which can
# take symbolic network names or ip addresses) and
# which architecture (HP, # PC/linux, PC/solaris, or
# DEC) applies to the machine. By setting the 
# mount point this way, the users know they can
# go to /u/tools and get the correct binaries for
# the current architecture mounted off the local
# network--regardless of which machine 
# they are using

home/*	-opts:=nosuid \ 
        hosttype:=nfs;rhost:=${key};rfs:=/home/${key}

# This statement is a wildcard map--any entry
# /home/whatever is mapped to machine whatever.
# Having a wild card map is very useful: I can now
# have hundreds of machines with home directories,
# and still have only one map entry. And to add a
# new one, I simply have to add the machine and
# export it--I don't have to modify the map.
#
# This statement also shows how to designate entry
# specific NFS options; I don't want to allow
# suid programs in home directories, so I turn it
# off (-opts:=nosuid).
<\n> 
 data	type:=nfs;rfs:=/data rhost:=server1 \
        rhost:=server2 rhost:=server3
# This statement sets up a replicated server.
# If we have important data, we want to make
# sure it will be available even if a server
# crashes. This data ia replicated over three
# servers, and AMD will mount from whichever one
# it can.