2 .\" Copyright (c) 2004, Sun Microsystems, Inc.
3 .\" 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.
4 .\" 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.
5 .\" 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]
6 .TH ETRN 1M "Aug 10, 2004"
8 etrn \- start mail queue run
12 \fBetrn\fR [\fB-b\fR] [\fB-v\fR] \fIserver-host\fR [\fIclient-hosts\fR]
18 SMTP's \fBETRN\fR command allows an SMTP client and server to interact, giving
19 the server an opportunity to start the processing of its queues for messages to
20 go to a given host. This is meant to be used in start-up conditions, as well as
21 for mail nodes that have transient connections to their service providers.
24 The \fBetrn\fR utility initiates an SMTP session with the host
25 \fIserver-host\fR and sends one or more \fBETRN\fR commands as follows: If no
26 \fIclient-hosts\fR are specified, \fBetrn\fR looks up every host name for which
27 \fBsendmail\fR(1M) accepts email and, for each name, sends an \fBETRN\fR
28 command with that name as the argument. If any \fIclient-hosts\fR are
29 specified, \fBetrn\fR uses each of these as arguments for successive \fBETRN\fR
34 The following options are supported:
41 System boot special case. Make sure localhost is accepting SMTP connections
42 before initiating the SMTP session with server-host.
44 This option is useful because it prevents race conditions between
45 \fBsendmail\fR(1M) accepting connections and \fIserver-host\fR attempting to
46 deliver queued mail. This check is performed automatically if no
47 \fIclient-hosts\fR are specified.
56 The normal mode of operation for \fBetrn\fR is to do all of its work silently.
57 The \fB-v\fR option makes it verbose, which causes \fBetrn\fR to display its
58 conversations with the remote SMTP server.
61 .SH ENVIRONMENT VARIABLES
64 No environment variables are used. However, at system start-up,
65 \fBsvc:/network/smtp:sendmail\fR reads \fB/etc/default/sendmail\fR. In this
66 file, if the variable \fBETRN_HOSTS\fR is set, \fBsvc:/network/smtp:sendmail\fR
67 parses this variable and invokes \fBetrn\fR appropriately. \fBETRN_HOSTS\fR
68 should be of the form:
72 "s1:c1.1,c1.2 s2:c2.1 s3:c3.1,c3.2,c3.3"
79 That is, white-space separated groups of \fIserver:client\fR where \fIclient\fR
80 can be one or more comma-separated names. The \fI:client\fR part is optional.
81 \fIserver\fR is the name of the server to prod; a mail queue run is requested
82 for each \fIclient\fR name. This is comparable to running:
86 /usr/lib/sendmail -qR \fIclient\fR
93 on the host \fIserver\fR.
96 \fBExample 1 \fRUsing \fBetrn\fR
104 ETRN_HOSTS="s1.domain.com:clnt.domain.com s2.domain.com:clnt.domain.com"
111 in \fB/etc/default/sendmail\fR results in \fBsvc:/network/smtp:sendmail\fR
112 invoking \fBetrn\fR such that \fBETRN\fR commands are sent to both
113 \fBs1.domain.com\fR and \fBs2.domain.com\fR, with both having
114 \fBclnt.domain.com\fR as the \fBETRN\fR argument.
123 ETRN_HOSTS="server.domain.com:client1.domain.com,client2.domain.com"
130 results in two \fBETRN\fR commands being sent to \fBserver.domain.com\fR, one
131 with the argument \fBclient1.domain.com\fR, the other with the argument
132 \fBclient2.domain.com\fR.
141 ETRN_HOSTS="server1.domain.com server2.domain.com"
148 results in set of a \fBETRN\fR commands being sent to both
149 \fBserver1.domain.com\fR and \fBserver2.domain.com\fR; each set contains one
150 \fBETRN\fR command for each host name for which \fBsendmail\fR(1M) accepts
151 email, with that host name as the argument.
157 \fB\fB/etc/mail/sendmail.cf\fR\fR
160 \fBsendmail\fR configuration file
166 \fB\fB/etc/default/sendmail\fR\fR
169 Variables used by \fBsvc:/network/smtp:sendmail\fR
175 See \fBattributes\fR(5) for descriptions of the following attributes:
183 ATTRIBUTE TYPE ATTRIBUTE VALUE
185 Interface Stability Stable
191 \fBsendmail\fR(1M), \fBattributes\fR(5)
198 Not all SMTP servers support \fBETRN\fR.