]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - usr.sbin/rpc.ypxfrd/rpc.ypxfrd.8
iostat: Restore lost spaces after tout
[FreeBSD/FreeBSD.git] / usr.sbin / rpc.ypxfrd / rpc.ypxfrd.8
1 .\" Copyright (c) 1995, 1996
2 .\"     Bill Paul <wpaul@ctr.columbia.edu>.  All rights reserved.
3 .\"
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
6 .\" are met:
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\"    notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\"    notice, this list of conditions and the following disclaimer in the
11 .\"    documentation and/or other materials provided with the distribution.
12 .\" 3. All advertising materials mentioning features or use of this software
13 .\"    must display the following acknowledgement:
14 .\"     This product includes software developed by Bill Paul.
15 .\" 4. Neither the name of the author nor the names of contributors
16 .\"    may be used to endorse or promote products derived from this software
17 .\"    without specific prior written permission.
18 .\"
19 .\" THIS SOFTWARE IS PROVIDED BY Bill Paul AND CONTRIBUTORS ``AS IS'' AND
20 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
21 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
22 .\" ARE DISCLAIMED.  IN NO EVENT SHALL Bill Paul OR CONTRIBUTORS BE LIABLE
23 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
24 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
25 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
26 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
27 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
28 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
29 .\" SUCH DAMAGE.
30 .\"
31 .Dd June 2, 1996
32 .Dt RPC.YPXFRD 8
33 .Os
34 .Sh NAME
35 .Nm rpc.ypxfrd
36 .Nd "NIS map transfer server"
37 .Sh SYNOPSIS
38 .Nm
39 .Op Fl p Ar path
40 .Sh DESCRIPTION
41 The
42 .Nm
43 utility is used to speed up the distribution of very large NIS maps
44 from NIS master to NIS slave servers.
45 The normal method for transferring
46 maps involves several steps:
47 .Bl -bullet -offset indent
48 .It
49 The master server calls
50 .Xr yppush 8
51 to inform the slave servers to start a transfer.
52 .It
53 The slave servers invoke
54 .Xr ypxfr 8 ,
55 which reads the entire contents of a map from the master server
56 using the yp_all() function.
57 .It
58 The
59 .Xr ypxfr 8
60 program then creates a new map database file by using the
61 .Xr db 3
62 library hash method to store the data that it receives from the server.
63 .It
64 When all the data has been retrieved,
65 .Xr ypxfr 8
66 moves the new file into place and sends
67 .Xr ypserv 8
68 on the local machine a YPPROC_CLEAR to tell it to refresh its
69 database handles.
70 .El
71 .Pp
72 This process can take several minutes when there are very large
73 maps involved.
74 For example: a passwd database with several tens of
75 thousands of entries can consume several megabytes of disk space,
76 and it can take the
77 .Xr db 3
78 library package a long time to sort and store all the records
79 in a hash database.
80 Consider also that there are two sets of map
81 files:
82 .Pa master.passwd.by{name,uid}
83 and
84 .Pa passwd.by{name,uid} .
85 .Pp
86 The
87 .Nm
88 utility speeds up the transfer process by allowing NIS slave servers to
89 simply copy the master server's map files rather than building their
90 own from scratch.
91 Simply put,
92 .Nm
93 implements an RPC-based file transfer protocol.
94 Transferring even
95 a multi-megabyte file in this fashion takes only a few seconds compared
96 to the several minutes it would take even a reasonably fast slave server
97 to build a new map from scratch.
98 .Pp
99 The
100 .Nm
101 utility uses the same access restriction mechanism as
102 .Xr ypserv 8 .
103 This means that slave servers will only be permitted to transfer
104 files if the rules in the
105 .Pa securenets
106 database permit it (see
107 .Xr ypserv 8
108 for more information on
109 .Pa securenets ) .
110 Furthermore, only slave servers using reserved
111 ports will be allowed to transfer the
112 .Pa master.passwd
113 maps.
114 .Sh OPTIONS
115 The following option is available:
116 .Bl -tag -width indent
117 .It Fl p Ar path
118 This option can be used to override the default path to
119 the location of the NIS
120 map databases.
121 The compiled-in default path is
122 .Pa /var/yp .
123 .El
124 .Sh FILES
125 .Bl -tag -width Pa -compact
126 .It Pa /var/yp/[domainname]/[maps]
127 The NIS maps for a particular NIS domain.
128 .El
129 .Sh SEE ALSO
130 .Xr yp 8 ,
131 .Xr yppush 8 ,
132 .Xr ypserv 8 ,
133 .Xr ypxfr 8
134 .Sh AUTHORS
135 .An Bill Paul Aq Mt wpaul@ctr.columbia.edu
136 .Sh BUGS
137 The
138 .Fx
139 .Nm ypxfrd
140 protocol is not compatible with that used by SunOS.
141 This is unfortunate
142 but unavoidable: Sun's protocol is not freely available, and even if it
143 were it would probably not be useful since the SunOS NIS v2 implementation
144 uses the original ndbm package for its map databases whereas the
145 .Fx
146 implementation uses Berkeley DB.
147 These two packages use vastly different
148 file formats.
149 Furthermore, ndbm is byte-order sensitive and not very
150 smart about it, meaning that am ndbm database created on a big endian
151 system cannot be read on a little endian system.