Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages


home | help
sendmail(1M)		System Administration Commands		  sendmail(1M)

       sendmail	- send mail over the internet

       /usr/lib/sendmail [-ba] [-bD] [-bd] [-bi] [-bm] [-bp] [-bP] [-bs] [-bt]
       [-bv] [-B type] [-C file] [-d X]	[-F fullname]  [-f name]  [-G]	[-h N]
       [-L tag]	 [  -M	xvalue]	[-Nnotifications] [-n] [ -Ooption =value] [ -o
       xvalue] [-p protocol] [ -q [time]] [-q Xstring] [-R ret]	[-r name] [-t]
       [-V envid] [-v] [-X logfile] [ address...]

       sendmail	 sends	a  message  to one or more people, routing the message
       over whatever networks are necessary. sendmail does  internetwork  for-
       warding as necessary to deliver the message to the correct place.

       sendmail	 is  not  intended as a	user interface routine;	other programs
       provide user-friendly front ends. sendmail is used only to deliver pre-
       formatted messages.

       With  no	 flags,	 sendmail  reads its standard input up to an EOF, or a
       line with a single dot, and sends a copy	of the letter found  there  to
       all  of the addresses listed. It	determines the network to use based on
       the syntax and contents of the addresses.

       Local addresses are looked up in	the local aliases(4)  file,  or	 in  a
       name  service  as defined by the	nsswitch.conf(4) file, and aliased ap-
       propriately. In addition, if there is a .forward	file in	a  recipient's
       home directory, sendmail	forwards a copy	of each	message	to the list of
       recipients that file contains. Refer to the NOTES section for more  in-
       formation  about	.forward files.	Aliasing can be	prevented by preceding
       the address with	a backslash.

       There are several conditions under which	the expected behavior  is  for
       the alias database to be	either built or	rebuilt. This cannot occur un-
       der any circumstances unless root owns and has exclusive	write  permis-
       sion to the /etc/mail/aliases* files.

       If a message is found to	be undeliverable, it is	returned to the	sender
       with diagnostics	that indicate the location and nature of the  failure;
       or,  the	 message  is placed in a dead.letter file in the sender's home

       The following options are supported:

       -Ac   Use even	if the operation mode  does  not  indicate  an
	     initial mail submission.

       -Am   Use  even if the operation mode indicates an initial
	     mail submission.

       -ba   Go	into ARPANET mode. All input lines must	end  with  a  <RETURN-
	     LINEFEED>,	 and  all  messages are	generated with a <RETURN-LINE-
	     FEED> at the end. Also, the From: and Sender: fields are examined
	     for the name of the sender.

       -bd   Run as a daemon in	the background,	waiting	for incoming SMTP con-

       -bD   Run as a daemon in	the foreground,	waiting	for incoming SMTP con-

       -bi   Initialize	the aliases(4) database. Root must own and have	exclu-
	     sive write	permission to the /etc/mail/aliases*  files  for  suc-
	     cessful use of this option.

       -bm   Deliver mail in the usual way (default).

       -bp   Print a summary of	the mail queues.

       -bP   Print  the	 number	 of entries in the queues. This	option is only
	     available with shared memory support.

       -bs   Use the SMTP protocol as described	in RFC 821. This flag  implies
	     all the operations	of the -ba flag	that are compatible with SMTP.

       -bt   Run in address test mode. This mode reads addresses and shows the
	     steps in parsing; it is used for debugging	configuration tables.

       -bv   Verify names only;	do not try to collect or  deliver  a  message.
	     Verify  mode  is  normally	 used  for validating users or mailing

       -B type
	     Indicate body type	(7BIT or 8BITMIME).

       -C file
	     Use alternate configuration file.

       -d X  Set debugging value to X.

       -F fullname
	     Set the full name of the sender.

       -G    When accepting messages by	way of the command line, indicate that
	     they  are	for relay (gateway) submission.	When this flag is set,
	     sendmail might complain about syntactically invalid messages, for
	     example,  unqualified  host names,	rather than fixing them. send-
	     mail does not do any canonicalization in this mode.

       -f name
	     Sets the name of the "from" person	(that is, the  sender  of  the

       -h N  Set  the  hop count to N. The hop count is	incremented every time
	     the mail is processed. When it reaches a limit, the mail  is  re-
	     turned with an error message, the victim of an aliasing loop.

       -L tag
	     Set the identifier	used in	syslog messages	to the supplied	tag.

	     Set macro x to the	specified value.

       -n    Do	not do aliasing.

       -N notifications
	     Tag  all  addresses being sent as wanting the indicated notifica-
	     tions, which consists of the word "NEVER"	or  a  comma-separated
	     list  of  "SUCCESS", "FAILURE", and "DELAY" for successful	deliv-
	     ery, failure and a	message	that is	stuck in a queue somwhere. The
	     default is	"FAILURE,DELAY".

	     Set  option  x to the specified value. Processing Options are de-
	     scribed below.

	     Set option	to the specified value (for long from names). Process-
	     ing Options are described below.

       -p protocol
	     Set  the sending protocol.	The protocol field can be in form pro-
	     tocol:host	to set both the	sending	protocol and the sending host.
	     For  example:  -pUUCP:uunet sets the sending protocol to UUCP and
	     the sending host to uunet.	(Some existing programs	use -oM	to set
	     the r and s macros; this is equivalent to using -p).

	     Process  saved  messages in the queue at given intervals. If time
	     is	omitted, process the queue once. time is  given	 as  a	tagged
	     number,  with  s being seconds, m being minutes, h	being hours, d
	     being days, and w being weeks.  For  example,  -q1h30m  or	 -q90m
	     would both	set the	timeout	to one hour thirty minutes.

	     By	 default,  sendmail runs in the	background. This option	can be
	     used safely with -bd.

	     Similar to	-qtime,	except that instead of periodically forking  a
	     child  to	process	 the queue, sendmail forks a single persistent
	     child for each queue that alternates between processing the queue
	     and sleeping. The sleep time (time) is specified as the argument;
	     it	defaults to 1 second. The process always  sleeps  at  least  5
	     seconds if	the queue was empty in the previous queue run.

       -qf   Process  saved messages in	the queue once and do not fork(2), but
	     run in the	foreground.

       -qG name
	      Process jobs in queue group called name only.

       -q[!]I substr
	     Limit processed jobs to those containing substr as	a substring of
	     the queue ID or not when !	is specified.

       -q[!]R substr
	     Limit processed jobs to those containing substr as	a substring of
	     one of the	recipients or not when ! is specified.

       --q[!]S substr
	     Limit processed jobs to those containing substr as	a substring of
	     the sender	or not when ! is specified.

       -r name
	     An	alternate and obsolete form of the -f flag.

       -R ret
	     Identify  the  information	 you  want  returned  if  the  message
	     bounces;  ret can be "HDRS" for headers only or "FULL" for	 head-
	     ers plus body.

       -t    Read message for recipients. To:, Cc:, and	Bcc: lines are scanned
	     for people	to send	to. The	Bcc: line is deleted before  transmis-
	     sion.  Any	 addresses  in the argument list is be suppressed. The
	     NoRecipientAction Processing Option can be	used to	change the be-
	     haviour when no legal recipients are included in the message.

       -v    Go	 into  verbose	mode.  Alias  expansions are announced,	and so

       -V envid
	      The indicated envid is passed with the envelope of  the  message
	     and returned if the message bounces.

       -X logfile
	     Log  all  traffic in and out of sendmail in the indicated logfile
	     for debugging mailer problems. This produces a lot	of  data  very
	     quickly and should	be used	sparingly.

   Processing Options
       There  are a number of "random" options that can	be set from a configu-
       ration file. Options are	represented by a single	character or by	multi-
       ple character names. The	syntax for the single character	names of is:


       This sets option	x to be	value. Depending on the	option,	value may be a
       string, an integer, a boolean (with legal values	t, T, f, or F; the de-
       fault is	TRUE), or a time interval.

	The multiple character or long names use this syntax:

	      O	Longname=argument

       This  sets the option Longname to be argument. The long names are bene-
       ficial because they are easier to interpret than	the  single  character

       Not  all	processing options have	single character names associated with
       them. In	the list below the multiple character name is presented	 first
       followed	by the single character	syntax enclosed	in parentheses.

       AliasFile (Afile)
	     Specify possible alias files.

       AliasWait (a N)
	     If	 set,  wait up to N minutes for	an "@:@" entry to exist	in the
	     aliases(4)	database before	starting up. If	it does	not appear  in
	     N minutes,	issue a	warning. Defaults to 10	minutes.

	     Allow  a  HELO SMTP command that does not include a host name. By
	     default this option is disabled.

	     If	set and	more than the specified	number of recipients in	a sin-
	     gle  SMTP	envelope are rejected, sleep for one second after each
	     rejected RCPT command.

       BlankSub	(Bc)
	     Set the blank substitution	character to c.	Unquoted spaces	in ad-
	     dresses  are  replaced by this character. Defaults	to SPACE (that
	     is, no change is made).

       CheckAliases (n)
	     Validate the RHS of aliases when rebuilding the aliases(4)	 data-

       CheckpointInterval (CN)
	     Checkpoints  the  queue  every  N (default	10) addresses sent. If
	     your system crashes during	delivery to a large  list,  this  pre-
	     vents retransmission to any but the last N	recipients.

       ClassFactor (zfact)
	     The indicated factor fact is multiplied by	the message class (de-
	     termined by the Precedence: field in the user header  and	the  P
	     lines  in	the configuration file)	and subtracted from the	prior-
	     ity. Thus,	messages with a	higher Priority: are favored. Defaults
	     to	1800.

	     Set  client  SMTP options.	The options are	key=value pairs. Known
	     keys are:

	     Addr Address Mask
		   Address Mask	defaults to INADDR_ANY.	The address  mask  can
		   be a	numeric	address	in dot notation	or a network name.

		   Address family (defaults to INET).

		   Size	of listen queue	(defaults to 10).

	     Port  Name/number of listening port (defaults to smtp).

		   The size of the TCP/IP receive buffer.

		   The size of the TCP/IP send buffer.

		   Options (flags) for the daemon. Can be:

		   h	 Use name of interface for HELO	command.

		   If  h is set, the name corresponding	to the outgoing	inter-
		   face	address	(whether chosen	by means of the	Connection pa-
		   rameter or the default) is used for the HELO/EHLO command.

	     If	 set,  colons are treated as a regular character in addresses.
	     If	not set, they are treated as the introducer  to	 the  RFC  822
	     "group" syntax. This option is on for version 5 and lower config-
	     uration files.

       ConnectionCacheSize (kN)
	     The maximum number	of open	connections that are be	 cached	 at  a
	     time.  The	 default is 1. This delays closing the current connec-
	     tion until	either this invocation of sendmail needs to connect to
	     another  host  or	it terminates. Setting it to 0 defaults	to the
	     old behavior, that	is, connections	are closed immediately.

       ConnectionCacheTimeout (Ktimeout)
	     The maximum amount	of time	a cached connection  is	 permitted  to
	     idle  without  activity. If this time is exceeded,	the connection
	     is	immediately closed. This value should be small (on  the	 order
	     of	ten minutes). Before sendmail uses a cached connection,	it al-
	     ways sends	a NOOP (no operation) command to check the connection;
	     if	 this  fails,  it  reopens the connection. This	keeps your end
	     from failing if the other end times out. The point	of this	option
	     is	to be a	good network neighbor and avoid	using up excessive re-
	     sources on	the other end. The default is five minutes.

	     The maximum number	of connections	permitted  per	second.	 After
	     this  many	 connections are accepted, further connections are de-
	     layed. If not set or <= 0,	there is no limit.

	     Name of the control socket	for daemon management. A running send-
	     mail  daemon  can	be controlled through this Unix	domain socket.
	     Available commands	are: help, restart, shutdown, and status.  The
	     status command returns the	current	number of daemon children, the
	     free disk space (in blocks) of the	queue directory, and the  load
	     average  of  the  machine expressed as an integer.	If not set, no
	     control socket is available. For the sake of security, this  Unix
	     domain  socket must be in a directory which is accessible only by
	     root; /var/spool/mqueue/.smcontrol	is recommended for the	socket

       DaemonPortOptions (Ooptions)
	     Set  server  SMTP options.	The options are	key=value pairs. Known
	     keys are:

	     Name  User-definable name for the daemon (defaults	to "Daemon#");
		   used	for error messages and logging.

	     Addr  Address mask	(defaults INADDR_ANY)

		   The	address	 mask may be a numeric address in dot notation
		   or a	network	name.

		   Address family (defaults to INET)

		   Size	of listen queue	(defaults to 10)

		   Options (flags) for the daemon; can be a sequence  (without
		   any delimiters) of:

		   a	 Require authentication.

		   b	 Bind  to  interface  through  which mail has been re-

		   c	 Perform hostname canonification (.cf).

		   f	 Require fully qualified hostname (.cf).

		   h	 Use name of interface for HELO	command.

		   u	 Allow unqualified addresses (.cf).

		   C	 Do not	perform	hostname canonification.

		   E	 Disallow ETRN (see RFC	2476).

	     Name  User-definable name for the daemon (defaults	 to  Daemon#);
		   used	for error messages and logging.

	     Port  Name/number of listening port (defaults to smtp)

		   The size of the TCP/IP receive buffer.

		   The size of the TCP/IP send buffer.

	     sendmail  listens on a new	socket for each	occurrence of the Dae-
	     monPortOptions option in a	configuration file.

	     Set the threshold,	in bytes, before  a  memory-bases  queue  data
	     file becomes disk-based. The default is 4096 bytes

	     Defines  the  location  of	the system-wide	dead.letter file, for-
	     merly hard-coded to /var/tmp/dead.letter. If this option  is  not
	     set (the default),	sendmail does not attempt to save to a system-
	     wide dead.letter file in the event	it cannot bounce the  mail  to
	     the user or postmaster. Instead, it renames the qf	file as	it has
	     in	the past when the dead.letter file could not be	opened.

	     Set the default character set to use when converting unlabeled  8
	     bit input to MIME.

       DefaultUser (ggid) or (uuid)
	     Set  the default group ID for mailers to run in to	gid or set the
	     default userid for	mailers	to uid.	Defaults to 1. The  value  can
	     also be given as a	symbolic group or user name.

	     When  the system load average exceeds LA, sendmail	sleeps for one
	     second on most SMTP commands and before accepting connections.

	     Set minimum time for  Deliver  By	SMTP  Service  Extension  (RFC
	     2852).  If	0, no time is listed, if less than 0, the extension is
	     not offered, if greater than 0, it	is listed as minimum time  for
	     the EHLO keyword DELIVERBY.

       DeliveryMode (dx)
	     Deliver in	mode x.	Legal modes are:

	     i	   Deliver interactively (synchronously).

	     b	   Deliver in background (asynchronously).

	     d	   Deferred  mode  --  database	lookups	are deferred until the
		   actual queue	run.

	     q	   Just	queue the message (deliver during queue	run).

	     Defaults to b if no option	is specified, i	if it is specified but
	     given no argument (that is, Od is equivalent to Odi).

	     If	a connection fails, wait this many seconds and try again. Zero
	     means "do not retry".

	     If	set, override the file safety checks. This compromises	system
	     security	and   should   not   be	  used.	 See  http://www.send- for more information.

	     If	set, $[	... $] lookups that do DNS-based lookups do not	expand
	     CNAME records.

	     If	 set,  the  initgroups(3C) routine is never be invoked.	If you
	     set this, agents run on behalf of users only have	their  primary
	     (/etc/passwd) group permissions.

	     If	 set,  sendmail	does not insert	the names and addresses	of any
	     local interfaces into the $=w class. If set, you  must  also  in-
	     clude support for these addresses,	otherwise mail to addresses in
	     this list bounce with a configuration error.

       DontPruneRoutes (R)
	     If	set, do	not prune route-addr syntax addresses to  the  minimum

	     If	an error occurs	when sending an	error message, send that "dou-
	     ble bounce" error message to this address.

       EightBitMode (8)
	     Use 8-bit data handling. This option requires one of the  follow-
	     ing keys. The key can selected by using just the first character,
	     but using the full	word is	better for clarity.

		   Do any necessary conversion of 8BITMIME to 7-bit.

	     pass  Pass	unlabeled 8-bit	input through as is.

		   Reject unlabeled 8-bit input.

       ErrorHeader (Efile/message)
	     Append error messages with	the indicated message.	If  it	begins
	     with a slash, it is assumed to be the pathname of a file contain-
	     ing a message (this is the	recommended setting).	Otherwise,  it
	     is	 a  literal  message.  The  error file might contain the name,
	     email address, and/or phone number	 of  a	local  postmaster  who
	     could  provide  assistance	to end users. If the option is missing
	     or	NULL, or if it names a file which does not exist or  which  is
	     not readable, no message is printed.

       ErrorMode (ex)
	     Dispose of	errors using mode x. The values	for x are:

	     e	   Mail	back errors and	give 0 exit status always.

	     m	   Mail	back errors.

	     p	   Print error messages	(default).

	     q	   No messages,	just give exit status.

	     w	   Write back errors (mail if user not logged in).

       FallbackMXhost (Vfallbackhost)
	     If	 specified,  the fallbackhost acts like	a very low priority MX
	     on	every host. This is intended to	be used	 by  sites  with  poor
	     network connectivity.

	     If	set to a value greater than zero (the default is one), it sup-
	     presses the MX lookups  on	 addresses  when  they	are  initially
	     sorted, that is, for the first delivery attempt. This usually re-
	     sults in faster envelope splitting	 unless	 the  MX  records  are
	     readily  available	in a local DNS cache. To enforce initial sort-
	     ing based on MX records set FastSplit to zero.  If	 the  mail  is
	     submitted	directly  from	the  command line, then	the value also
	     limits the	number of processes to deliver the envelopes; if  more
	     envelopes	are  created they are only queued up and must be taken
	     care of by	a queue	run. Since the default submission method is by
	     way  of  SMTP (either from	a MUA or by way	of the MSP), the value
	     of	FastSplit is seldom used to limit the number of	 processes  to
	     deliver the envelopes.

       ForkEachJob (Y)
	     If	set, deliver each job that is run from the queue in a separate
	     process. Use this option if you are short of  memory,  since  the
	     default tends to consume considerable amounts of memory while the
	     queue is being processed.

       ForwardPath (Jpath)
	     Set the path for searching	for users' .forward files. The default
	     is	$z/.forward. Some sites	that use the automounter may prefer to
	     change this to /var/forward/$u to search a	 file  with  the  same
	     name  as  the user	in a system directory. It can also be set to a
	     sequence of paths separated by  colons;  sendmail	stops  at  the
	     first  file  it  can  successfully	 and safely open. For example,
	     /var/forward/$u:$z/.forward searches first	in /var/forward/ user-
	     name  and	then in	~username/.forward (but	only if	the first file
	     does not exist). Refer to the NOTES section for more information.

       HelpFile	(Hfile)
	     Specify the help file for SMTP.

       HoldExpensive (c)
	     If	an outgoing mailer is marked as	being expensive, don't connect

	     Set the file to use when doing "file" type	access of host names.

	     If	 set, host status is kept on disk between sendmail runs	in the
	     named directory tree. If a	full path is not used, then  the  path
	     is	interpreted relative to	the queue directory.

       IgnoreDots (i)
	     Ignore  dots  in incoming messages. This is always	disabled (that
	     is, dots are always accepted) when	reading	SMTP mail.

       LogLevel	(Ln)
	     Set the default log level to n. Defaults to 9.

	     Set the macro x to	value. This is intended	only for use from  the
	     command line.

	     Type  of  lookup  to find information about local mail boxes, de-
	     faults to pw which	uses getpwnam(3C). Other types can  be	intro-
	     duced by adding them to the source	code, see libsm/mbdb.c for de-

       MatchGECOS (G)
	     Try to match recipient names using	the GECOS field.  This	allows
	     for  mail	to be delivered	using names defined in the GECOS field
	     in	/etc/passwd as well as the login name.

	     The maximum number	of children the	 daemon	 permits.  After  this
	     number,  connections are rejected.	If not set or <=0, there is no

       MaxHopCount (hN)
	     The maximum hop count. Messages that  have	 been  processed  more
	     than  N  times  are assumed to be in a loop and are rejected. De-
	     faults to 25.

	     The maximum size of messages that are accepted (in	bytes).

	     Sets the maximum length of	certain	MIME header field values to  M
	     characters.  For some of these headers which take parameters, the
	     maximum length of each parameter is set to	N if specified.	If  /N
	     is	not specified, one half	of M is	used. By default, these	values
	     are 0, meaning no checks are done.

	     When set, this limits the number of concurrent queue runner  pro-
	     cesses to N. This helps to	control	the amount of system resources
	     used when processing the queue. When  there  are  multiple	 queue
	     groups  defined  and  the total number of queue runners for these
	     queue groups would	exceed MaxQueueChildren	then the queue	groups
	     are  not all run concurrently. That is, some portion of the queue
	     groups run	concurrently such that MaxQueueChildren	is not be  ex-
	     ceeded,  while the	remaining queue	groups are run later (in round
	     robin order). See MaxRunnersPerQueue.

	     If	set, limit the maximum size of any given  queue	 run  to  this
	     number  of	 entries. This stops reading the queue directory after
	     this number of entries is reached;	job priority is	not  used.  If
	     not set, there is no limit.

	     This  sets	 the default maximum number of queue runners for queue
	     groups. Up	to N queue runners work	in parallel on a queue group's
	     messages. This is useful where the	processing of a	message	in the
	     queue might delay the processing of subsequent messages.  Such  a
	     delay can be the result of	non-erroneous situations such as a low
	     bandwidth connection. The can be overridden on a per queue	 group
	     basis  by	setting	 the Runners option. The default is 1 when not

       MeToo (M)
	     Send to me	too, even if I am in an	alias expansion.

	     If	set, allow no more than	the specified number of	recipients  in
	     an	SMTP envelope. Further recipients receive a 452	error code and
	     are deferred for the next delivery	attempt.

       MinFreeBlocks (bN/M)
	     Insist on at least	N blocks free on the file  system  that	 holds
	     the  queue	 files before accepting	email by way of	SMTP. If there
	     is	insufficient space, sendmail gives a 452 response to the  MAIL
	     command. This invites the sender to try again later. The optional
	     M is a maximum message size advertised  in	 the  ESMTP  EHLO  re-
	     sponse. It	is currently otherwise unused.

	     The  amount  of  time  a  job must	sit in the queue between queue
	     runs. This	allows you to set the queue run	interval low for  bet-
	     ter  responsiveness  without trying all jobs in each run. The de-
	     fault value is 0.

	     Characters	to be quoted in	a  full	 name  phrase.	&,;:\()[]  are
	     quoted automatically.

	     The priority of queue runners. See	nice(1).

	     Set  action if there are no legal recipient files in the message.
	     The legal values are:

		   Add an Apparently-to: header	with all the known  recipients
		   (which may expose blind recipients).

		   Add an empty	Bcc: header.

		   Add	a  To: header with all the known recipients (which may
		   expose blind	recipients).

		   Add a To: undisclosed-recipients: header.

	     none  Do nothing, leave the message as it is.

       OldStyleHeaders (o)
	     Assume that the headers may be in old format, that	is, spaces de-
	     limit names. This actually	turns on an adaptive algorithm:	if any
	     recipient	address	 contains  a  comma,  parenthesis,  or	 angle
	     bracket, it is assumed that commas	already	exist. If this flag is
	     not on, only commas delimit names.	Headers	are always output with
	     commas between the	names.

       OperatorChars or	$o
	     Defines  the  list	of characters that can be used to separate the
	     components	of an address into tokens.

	     Filename of the pid file. The default  is	/var/run/
	     The filename is macro-expanded before it is opened.

       PostmasterCopy (Ppostmaster)
	     If	 set,  copies of error messages	are sent to the	named postmas-
	     ter. Only the header of the failed	message	is  sent.  Since  most
	     errors  are  user	problems,  this	is probably not	a good idea on
	     large sites, and arguably contains	all sorts  of  privacy	viola-
	     tions,  but it seems to be	popular	with certain operating systems

       PrivacyOptions (popt,opt,...)
	     Set privacy options. Privacy is really a misnomer;	many of	 these
	     are  just	a  way	of insisting on	stricter adherence to the SMTP

	     The goaway	pseudo-flag sets  all  flags  except  noreceipts,  re-
	     strictmailq,  restrictqrun, restrictexpand, noetrn, and nobodyre-
	     turn. If mailq is restricted, only	people in the  same  group  as
	     the  queue	 directory  can	print the queue. If queue runs are re-
	     stricted, only root and the owner of the queue directory can  run
	     the  queue. The restrict-expand pseudo-flag instructs sendmail to
	     drop privileges when the -bv option is given  by  users  who  are
	     neither  root  nor	 the  TrustedUser so users cannot read private
	     aliases, forwards,	or  :include:  files.  It  adds	 the  NonRoot-
	     SafeAddr to the "DontBlame-Sendmail" option to prevent misleading
	     unsafe address warnings. It also overrides	the -v (verbose)  com-
	     mand  line	 option	to prevent information leakage.	Authentication
	     Warnings add warnings about various conditions that may  indicate
	     attempts  to  fool	the mail system, such as using an non-standard
	     queue directory.

	     The options can be	selected from:

		   Put X-Authentication-Warning: headers in messages.

		   Disallow essentially	all SMTP status	queries.

		   Insist on HELO or EHLO command before EXPN.

		   Insist on HELO or EHLO command before MAIL.

		   Insist on HELO or EHLO command before VRFY.

		   Disallow ETRN entirely.

		   Disallow EXPN entirely.

		   Prevent return receipts.

		   Do not return the body of a message with DSNs.

		   Disallow VRFY entirely.

		   Allow open access.

		   Restrict -bv	and -v command line flags.

		   Restrict mailq command.

		   Restrict -q command line flag.

       ProcessTitlePrefix string
	     Prefix the	process	title shown on	"/usr/ucb/ps  auxww"  listings
	     with string. The string is	macro processed.

       QueueDirectory (Qdir)
	     Use the named dir as the queue directory.

       QueueFactor (qfactor)
	     Use  factor  as the multiplier in the map function	to decide when
	     to	just queue up jobs rather than run them. This value is divided
	     by	 the  difference between the current load average and the load
	     average limit (xflag) to determine	the maximum  message  priority
	     to	be sent. Defaults to 600000.

	     Default permissions for queue files (octal). If not set, sendmail
	     uses 0600 unless its real and  effective  uid  are	 different  in
	     which case	it uses	0644.

       QueueLA (xLA)
	     When  the	system	load  average  exceeds LA, just	queue messages
	     (that is, do not try to send them). Defaults to eight  times  the
	     number of processors online when sendmail starts.

	     Sets  the	algorithm  used	 for sorting the queue.	Only the first
	     character of the value is used. Legal values are host  (to	 order
	     by	the name of the	first host name	of the first recipient), file-
	     name (to order by the name	of the queue file name), time (to  or-
	     der by the	submission/creation time), random (to order randomly),
	     modification (to order by the modification	time of	 the  qf  file
	     (older  entries first)), and priority (to order by	message	prior-
	     ity). Host	ordering makes better use of the connection cache, but
	     may  tend	to  process  low priority messages that	go to a	single
	     host over high priority messages that go  to  several  hosts;  it
	     probably shouldn't	be used	on
	      slow  network  links.  Filename  and  modification time ordering
	     saves the overhead	of reading all	of  the	 queued	 items	before
	     starting  the  queue  run.	Creation (submission) time ordering is
	     almost always a bad idea, since it	allows large, bulk mail	to  go
	     out  before smaller, personal mail, but may have applicability on
	     some hosts	with very fast connections. Random is useful  if  sev-
	     eral  queue  runners  are	started	by hand	which try to drain the
	     same queue	since odds are they are	working	on different parts  of
	     the queue at the same time. Priority ordering is the default.

       QueueTimeout (Trtime/wtime)
	     Set  the  queue  timeout  to rtime. After this interval, messages
	     that have not been	successfully sent are returned to the  sender.
	     Defaults  to five days (5d). The optional wtime is	the time after
	     which a warning message is	sent. If it is missing or 0,  then  no
	     warning messages are sent.

       RecipientFactor (yfact)
	     The indicated factor fact is added	to the priority	(thus lowering
	     the priority of the job) for each recipient, that is, this	 value
	     penalizes	jobs  with  large  numbers  of recipients. Defaults to

       RefuseLA	(XLA)
	     When the system load average exceeds  LA,	refuse	incoming  SMTP
	     connections. Defaults to 12 times the number of processors	online
	     when sendmail starts.

       ResolverOptions (I)
	     Tune DNS lookups.

       RetryFactor (Zfact)
	     The indicated factor fact is added	to the priority	every  time  a
	     job  is processed.	Thus, each time	a job is processed, its	prior-
	     ity is decreased by the indicated	value.	In  most  environments
	     this  should  be  positive, since hosts that are down are all too
	     often down	for a long time. Defaults to 90000.

	     If	this option is set, a "Return-Receipt-To:" header  causes  the
	     request  of  a  DSN,  which is sent to the	envelope sender	as re-
	     quired by RFC 1891, not to	the address given in the header.

	     If	set, become this user when reading and	delivering  mail.  In-
	     tended for	use of firewalls where users do	not have accounts.

	     If	set, sendmail does a chroot into this directory	before writing

       SaveFromLine (f)
	     Save Unix-style From lines	at the front of	headers. Normally they
	     are assumed redundant and discarded.

       SendMimeErrors (j)
	     If	 set, send error messages in MIME format (see RFC 2045 and RFC
	     1344 for details).	If disabled, sendmail does not return the  DSN
	     keyword  in  response  to an EHLO and does	not do Delivery	Status
	     Notification processing as	described in RFC 1891.

	     Defines the path to the service-switch file. Since	 the  service-
	     switch  file is defined in	the Solaris operating environment this
	     option is ignored.

       SevenBitInput (7)
	     Strip input to seven bits for  compatibility  with	 old  systems.
	     This should not be	necessary.

	     Key  to  use for shared memory segment; if	not set	(or 0),	shared
	     memory is not be used. If this option is set, sendmail can	 share
	     some data between different instances. For	example, the number of
	     entries in	a queue	directory or the available  space  in  a  file
	     system.  This  allows for more efficient program execution, since
	     only one process needs to update the data instead of  each	 indi-
	     vidual process gathering the data each time it is required.

	     If	 set,  From:  lines  that have embedded	newlines are unwrapped
	     onto one line.

	     If	this option and	the HostStatusDirectory	option are  both  set,
	     use single	thread deliveries to other hosts.

       SmtpGreetingMessage or $e
	     The initial SMTP greeting message.

       StatusFile (Sfile)
	     Log   statistics	in   the  named	 file.	By  default,  this  is
	     /etc/mail/ As root, you must touch(1)	this  file  to
	     enable mailstats(1).

       SuperSafe (s)
	     This  option can be set to	True, False, or	Interactive. If	set to
	     True, sendmail is set to super-safe when running things, that is,
	     always  instantiate  the queue file, even if you are going	to at-
	     tempt immediate delivery. sendmail	always instantiates the	 queue
	     file  before  returning  control  to the client under any circum-
	     stances. This should really always	be set to True.	 The  Interac-
	     tive  value  has been introduced in 8.12 and can be used together
	     with DeliveryMode=i. It skips some	 synchronization  calls	 which
	     are effectively doubled in	the code execution path	for this mode.

       TempFileMode (Fmode)
	     The file mode for queue files.

       Timeout (rtimeouts)
	     Timeout  reads  after  time  interval. The	timeouts argument is a
	     list of keyword=value pairs. All  but  command  apply  to	client
	     SMTP. For backward	compatibility, a timeout with no keyword= part
	     is	set all	of the longer  values.	The  recognized	 timeouts  and
	     their  default  values, and their minimum values specified	in RFC
	     1123 section 5.3.2	are:

		   all connections for a single	delivery attempt [0,  unspeci-

		   command read	[1h, 5m]

		   initial connect [0, unspecified]

		   complete control socket transaction [2m, none]

		   data	block read [1h,	3m]

		   reply to final . in data [1h, 10m]

		   reply to DATA command [5m, 2m]

		   file	open [60sec, none]

	     helo  reply to HELO or EHLO command [5m, none]

		   host	retry [30m, unspecified]

		   first attempt to connect to a host [0, unspecified]

	     ident IDENT protocol timeout [5s, none]

		   wait	for initial greeting message [5m, 5m]

	     lhlo  wait	for reply to an	LMTP LHLO command [2m, unspecified].

	     mail  reply to MAIL command [10m, 5m]

	     misc  reply to NOOP and VERB commands [2m,	none]

		   undeliverable message returned [5d]

		   deferred warning [4h]

	     quit  reply to QUIT command [2m, none]

	     rcpt  reply to RCPT command [1h, 5m]

		   Resolver's	retransmission	 time  interval	 (in  seconds)
		   [varies].  Sets  both  Timeout.resolver.retrans.first   and

		   Resolver's  retransmission  time  interval (in seconds) for
		   the first attempt to	deliver	a message [varies].

		   Resolver's retransmission time interval  (in	 seconds)  for
		   all look-ups	except the first delivery attempt [varies].

		   Number  of  times  to retransmit a resolver query [varies].
		   Sets	 both  Timeout.resolver.retry.first  and

		   Number  of  times  to  retransmit  a	resolver query for the
		   first attempt to deliver a message [varies].

		   Number of times to retransmit  a  resolver  query  for  all
		   look-ups except the first delivery attempt [varies].

	     rset  reply to RSET command [5m, none]

       TimeZoneSpec (ttzinfo)
	     Set  the local time zone info to tzinfo, for example, "PST8PDT ".
	     Actually, if this is not set,  the	 TZ  environment  variable  is
	     cleared  (so  the	system	default	is used); if set but null, the
	     user's TZ variable	is used, and if	set and	non-null, the TZ vari-
	     able is set to this value.

	     The  user	parameter  can be a user name (looked up in the	passwd
	     map) or a numeric user id.	Trusted	user for  file	ownership  and
	     starting  the  daemon.  If	set, generated alias databases and the
	     control socket (if	configured) are	automatically  owned  by  this

       TryNullMXList (w)
	     If	you are	the "best" (that is, lowest preference)	MX for a given
	     host, you should normally detect this situation  and  treat  that
	     condition	specially,  by	forwarding  the	 mail  to a UUCP feed,
	     treating it as local, or whatever.	However, in some  cases	 (such
	     as	Internet firewalls) you	may want to try	to connect directly to
	     that host as though it had	no MX records at all. Setting this op-
	     tion  causes sendmail to try this.	The downside is	that errors in
	     your configuration	are likely to be diagnosed as  "host  unknown"
	     or	"message timed out" instead of something more meaningful. This
	     option is deprecated.

       UnixFromLine or $l
	     The "From " line used when	sending	to files or programs.

	     If	set, group-writable :include: and .forward files  are  consid-
	     ered  "unsafe",  that  is,	 programs and files cannot be directly
	     referenced	from such files.

       UseErrorsTo (l)
	     If	there is an Errors-To: header, send error messages to the  ad-
	     dresses  listed  there.  They normally go to the envelope sender.
	     Use of this option	causes sendmail	to violate RFC 1123. This  op-
	     tion is not recommended and deprecated.

	     Use  as  mail  submission program,	that is., allow	group writable
	     queue files if the	group is the same as that  of  a  set-group-id
	     sendmail binary.

       UserDatabaseSpec	(U)
	     Defines  the  name	and location of	the file containing User Data-
	     base information.

       Verbose (v)
	     Run in verbose mode. If this is set, sendmail adjusts the HoldEx-
	     pensive  and  DeliveryMode	 options so that all mail is delivered
	     completely	in a single job	so that	you can	see the	entire	deliv-
	     ery  process.  The	Verbose	option should never be set in the con-
	     figuration	file; it is intended for command line use only.

	     Set the threshold,	in bytes, before a  memory-bases  queue	 tran-
	     script file becomes disk-based. The default is 4096 bytes.

       If  the first character of the user name	is a vertical bar, the rest of
       the user	name is	used as	the name of a program to pipe the mail to.  It
       may  be	necessary  to quote the	name of	the user to keep sendmail from
       suppressing the blanks from between arguments.

       If invoked as newaliases, sendmail rebuilds the alias database, so long
       as  the	/etc/mail/aliases* files are owned by root and root has	exclu-
       sive write permission. If invoked as mailq, sendmail  prints  the  con-
       tents of	the mail queue.

	     address of	an intended recipient of the message being sent.

       See  largefile(5)  for the description of the behavior of sendmail when
       encountering files greater than or equal	to 2 Gbyte ( 2**31 bytes).

       sendmail	returns	an exit	status describing what it did. The  codes  are
       defined in /usr/include/sysexits.h.

       EX_OK Successful	completion on all addresses.

	     User name not recognized.

	     Catchall. Necessary resources were	not available.

	     Syntax error in address.

	     Internal software error, including	bad arguments.

	     Temporary operating system	error, such as "cannot fork".

	     Host name not recognized.

	     Message could not be sent immediately, but	was queued.

	     Unmailable	text

	     Mail aliases file (ASCII)

	     Database of mail aliases (binary)

	     Database of mail aliases (binary)

	     Database of mail aliases (binary)

	     Defines environment for sendmail

	     Defines environment for sendmail

	     Temporary files and queued	mail

	     Temporary files and queued	mail

	     List of recipients	for forwarding messages

       See attributes(5) for descriptions of the following attributes:

       |      ATTRIBUTE	TYPE	     |	    ATTRIBUTE VALUE	   |
       |Availability		     |SUNWsndmu			   |

       biff(1B),  mail(1),  mailq(1),  mailx(1),  nice(1), check-hostname(1M),
       check-permissions(1M), newaliases(1M), fork(2), getpwnam(3C),  getuser-
       shell(3C),  resolver(3RESOLV),  aliases(4),  hosts(4),  shells(4),  at-
       tributes(5), largefile(5)

       Postel, Jon, Simple Mail	Transfer Protocol, RFC 821,  Network  Informa-
       tion Center, SRI	International, Menlo Park, Calif., August 1982.

       Crocker,	 Dave, Standard	for the	Format of ARPA-Internet	Text Messages,
       RFC 822,	Network	Information Center,  SRI  International,  Menlo	 Park,
       Calif., August 1982.

       Costales,  Bryan	with Eric Allman, sendmail, Second Edition, O'Reilly &
       Associates, Inc., 1997.

       The sendmail program requires a fully qualified host name  when	start-
       ing.  A script has been included	to help	verify if the host name	is de-
       fined properly (see check-hostname(1M)).

       The permissions and the ownership  of  several  directories  have  been
       changed	in  order  to  increase	 security.  In	particular,  access to
       /etc/mail and /var/spool/mqueue has been	restricted.

       Security	restrictions have been placed users using  .forward  files  to
       pipe  mail  to  a program or redirect mail to a file. The default shell
       (as  listed  in	/etc/passwd)  of  these	 users	must  be   listed   in
       /etc/shells.  This restriction does not affect mail that	is being redi-
       rected to another alias.

       Additional restrictions have been put in	place  on  .forward  and  :in-
       clude:  files.  These  files  and the directory structure that they are
       placed  in  cannot  be  group-  or   world-writable   (seecheck-permis-

       If  you	have  interfaces that map to domains that have MX records that
       point to	non-local destinations,	you might need	to  enable  the	 Dont-
       ProbeInterfaces option to enable	delivery to those destinations.	In its
       default startup behavior, sendmail probes each interface	 and  adds  an
       interface's  IP	addresses, as well as any domains that those addresses
       map to, to its list of domains that are considered local.  For  domains
       thus  added, being on the list of local domains is equivalent to	having
       a 0-preference MX record, with localhost	as the MX value.  If  this  is
       not the result you want,	enable DontProbeInterfaces.

SunOS 5.9			  16 Nov 2001			  sendmail(1M)


Want to link to this manual page? Use this URL:

home | help