Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ sendmail(1M) — A/UX 3.0.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

mailq(1M)

newaliases(1M)

syslogd(1M)

mail(1)

mailx(1)

rmail(1)

aliases(4)




sendmail(1M) sendmail(1M)
NAME sendmail - sends mail SYNOPSIS sendmail -bd -bi -bm -bp -bs -bt -bv -bz -Cconfiguration-file -ddebug-level -Ffull-name -fname -hhop-count -n -oconfiguration-option value -q[interval] -rname -t -v [address]... ARGUMENTS -ba Causes sendmail to run in Arpanet mode. All input lines must end with the RETURN key, and all messages are generated with the RETURN key at the end. In addition, sendmail examines the From: and Sender: fields for the name of the sender. -bd Causes sendmail to execute a fork system call, run as a daemon in the background, and listen on socket 25 for incoming SMTP connections. To do this, the system must support Berkeley IPC. This option is used to start sendmail from /etc/inittab. -bi Initializes the alias database. Using this option is the same as running the newaliases command. -bm Delivers mail in the usual way. This option is the default. -bp Displays a listing of the sendmail queue, /usr/spool/mqueue. Using this option is the same as running the mailq command. -bs Causes sendmail to use the SMTP, as described in RFC 821, on standard input and output. This option includes all the operations of the -ba option that are compatible with SMTP. -bt Runs sendmail in address-test mode. This option is used for debugging configuration tables because it reads addresses and shows the steps in parsing. -bv Verifies names and does not try to collect or deliver a message. This option is normally used to validate users or mailing lists. -bz Creates the configuration freeze file /usr/lib/sendmail.fc. -C[configuration-file] Causes sendmail to bypass the configuration file. If you provide a configuration-file argument, sendmail uses the specified file. If you do not provide a January 1992 1



sendmail(1M) sendmail(1M)
configuration-file argument, sendmail defaults to a file named sendmail.cf in the current directory. If you use this option, sendmail refuses to run as root. -ddebug-argument Enables debugging at the level specified by debug-argument. The value of debug-argument manipulates the debugging flags that are built into sendmail. Each flag is identified by a number and can be set to a level. The higher the level, the greater the amount of information that sendmail displays. Levels greater than 9 are not recommended because they display information that is useful only when debugging sendmail itself. The syntax of debug-argument is as follows: debug-argument: debug-option,debug-option debug-option: debug-range[.debug-level] debug-range: integer | integer - integer Here are some examples: -d12 Sets flag 12 to debug level 1. -d12.3 Sets flag 12 to debug level 3. -d3-17 Sets flags 3 through 17 to debug level 1. -d3-17.4 Sets flags 3 through 17 to debug level 4. -Ffullname Sets the full name of the person sending mail. -flogin-name Sets the name of the person sending mail. This option can be used only by ``trusted'' users (normally root, daemon, and uucp) or if the name you are setting is your current login name. -hhop-count Sets the hop count to the integer value specified by hop-count. The hop count is incremented every time the mail is processed. When it reaches a limit, the mail is returned with an error message, the victim of an aliasing loop. If not specified, Received: lines in the message are counted. -n Prevents sendmail from using the alias database to look 2 January 1992



sendmail(1M) sendmail(1M)
up addresses. -o configuration-option value Sets the configuration option specified by configuration-option to the value specified by value. The system administrator can use the -o option to override values set in the configuration file. In the configuration file, these options appear as a string that has this format: OL[value] The value of L is a letter that identifies the configuration option that is being set, and value is the value to which the configuration option is being set. Some configuration options do not require a value argument. Here are the configuration options: aminutes Causes sendmail to wait for the number of minutes specified by minutes for the @:@ entry to appear in the alias database. If the entry does not appear within that amount of time and the D configuration option is set, you must rebuild the database. If the D option is not set, sendmail issues a warning message. A[alias-file] Causes sendmail to use the database specified by alias-file rather than the default, which is /usr/lib/aliases. If you do not specify the alias file, sendmail uses the file named aliases in the current directory. Bcharacter Sets the blank-substitution character to the value specified by character. Unquoted spaces in addresses are replaced by the specified character. c Prevents immediate connection for mailers that are marked as expensive in their mailer definition line in the configuration file. The message is queued and handled during queue processing. D Allows sendmail to rebuild the alias database if necessary and if the database access modes allow it. If you do not set this configuration option, sendmail never rebuilds the alias database unless explicitly started with the -bi option. dmode Sets the delivery mode to the value specified by January 1992 3



sendmail(1M) sendmail(1M)
mode. Here are the delivery modes: b Specifies background (asynchronous) delivery. i Specifies interactive (synchronous) delivery. q Causes sendmail to queue the message only. Actual delivery takes place the next time sendmail processes the queue. emode Sets error processing to the mode specified by mode. Here are the valid modes: e Causes error messages to be mailed back but always returns a zero exit status. m Causes error messages to be mailed back. p Causes error messages to be displayed on the terminal; this mode is the default. q Causes error messages to be discarded. Only the exit status is returned. w Causes error messages to be ``written'' back (or mailed back if the sender is not logged in). If the text of the message is not mailed back by modes m or w and if the sender is local to this system, a copy of the message is appended to the file dead.letter in the sender's home directory.
r
f Saves the UNIX -style From: line at the beginning
of every message. Normally, sendmail assumes that these lines are redundant and discards them. Fmode Specifies the mode to use when creating temporary files. The value of mode is a 3-digit octal number that is interpreted as the file's access permissions. 644 and 600 are reasonable choices. ggid Starts up mailers with the group ID specified by gid. Hhelp-file Causes sendmail to use the SMTP help file specified by help-file. 4 January 1992



sendmail(1M) sendmail(1M)
i Causes sendmail to ignore periods (.) in incoming messages. I Requires that the BIND name server be running to resolve host names. If this configuration option is not set and the name server is not running, sendmail considers the /etc/hosts file to be complete. In general, do not set this configuration option if your /etc/hosts file does not include all hosts known to you or if you are using the MX (mail forwarding) feature of the BIND name server. If you do not set this configuration option, sendmail still consults the name server but reads the /etc/hosts file if the name server is not available. Do not set this configuration option if you do not run the name server. Llog-level Sets the log level to the value specified by log-level. Acceptable values are 0 to 6, 9, 12, 16. A log level of 0 yields no log messages, while a log level of 16 yields the most verbose logging. See Chapter 9, ``Setting Up Network Mail,'' in A/UX Network System Administration for an explanation of each level. The log is written to the file /usr/spool/mqueue/syslog. m Causes messages to be sent to the sender even if the sending is the result of an alias expansion. MXvalue Sets the macro specified by X to the value specified by value. Nnet-name Specifies the name of the home network. The default is ARPA. The argument of an SMTP HELO command is checked against host-name.net-name, where host-name is requested from the kernel for the current connection. If they do not match, Received: lines are augmented by the name that is determined in this manner so that messages can be traced accurately. o Allows receipt of both old-style headers (spaces between addresses) and new-style headers (commas between addresses). When this configuration option is set, sendmail uses an adaptive algorithm that correctly determines the header format in most cases. If this option is not set, messages must have new-style headers. Regardless of the setting of this configuration option, this version January 1992 5



sendmail(1M) sendmail(1M)
of sendmail outputs new-style headers. qfactor Causes sendmail to use the value specified by factor as a multiplier when deciding when to queue jobs rather than processing them. This value is divided by the difference between the current load-average and the load average limit set by the x configuration option to determine the maximum message priority to send. The default value of factor is 10,000. Qqueuedir Causes sendmail to queue messages in the directory specified by queuedir. The default directory is /usr/spool/mqueue. rperiod-of-time Sets the period of time to wait on read operations. If you do not use this option, sendmail waits forever for a mailer. This option violates the SMTP specification, so the value of period-of-time should be fairly large, such as one hour. The value of period-of-time is specified as a number followed by a unit designation. Here are the unit designations: s Specifies seconds. m Specifies minutes. h Specifies hours. d Specifies days. w Specifies weeks. For example, -q1h30m and -q90m both set the interval to one hour and thirty minutes. The /etc/inittab file in the standard distribution of A/UX runs sendmail with -q15m. s Causes the queue file to always be instantiated, even under circumstances where it is not strictly necessary. This option provides safety against system crashes during delivery. Sstat-file Causes sendmail to save statistics in the file 6 January 1992



sendmail(1M) sendmail(1M)
specified by stat-file instead of the default, /usr/lib/sendmail.st. tstandard-time-zone,daylight-time-zone Sets the time zone to the values specified by standard-time-zone and daylight-time-zone. The values of standard-time-zone and daylight-time-zone should be a standard time zone designator, such as PST or PDT. Tperiod-of-time Sets the period of time for which an undelivered message stays in the queue. When the value specified by period-of-time is reached, undelivered messages are returned to the sender. The default value is three days. You can flush messages that have been in the mail queue for a shorter period of time by processing the message with a shorter period-of-time value. This command returns undelivered messages that are more than one day old: /usr/lib/sendmail -oT1d -q See the description of the r configuration option earlier in this list, for the ways in which period-of-time can be expressed. uuid Starts up those mailers whose definition in the configuration file does not set the S flag with the user ID specified by uid. v Runs sendmail in verbose mode. w Causes sendmail to use the Network Information Service (NIS) to resolve aliases if NIS is active, before looking in the local alias file. xload-average Causes sendmail to queue messages rather than send them when the system load average exceeds the value specified by load-average. Xload-average Causes sendmail to refuse incoming SMTP connections when the system load average exceeds the value specified by load-average. yfact Adds the value specified by fact to the priority (thus lowering the priority of the job) for each recipient. This value penalizes jobs with large January 1992 7



sendmail(1M) sendmail(1M)
numbers of recipients. Y Causes sendmail to deliver each job that is run from the queue in a separate process. You should use this option if your system doesn't have much memory, because sendmail consumes considerable amounts of memory while the queue is being processed. zfact Multiplies the value specified by fact by the message class (determined by the Precedence: field in the header and the P lines in the configuration file) and subtracts the result from the priority. Thus, messages with a higher priority are favored. Zfact Adds the value specified by fact to the priority every time a job is processed. Thus, each time a job is processed, its priority is decreased by the specified value of fact. In most environments, this option is beneficial because hosts that are down are often down for a long time. -q[period-of-time] Causes sendmail to run in the background and process messages in the queue at the interval specified by period-of-time. If you do not specify period-of-time, sendmail processes the queue once. You can use this option with the -bd option. If you are running in f or a mode, the value of period-of-time can be relatively large because it is relevant only when a system that was down comes back up. If you are running in q mode, the value of period-of-time should be relatively short because it defines the maximum amount of time that a message can sit in the queue. See the description of the r configuration option, earlier in this list, for the ways in which period-of-time can be expressed. -rlogin-name Sets the name of the sender of the mail to the value specified by login-name. This option is an alternate and obsolete form of the -f option. -t Causes sendmail to examine the message for lines that begin with To:, Cc:, and Bcc: in search of recipient addresses. The Bcc: line is deleted before transmission. Any addresses in the argument list are suppressed; that is, they do not receive copies even if listed in the message header. 8 January 1992



sendmail(1M) sendmail(1M)
-v Causes sendmail to report expansions of aliases and other information. DESCRIPTION sendmail sends a message to one or more addresses, routing the message over whatever networks are necessary to deliver the message to the correct system and user. Once you have configured sendmail, it runs as a background daemon that neither the system administrator nor users directly use. Instead, users run the standard mail commands, such as /bin/mail or /usr/bin/mailx, which collect the mail, format it for processing by sendmail, and deposit it in a directory (called the mail queue) that sendmail processes. If run without options, sendmail reads its standard input up to the end-of-file character, or up to a line consisting of a single dot, and sends a copy of the message found there to all of the address arguments listed on the command line. To determine any network requirements, sendmail analyzes the syntax and contents of the address arguments. The sendmail daemon supports aliasing, which is a mechanism by which a user is known by another name. Aliases are stored in /usr/lib/aliases for use by all users on the system. Local addresses are looked up and aliased appropriately. You can prevent aliasing by preceding the address with a backslash. Normally the sender is not included in any alias expansions; for example, if the user mars sends a message to an alias called planets, and planets includes mars in the expansion, the message is not delivered to mars. In aliases, the first character of a name may be a vertical bar to cause interpretation of the rest of the name as a command to pipe the mail to. It may be necessary to quote the name to keep sendmail from suppressing the blanks between arguments. For example, the following alias might be established to print mail: lpr: "|/usr/ucb/lpr -h" Aliases can also have the syntax :include:filename to ask sendmail to read the named file for a list of recipients. For example, an alias such as poets: ":include:/usr/local/lib/poets.list" would read /usr/local/lib/poets.list for the list of addresses making up the group. January 1992 9



sendmail(1M) sendmail(1M)
STATUS MESSAGES AND VALUES The sendmail daemon can return any of these exit codes to describe error conditions, if any: 0 (EX_OK) Completion was successful on all addresses. 67 (EX_NOUSER) The specified user does not exist. 68 (EX_NOHOST) The specified host does not exist. 69 (EX_UNAVAILABLE) A service, such as a command or file, does not exist. 70 (EX_SOFTWARE) An internal software error, including bad arguments occurred. 71 (EX_OSERR) A temporary operating-system error, such as cannot fork or cannot create pipe occurred. 72 (EX_OSFILE) A system file, such as /etc/passwd or /etc/utmp, does not exist, cannot be opened, or contains some sort of error, such as a syntax error. 73 (EX_CANTCREAT) A user-specified output file cannot be created. 74 (EX_IOERR) An error occurred while the system was doing I/O on a file. 75 (EX_TEMPFAIL) A message could not be sent immediately, but was queued. 76 (EX_PROTOCOL) A remote system returned an unexpected value during a protocol exchange. 78 (EX_CONFIG) A configuration error occurred. FILES /usr/lib/aliases File containing the input data for the alias database /usr/lib/aliases.dir Files containing the alias database 10 January 1992



sendmail(1M) sendmail(1M)
/usr/lib/aliases.pag File containing list of aliases /usr/lib/sendmail Executable file /usr/lib/sendmail.cf File containing configuration data /usr/lib/sendmail.fc File containing the ``frozen'' configuration /usr/lib/sendmail.hf File containing help information /usr/lib/sendmail.st File used to collect statistics /usr/spool/mqueue/* Directory of temporary files /usr/ucb/mailq Hard link to /usr/lib/sendmail that displays the mail queue /usr/ucb/newaliases Hard link to /usr/lib/sendmail that creates or updates the alias database SEE ALSO mailq(1M), newaliases(1M), syslogd(1M) mail(1), mailx(1), rmail(1) in A/UX Command Reference aliases(4) in A/UX Programmer's Reference Chapter 9, ``Setting Up Network Mail,'' in A/UX Network System Administration January 1992 11

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026