'\" te .\" Copyright (c) 2000 Sun Microsystems, Inc. All Rights Reserved. .\" Copyright 1989 AT&T .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License. .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License. .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner] .TH YPXFR 1M "Mar 11, 1998" .SH NAME ypxfr, ypxfr_1perday, ypxfr_1perhour, ypxfr_2perday \- transfer NIS map from a NIS server to host .SH SYNOPSIS .LP .nf \fB/usr/lib/netsvc/yp/ypxfr\fR [\fB-c\fR] [\fB-f\fR] [\fB-C\fR \fItid\fR \fIprog\fR \fIserver\fR] [\fB-d\fR \fIypdomain\fR] [\fB-h\fR \fIhost\fR] [\fB-s\fR \fIypdomain\fR] \fImapname\fR .fi .SH DESCRIPTION .sp .LP The \fBypxfr\fR command moves an \fBNIS\fR map in the default domain for the local host to the local host by making use of normal \fBNIS\fR services. It creates a temporary map in the directory \fB/var/yp/\fR\fIypdomain\fR (this directory must already exist; \fIypdomain\fR is the default domain for the local host), fills it by enumerating the map's entries, fetches the map parameters (master and order number), and loads them. It then deletes any old versions of the map and moves the temporary map to the real \fIname\fR. .sp .LP If run interactively, \fBypxfr\fR writes its output to the terminal. However, if it is started without a controlling terminal, and if the log file \fB/var/yp/ypxfr.log\fR exists, it appends all its output to that file. Since \fBypxfr\fR is most often run from the privileged user's \fBcrontab\fR file, or by \fBypserv\fR, the log file can retain a record of what was attempted, and what the results were. .sp .LP For consistency between servers, \fBypxfr\fR should be run periodically for every map in the \fBNIS\fR data base. Different maps change at different rates: a map might not change for months at a time, for instance, and can therefore be checked only once a day. Some maps might change several times per day. In such a case, you might want to check hourly for updates. A \fBcrontab\fR(1) entry can be used to automatically perform periodic updates. Rather than having a separate \fBcrontab\fR entry for each map, you can group commands to update several maps in a shell script. Examples (mnemonically named) are in \fB/usr/sbin/yp\fR: \fBypxfr_1perday\fR, \fBypxfr_2perday\fR, and \fBypxfr_1perhour\fR. .sp .LP Refer to \fBypfiles\fR(4) for an overview of the NIS name service. .SH OPTIONS .sp .ne 2 .na \fB\fB-c\fR\fR .ad .RS 22n Do not send a "Clear current map" request to the local \fBypserv\fR process. Use this flag if \fBypserv\fR is not running locally at the time you are running \fBypxfr\fR. Otherwise, \fBypxfr\fR complains that it cannot communicate with the local \fBypserv\fR, and the transfer fails. .RE .sp .ne 2 .na \fB\fB-f\fR\fR .ad .RS 22n Force the transfer to occur even if the version at the master is not more recent than the local version. .RE .sp .ne 2 .na \fB\fB-C\fR\fI tid prog server\fR\fR .ad .RS 22n This option is for use \fIonly\fR by \fBypserv\fR. When \fBypserv\fR starts \fBypxfr\fR, it specifies that \fBypxfr\fR should call back a \fByppush\fR process at the host \fIserver\fR, registered as program number \fIprog\fR, and waiting for a response to transaction \fItid\fR. .RE .sp .ne 2 .na \fB\fB-d\fR\fI ypdomain\fR\fR .ad .RS 22n Specify a domain other than the default domain. .RE .sp .ne 2 .na \fB\fB-h\fR \fIhost\fR\fR .ad .RS 22n Get the map from \fIhost\fR, regardless of the master. If \fIhost\fR is not specified, \fBypxfr\fR asks the \fBNIS\fR service for the name of the master, and tries to get the map from there. \fIhost\fR must be a valid host name. .RE .sp .ne 2 .na \fB\fB-s\fR\fI ypdomain\fR\fR .ad .RS 22n Specify a source domain from which to transfer a map that should be the same across domains. .RE .SH FILES .sp .ne 2 .na \fB\fB/var/yp/ypxfr.log\fR\fR .ad .sp .6 .RS 4n Log file .RE .sp .ne 2 .na \fB\fB/usr/lib/netsvc/yp/ypxfr_1perday\fR\fR .ad .sp .6 .RS 4n Script to run one transfer per day, for use with \fBcron\fR(1M) .RE .sp .ne 2 .na \fB\fB/usr/lib/netsvc/yp/ypxfr_2perday\fR\fR .ad .sp .6 .RS 4n Script to run two transfer per day, for use with \fBcron\fR(1M) .RE .sp .ne 2 .na \fB\fB/usr/lib/netsvc/yp/ypxfr_1perhour\fR\fR .ad .sp .6 .RS 4n Script for hourly transfers of volatile maps .RE .sp .ne 2 .na \fB\fB/var/yp/\fR\fIypdomain\fR\fR .ad .sp .6 .RS 4n \fBNIS\fR domain .RE .sp .ne 2 .na \fB\fB/usr/spool/cron/crontabs/root\fR\fR .ad .sp .6 .RS 4n Privileged user's \fBcrontab\fR file .RE .SS "ypxfr_1perday, ypxfr_1perhour, and ypxfr_2perday" .sp .SH SEE ALSO .sp .LP \fBcrontab\fR(1), \fBcron\fR(1M), \fBypinit\fR(1M), \fByppush\fR(1M), \fBypserv\fR(1M), \fBypfiles\fR(4), \fBattributes\fR(5)