113170f18SBill Paul.\" Copyright (c) 1997 213170f18SBill Paul.\" Bill Paul <wpaul@ctr.columbia.edu>. All rights reserved. 313170f18SBill Paul.\" 413170f18SBill Paul.\" Redistribution and use in source and binary forms, with or without 513170f18SBill Paul.\" modification, are permitted provided that the following conditions 613170f18SBill Paul.\" are met: 713170f18SBill Paul.\" 1. Redistributions of source code must retain the above copyright 813170f18SBill Paul.\" notice, this list of conditions and the following disclaimer. 913170f18SBill Paul.\" 2. Redistributions in binary form must reproduce the above copyright 1013170f18SBill Paul.\" notice, this list of conditions and the following disclaimer in the 1113170f18SBill Paul.\" documentation and/or other materials provided with the distribution. 1213170f18SBill Paul.\" 3. All advertising materials mentioning features or use of this software 1313170f18SBill Paul.\" must display the following acknowledgement: 1413170f18SBill Paul.\" This product includes software developed by Bill Paul. 1513170f18SBill Paul.\" 4. Neither the name of the author nor the names of any co-contributors 1613170f18SBill Paul.\" may be used to endorse or promote products derived from this software 1713170f18SBill Paul.\" without specific prior written permission. 1813170f18SBill Paul.\" 1913170f18SBill Paul.\" THIS SOFTWARE IS PROVIDED BY Bill Paul AND CONTRIBUTORS ``AS IS'' AND 2013170f18SBill Paul.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 2113170f18SBill Paul.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 2213170f18SBill Paul.\" ARE DISCLAIMED. IN NO EVENT SHALL Bill Paul OR THE VOICES IN HIS HEAD 2313170f18SBill Paul.\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 2413170f18SBill Paul.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 2513170f18SBill Paul.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 2613170f18SBill Paul.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 2713170f18SBill Paul.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 2813170f18SBill Paul.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 2913170f18SBill Paul.\" THE POSSIBILITY OF SUCH DAMAGE. 3013170f18SBill Paul.\" 31*fac7bc23SAlan Somers.Dd August 18, 2015 32d8207d54SBill Paul.Dt YPINIT 8 33a4c37c81SRuslan Ermilov.Os 3413170f18SBill Paul.Sh NAME 3513170f18SBill Paul.Nm ypinit 3613170f18SBill Paul.Nd build and install NIS databases 3713170f18SBill Paul.Sh SYNOPSIS 38e97407b4SRuslan Ermilov.Nm 3913170f18SBill Paul.Fl m 4013170f18SBill Paul.Op Ar domainname 41e97407b4SRuslan Ermilov.Nm 4213170f18SBill Paul.Fl s 4313170f18SBill Paul.Ar master_server 4413170f18SBill Paul.Op Ar domainname 45e97407b4SRuslan Ermilov.Nm 4613170f18SBill Paul.Fl u 4713170f18SBill Paul.Op Ar domainname 4813170f18SBill Paul.Sh DESCRIPTION 4913170f18SBill PaulThe 5013170f18SBill Paul.Nm 51490d5836SPhilippe Charnierutility is a script which sets up databases on a Network Information Service 52490d5836SPhilippe Charnier(NIS) 5313170f18SBill Paulmaster or slave server. 5413170f18SBill Paul.Pp 5513170f18SBill PaulOn a master server, 5613170f18SBill Paul.Nm 5713170f18SBill Paulcreates the 5813170f18SBill Paul.Pa /var/yp/$DOMAINNAME 5913170f18SBill Pauldirectory, the 6013170f18SBill Paul.Pa /var/yp/ypservers 6113170f18SBill Paulfile, and calls 6213170f18SBill Paul.Pa /var/yp/Makefile 63f2e366a1SSheldon Hearnto create and populate an initial set of NIS maps. 64f2e366a1SSheldon HearnThe maps are 6513170f18SBill Paulcreated from local source files using the 6613170f18SBill Paul.Xr yp_mkdb 8 67490d5836SPhilippe Charnierutility. 68490d5836SPhilippe CharnierThe utility will prompt the user for a list of servers 6913170f18SBill Paulthat support the specified domain; this list is used to populate 7013170f18SBill Paulthe ypservers map. 7113170f18SBill Paul.Pp 7213170f18SBill PaulOn a slave server, 7313170f18SBill Paul.Nm 7413170f18SBill Paulcreates the 75d8207d54SBill Paul.Pa /var/yp/$DOMAINNAME , 76f2e366a1SSheldon Hearnpopulates it with copies of the NIS maps from the master. 77f2e366a1SSheldon HearnThe maps 7813170f18SBill Paulare obtained from the master using the 7913170f18SBill Paul.Xr ypxfr 8 80490d5836SPhilippe Charnierutility. 81f2e366a1SSheldon HearnThe 8213170f18SBill Paul.Nm 83490d5836SPhilippe Charnierutility obtains the list of maps to transfer in one of two ways: if 8413170f18SBill Paulthe system is configured as an NIS client and is bound to the master 8513170f18SBill Paulserver, 8613170f18SBill Paul.Nm 8713170f18SBill Paulis able to use the 88d8207d54SBill Paul.Xr ypwhich 1 89490d5836SPhilippe Charnierutility to obtain a list of maps exported by the master server. 9013170f18SBill PaulIf the system is not configured as a client of the NIS master, 9113170f18SBill Paul.Nm 9213170f18SBill Pauluses a hardcoded list of maps, some of which may or may not actually 93f2e366a1SSheldon Hearnexist on the master. 94490d5836SPhilippe CharnierThe system administrator can edit the 95490d5836SPhilippe Charnier.Nm 96490d5836SPhilippe Charnierscript and 97f2e366a1SSheldon Hearnmodify the map list if necessary. 98490d5836SPhilippe CharnierOtherwise, individual maps can 99d4352d29SJoel Dahlbe transferred manually from the master using 10013170f18SBill Paul.Xr ypxfr 8 . 10113170f18SBill Paul.Sh OPTIONS 102490d5836SPhilippe CharnierThe 103490d5836SPhilippe Charnier.Nm 104490d5836SPhilippe Charnierutility supports the following options: 105d8207d54SBill Paul.Bl -tag -width indent 10613170f18SBill Paul.It Fl m Op Ar domainname 107f2e366a1SSheldon HearnSet up a master server. 108490d5836SPhilippe CharnierBy default, 109490d5836SPhilippe Charnier.Nm 110490d5836SPhilippe Charniersets up a server for 111f2e366a1SSheldon Hearnthe system default domain. 112f2e366a1SSheldon HearnThe user can override this default by specifying 11313170f18SBill Paul.Ar domainname 11413170f18SBill Paulexplicitly. 11513170f18SBill PaulMaps are constructed from scratch using local files as templates using 11613170f18SBill Paulthe 11713170f18SBill Paul.Xr yp_mkdb 8 118490d5836SPhilippe Charnierutility. 11913170f18SBill Paul.It Fl s Ar master_server Op Ar domainname 12013170f18SBill PaulSet up a slave server using 12113170f18SBill Paul.Ar master_name 122f2e366a1SSheldon Hearnas the master. 123f2e366a1SSheldon HearnMaps are copied from 12413170f18SBill Paul.Ar master_server 12513170f18SBill Paulto the slave using 12613170f18SBill Paul.Xr ypxfr 8 . 127490d5836SPhilippe CharnierBy default, 128490d5836SPhilippe Charnier.Nm 129490d5836SPhilippe Charniersets up a server for 130f2e366a1SSheldon Hearnthe system default domain. 131f2e366a1SSheldon HearnThe user can override this default by specifying 13213170f18SBill Paul.Ar domainname 13313170f18SBill Paulexplicitly. 13413170f18SBill Paul.It Fl u Op Ar domainname 135f2e366a1SSheldon HearnUpdate the ypservers map on the master server. 136f2e366a1SSheldon HearnWhen a new slave 13713170f18SBill Paulserver is added to a domain, its hostname must be added to the 13813170f18SBill Paulypservers map so that 13913170f18SBill Paul.Xr yppush 8 14013170f18SBill Paulcan propagate updates on the master to all of the slaves. 1418b5c4af3SRuslan Ermilov.El 14213170f18SBill Paul.Sh FILES 14313170f18SBill Paul.Bl -tag -width /var/yp/master.passwd -compact 14413170f18SBill Paul.It Pa /etc/bootparams 14513170f18SBill PaulBootparams source file 14613170f18SBill Paul.It Pa /etc/ethers 14713170f18SBill PaulEthers data source file 148*fac7bc23SAlan Somers.It Pa /etc/eui64 149*fac7bc23SAlan SomersEUI64 data source file 15013170f18SBill Paul.It Pa /etc/group 15113170f18SBill PaulGroup source file 15213170f18SBill Paul.It Pa /etc/hosts 15313170f18SBill PaulHostname/IP address source file 15413170f18SBill Paul.It Pa /etc/netid 15513170f18SBill PaulRPC netid source file 15613170f18SBill Paul.It Pa /etc/networks 15713170f18SBill PaulNetworks source file 15813170f18SBill Paul.It Pa /etc/protocols 15913170f18SBill PaulProtocols source file 16013170f18SBill Paul.It Pa /etc/publickey 16113170f18SBill PaulRPC public key/secret key source file 16213170f18SBill Paul.It Pa /etc/services 16313170f18SBill PaulServices data source file 1641e6c9668SMaxim Konovalov.It Pa /etc/shells 1651e6c9668SMaxim KonovalovShells source file 16613170f18SBill Paul.It Pa /var/yp/master.passwd 16713170f18SBill PaulPasswd database source file 16813170f18SBill Paul.It Pa /var/yp/netgroup 16913170f18SBill PaulNetgroup data source file 17013170f18SBill Paul.It Pa /var/yp/ypservers 17113170f18SBill PaulYpservers source file (generated by 172e97407b4SRuslan Ermilov.Nm ) 17313170f18SBill Paul.El 17413170f18SBill Paul.Sh SEE ALSO 17513170f18SBill Paul.Xr mknetid 8 , 17613170f18SBill Paul.Xr revnetgroup 8 , 177491a8429SRuslan Ermilov.Xr yp 8 , 1781c85060aSRuslan Ermilov.Xr yp_mkdb 8 , 17913170f18SBill Paul.Xr yppush 8 , 18013170f18SBill Paul.Xr ypserv 8 , 1811c85060aSRuslan Ermilov.Xr ypxfr 8 18213170f18SBill Paul.Sh HISTORY 18313170f18SBill PaulThis version of 18413170f18SBill Paul.Nm 18513170f18SBill Paulis based on the 18613170f18SBill Paul.Nm 187d8207d54SBill Paulscript in 18814201ae6SMike Pritchard.Ox . 189d8207d54SBill PaulIt first appeared in 19013170f18SBill Paul.Fx 3.0 . 191f12a1471SPhilippe Charnier.Sh AUTHORS 192f4d874a1SRuslan Ermilov.An -nosplit 19313170f18SBill PaulThe original script was written by 19401c2b8acSBaptiste Daroussin.An Mats O Jansson Aq Mt moj@stacken.kth.se . 195d8207d54SBill PaulIt was modified for 19614201ae6SMike Pritchard.Fx 197d8207d54SBill Paulby 19801c2b8acSBaptiste Daroussin.An Bill Paul Aq Mt wpaul@ctr.columbia.edu . 199