Network Information Service (NIS) B.11.31.04 Administrator's Guide

passwd.byuid protocols.byname protocols.bynumber rpc.bynumber \
services.byname vhe_list publickey.byname netid.byname mail.byaddr \
mail.aliases auto.master rpc.byname servi.bynp auto.tools
3. Modify the /var/yp/Makefile file:
Add the AutoFS map to the list of maps that begin with all:, as follows:
all: passwd group hosts networks rpc services protocols \
netgroup aliases publickey netid vhe_list auto.master\
auto.tools
Duplicate the section that begins with $(YPDBDIR)/$(DOM)/auto_master.time.
In this section, change all occurrences of auto.master or auto_master in the newly
created section to the name of the map you are adding. Note that some
occurrences are auto_tools (the name of the ASCII file), and some are auto.tools
(the name of the NIS database).
$ (YPDBDIR)/$(DOM)/auto_tools.time: $(DIR)/auto_tools\
@(sed -e s/^[ | ]*//g -e /^#/d -e s/#.*$$//
$(DIR)/auto_tools $(CHKPIPE)) |\
$(MAKEDBM) - $(YPDBDIR) /$(DOM)/auto.tools;
@touch $(YPDBDIR)/$(DOM)/auto_tools.time;
@echo updated auto.tools;
@if [ ! $(NOPUSH) ]; then $(YPPUSH) -d $(DOM)\ auto.tools; fi
@if [ ! $(NOPUSH) ]; then echo pushed\ auto.tools; fi
In the /var/yp/Makefile file, duplicate the section that begins with
auto.master:. In this section, change auto.master to auto.tools, and change both
occurrences of auto_master.time to auto_tools.time.
auto.tools:
@if [ $(NOPUSH) ]; then $(MAKE) $(MFLAGS) -k \
$(YPDBDIR)/$(DOM)/auto_tools.time DOM=$(DOM) DIR=$(DIR); \
else $(MAKE) $(MFLAGS) -k $(YPDBDIR)/$(DOM)/auto_tools.time \
DOM=$(DOM) DIR=$(DIR) NOPUSH=$(NOPUSH);fi
4. Generate the map:
# cd /var/yp
# /usr/ccs/bin/make auto.tools
Removing an AutoFS Map from the NIS Domain
If you want to shift the tools repository from the NIS master server to a different server,
the auto.tools AutoFS map must be removed from the master server and added to the
other server.
To remove an AutoFS map from the NIS domain, for example auto.tools, complete the
following steps:
1. Log in to the NIS master server as a superuser.
2. Modify the /usr/sbin/ypinit script using a text editor, to remove the auto.tools
map name from the MASTER_MAPS list.
Removing an AutoFS Map from the NIS Domain 37