Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 15 Oct 1998 15:59:06 -0700 (PDT)
From:      Jin Guojun (FTG staff) <jin@george.lbl.gov>
To:        freebsd-bugs@hub.freebsd.org, wpaul@FreeBSD.ORG, wpaul@hub.freebsd.org
Subject:   Re: bin/8338
Message-ID:  <199810152259.PAA22852@george.lbl.gov>

next in thread | raw e-mail | index | archive | help
> You can look at the contents of the map on the slave using the yp_mkdb
> command. Do the following:
>   
> # cd /var/yp/<your domain>
> # yp_mkdb -u passwd.byname | grep YP_MASTER_NAME

The YP_MASTER_NAME is correctly set.

> You will see that there is a special record in the map database with a 
> key of YP_MASTER_NAME and a data field with the name of the master host.  
> This is the information that ypserv uses to determine the master name 
> when it receives a YPPROC_XFR request. It deliberately ignores the hostname  
> specified in the request arguments because it knows that it might be wrong,
> and the information in the map is always supposed to be correct.
>  
> When you first initialize a slave, you need to use ypxfr to transfer copies
> manually onto the slave from the master. If you have FreeBSD 3.0, then
> the ypinit script will do this for you: use ypinit -s. After you do this,
> then the FreeBSD slave server will contain the correct YP_MASTER_NAME
> information.

Yes, under 3.0, the "ypinit -s $YP_MASTER_NAME" removed /var/yp/${domain}
and reuested all copies of maps transfered; and then, everything seems to work.

Under 2.x system, however, "ypxfr -h $YP_MASTER_NAME passwd" failed:
# ./ypxfr -h $YP_MASTER_NAME passwd
ypxfr: failed to find master of passwd in domain FTG: No such map in server's domain
ypxfr: Exiting: Could not get master server address

I don't know if I still miss something here, but it is not important since
3.0 works and we wil move to 3.0 any way. If this can be resolved, it will be
appreciated.

> There are several reasons why may be having problems:
>  
> - You previously set up the FreeBSD host as an NIS master server and
>   did not erase the old maps before turning the machine into a slave.

There was no set-up for server, but could be some bad maps there.
Clean-up doesn't help.

> - The maps on the NIS master server have the wrong YP_MASTER_NAME
>   in them. To check, do a yppoll passwd.byname from a client that is
>   bound to the master name. If yppoll reports the wrong information,
>   then you should rebuild the maps on the master server.

yppoll passwd.byname reports correct information on all hosts.


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?199810152259.PAA22852>