*BSD News Article 71373


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.anu.edu.au!harbinger.cc.monash.edu.au!nntp.coast.net!howland.reston.ans.net!math.ohio-state.edu!uwm.edu!lll-winken.llnl.gov!sol.ctr.columbia.edu!startide.ctr.columbia.edu!wpaul
From: wpaul@ctr.columbia.edu (Bill Paul)
Newsgroups: comp.unix.bsd.freebsd.misc
Subject: Re: NIS slave server?
Date: 18 Jun 1996 20:42:36 GMT
Organization: Columbia University Center for Telecommunications Research
Lines: 50
Message-ID: <4q74bt$ejg@sol.ctr.columbia.edu>
References: <david-1806960033250001@blue4.infocom.com>
NNTP-Posting-Host: startide.ctr.columbia.edu
X-Newsreader: TIN [version 1.2 PL2]

Daring to challenge the will of the almighty Leviam00se, David Scheidt
(david@infocom.com) had the courage to say:

: We are trying to get an nis slave server running on one of our FreeBSD
: boxes.  I cannot figure out how one to init the slave server.  Under other
: unix religons one runs ypinit;  FreeBSD has none.  What it the
: replacement?  ypserv doesn't have any options that tell it that it is a
: slave server.  Does the the lack of maps in /var/yp signal in some way?

: David

First, make sure ypserv is running on all the master and slave servers.
(You don't need to use any special flags for this: just run it on the
slaves the same way you run it on the master.) yppasswdd should run only
on the master.

Create a ypservers map on the master server and put in it the names of
all your NIS servers, like this:

master.nis.domain	master.nis.domain
slave1.nis.domain	slave1.nis.domain
slave2.nis.domain	slave2.nis.domain

Do a 'make' to update the map.

Then edit /var/yp/Makefile and comment out the line that says 'NOPUSH = True'.
This will cause the maps to be pushed to the slave servers when they are
updated.

Now 'touch' all the map source files on your NIS master and run 'make'
again. Using the touch command will update the timestamps on the source
files so that 'make' will rebuild all the maps. It will also distribute
them to all the slave servers for you using the yppush command.

From then on, any updates you make on the server will automatically be
pushed to the slaves.

If you like, you can also use the yppush command on the master to
distribute the maps manually.

-Bill

--
=============================================================================
-Bill Paul            (212) 854-6020 | System Manager, Master of Unix-Fu
Work:         wpaul@ctr.columbia.edu | Center for Telecommunications Research
Home:  wpaul@skynet.ctr.columbia.edu | Columbia University, New York City
=============================================================================
 "If you're ever in trouble, go to the CTR. Ask for Bill. He will help you."
=============================================================================