Next   Contents       (Exim 4.40 Specification)

1. Introduction

If I have seen further it is by standing on the shoulders of giants. (Isaac Newton).

Exim is a mail transfer agent (MTA) for hosts that are running Unix or Unix-like operating systems. It was designed on the assumption that it would be run on hosts that are permanently connected to the Internet. However, it can be used on intermittently connected hosts with suitable configuration adjustments.

Configuration files currently exist for the following operating systems: AIX, BSD/OS (aka BSDI), Darwin (Mac OS X), DGUX, FreeBSD, GNU/Hurd, GNU/Linux, HI-OSF (Hitachi), HP-UX, IRIX, MIPS RISCOS, NetBSD, OpenBSD, QNX, SCO, SCO SVR4.2 (aka UNIX-SV), Solaris (aka SunOS5), SunOS4, Tru64-Unix (formerly Digital UNIX, formerly DEC-OSF1), Ultrix, and Unixware. Some of these operating systems are no longer current and cannot easily be tested, so the configuration files may no longer work in practice.

There are also configuration files for compiling Exim in the Cygwin environment that can be installed on systems running Windows. However, this document does not contain any information about running Exim in the Cygwin environment.

The terms and conditions for the use and distribution of Exim are contained in the file NOTICE. Exim is distributed under the terms of the GNU General Public Licence, a copy of which may be found in the file LICENCE.

The use, supply or promotion of Exim for the purpose of sending bulk, unsolicited electronic mail is incompatible with the basic aims of the program, which revolve around the free provision of a service that enhances the quality of personal communications. The author of Exim regards indiscriminate mass-mailing as an antisocial, irresponsible abuse of the Internet.

Exim owes a great deal to Smail 3 and its author, Ron Karr. Without the experience of running and working on the Smail 3 code, I could never have contemplated starting to write a new MTA. Many of the ideas and user interfaces were originally taken from Smail 3, though the actual code of Exim is entirely new, and has developed far beyond the initial concept.

Many people, both in Cambridge and around the world, have contributed to the development and the testing of Exim, and to porting it to various operating systems. I am grateful to them all. The distribution now contains a file called ACKNOWLEDGMENTS, in which I have started recording the names of contributors.

1.1. Exim documentation

This edition of the Exim specification applies to version 4.40 of Exim. Substantive changes from the 4.30 edition are marked by bars in the right-hand margin in the PostScript, PDF, and plain text versions of the document, and by green text in the HTML version, as shown by this paragraph. Changes are not marked in the Texinfo version, because Texinfo doesn't support change bars. Minor corrections and rewordings are not marked.

This document is very much a reference manual; it is not a tutorial. The reader is expected to have some familiarity with the SMTP mail transfer protocol and with general Unix system administration. Although there are some discussions and examples in places, the information is mostly organized in a way that makes it easy to look up, rather than in a natural order for sequential reading. Furthermore, the manual aims to cover every aspect of Exim in detail, including a number of rarely-used, special-purpose features that are unlikely to be of very wide interest.

An “easier” discussion of Exim which provides more in-depth explanatory, introductory, and tutorial material can be found in a book entitled The Exim SMTP Mail Server, published by UIT Cambridge.

This book also contains a chapter that gives a general introduction to SMTP and Internet mail. Inevitably, however, the book is unlikely to be fully up-to-date with the latest release of Exim. (Note that the earlier book about Exim, published by O'Reilly, covers Exim 3, and many things have changed in Exim 4.)

As the program develops, there may be features in newer versions that have not yet made it into this document, which is updated only when the most significant digit of the fractional part of the version number changes. However, specifications of new features that are not yet in this manual are placed in the file doc/NewStuff in the Exim distribution. All changes to the program (whether new features, bug fixes, or other kinds of change) are noted briefly in the file called doc/ChangeLog.

This specification itself is available as an ASCII file in doc/spec.txt so that it can easily be searched with a text editor. Other files in the doc directory are:

  OptionLists.txt  list of all options in alphabetical order
  dbm.discuss.txt  discussion about DBM libraries
  exim.8  a man page of Exim's command line options
  filter.txt  specification of the filter language
  pcrepattern.txt  specification of PCRE regular expressions
  pcretest.txt  specification of the PCRE testing program
  Exim3.upgrade  upgrade notes from release 2 to release 3
  Exim4.upgrade  upgrade notes from release 3 to release 4

The main specification and the specification of the filtering language are also available in other formats (HTML, PostScript, PDF, and Texinfo). Section 1.5 below tells you how to get hold of these.

1.2. FTP and web sites, and mailing list

The primary distribution site for Exim is an FTP site, whose contents are described in Where to find the Exim distribution below. In addition, there is a web site at http://www.exim.org by courtesy of Energis Squared, formerly Planet Online Ltd, who are situated in the UK. The site is mirrored in a number of other countries; links to the mirrors are listed on the home page. The web site contains the Exim distribution, and you can also find the documentation and the FAQ online there, as well as other relevant material.

Energis Squared also provide resources for the following mailing lists:

  exim-users@exim.org  general discussion list
  exim-announce@exim.org  moderated, low volume announcements list

You can subscribe to these lists, change your existing subscriptions, and view or search the archives via the mailing lists link on the Exim home page. The exim-users mailing list is also forwarded to http://www.egroups.com/list/exim-users, an archiving system with searching capabilities.

1.3. Exim training

From time to time (approximately annually at the time of writing), lecture-based training courses are run by the author of Exim in Cambridge, UK. Details can be found on the web site http://www-tus.csx.cam.ac.uk/courses/exim/.

1.4. Bug reports

Reports of obvious bugs should be emailed to bugs@exim.org. However, if you are unsure whether some behaviour is a bug or not, the best thing to do is to post a message to the exim-users mailing list and have it discussed.

1.5. Where to find the Exim distribution

The master ftp site for the Exim distribution is

  ftp://ftp.csx.cam.ac.uk/pub/software/email/exim

Within that directory there are subdirectories called exim3 (for previous Exim 3 distributions), exim4 (for the latest Exim 4 distributions), and Testing for occasional testing versions. Those mirror sites that I know about are listed in the file

  ftp://ftp.csx.cam.ac.uk/pub/software/email/exim/Mirrors

In the exim4 subdirectory, the current release can always be found in files called

  exim-n.nn.tar.gz
  exim-n.nn.tar.bz2

where n.nn is the highest such version number in the directory. The two files contain identical data; the only difference is the type of compression. The .bz2 file is usually a lot smaller than the .gz file. The distributions are signed with Philip Hazel's GPG key. The corresponding public key is available from a number of keyservers, and there is also a copy in the file:

  ftp://ftp.csx.cam.ac.uk/pub/software/email/exim/Public-Key

The signatures for the tar bundles are in:

  exim-n.nn.tar.gz.sig
  exim-n.nn.tar.bz2.sig

When there is only a small amount of change from one release to the next, a patch file may be provided, with a final component name of the form

  exim-patch-n.nn-m.mm.gz

For each released version, the log of changes is made separately available in the directory

  ftp://ftp.csx.cam.ac.uk/pub/software/email/exim/ChangeLogs

so that it is possible to find out what has changed without having to download the entire distribution.

The main distribution contains ASCII versions of this specification and other documentation; other formats of the documents are available in separate files inside the exim4 directory of the FTP site:

  exim-html-n.nn.tar.gz
  exim-pdf-n.nn.tar.gz
  exim-postscript-n.nn.tar.gz
  exim-texinfo-n.nn.tar.gz

These tar files contain only the doc directory, not the complete distribution, and are also available in .bz2 as well as .gz forms.

The FAQ is available for downloading in two different formats from

  ftp://ftp.csx.cam.ac.uk/pub/software/email/exim/exim4/FAQ.txt.gz
  ftp://ftp.csx.cam.ac.uk/pub/software/email/exim/exim4/FAQ.html.tar.gz

The first of these is a single ASCII file that can be searched with a text editor. The second is a directory of HTML files, normally accessed by starting at index.html. The HTML version of the FAQ (which is also included in the HTML documentation tarbundle) includes a keyword-in-context index, which is often the most convenient way of finding your way around.

1.6. Wish list

A wish list is maintained, containing ideas for new features that have been submitted. From time to time the file is exported to the ftp site:

  ftp://ftp.csx.cam.ac.uk/pub/software/email/exim/exim4/WishList

Items are removed from the list if they get implemented.

1.7. Contributed material

At the ftp site, there is a directory called

  ftp://ftp.csx.cam.ac.uk/pub/software/email/exim/exim4/Contrib/

which contains miscellaneous files contributed to the Exim community by Exim users. There is also a collection of contributed configuration examples in

  ftp://ftp.csx.cam.ac.uk/pub/software/email/exim/exim4/config.samples.tar.gz

These samples are referenced from the FAQ.

1.8. Limitations

1.9. Run time configuration

Exim's run time configuration is held in a single text file that is divided into a number of sections. The entries in this file consist of keywords and values, in the style of Smail 3 configuration files. A default configuration file which is suitable for simple online installations is provided in the distribution, and is described in chapter 7 below.

1.10. Calling interface

Like many MTAs, Exim has adopted the Sendmail command line interface so that it can be a straight replacement for /usr/lib/sendmail or /usr/sbin/sendmail when sending mail, but you do not need to know anything about Sendmail in order to run Exim. For actions other than sending messages, Sendmail-compatible options also exist, but those that produce output (for example, -bp, which lists the messages on the queue) do so in Exim's own format. There are also some additional options that are compatible with Smail 3, and some further options that are new to Exim. Chapter 5 documents all Exim's command line options. This information is automatically made into the man page that forms part of the Exim distribution.

Control of messages on the queue can be done via certain privileged command line options. There is also an optional monitor program called eximon, which displays current information in an X window, and which contains a menu interface to Exim's command line administration options.

1.11. Terminology

The body of a message is the actual data that the sender wants to transmit. It is the last part of a message, and is separated from the header (see below) by a blank line.

When a message cannot be delivered, it is normally returned to the sender in a delivery failure message. The term bounce is commonly used for this action, and the error reports are often called bounce messages. This is a convenient shorthand for “delivery failure error report”. Such messages have an empty sender address in the message's envelope (see below) to ensure that they cannot themselves give rise to further bounce messages.

The term default appears frequently in this manual. It is used to qualify a value which is used in the absence of any setting in the configuration. It may also qualify an action which is taken unless a configuration setting specifies otherwise.

The term defer is used when the delivery of a message to a specific destination cannot immediately take place for some reason (a remote host may be down, or a user's local mailbox may be full). Such deliveries are deferred until a later time.

The word domain is sometimes used to mean all but the first component of a host's name. It is not used in that sense here, where it normally refers to the part of an email address following the @ sign.

A message in transit has an associated envelope, as well as a header and a body. The envelope contains a sender address (to which bounce messages should be delivered), and any number of recipient addresses. References to the sender or the recipients of a message usually mean the addresses in the envelope. An MTA uses these addresses for delivery, and for returning bounce messages, not the addresses that appear in the header lines.

The header of a message is the first part of a message's text, consisting of a number of lines, each of which has a name such as From:, To:, Subject:, etc. Long header lines can be split over several text lines by indenting the continuations. The header is separated from the body by a blank line.

The term local part, which is taken from RFC 2822, is used to refer to that part of an email address that precedes the @ sign. The part that follows the @ sign is called the domain or mail domain.

The terms local delivery and remote delivery are used to distinguish delivery to a file or a pipe on the local host from delivery by SMTP over TCP/IP to a remote host.

Return path is another name that is used for the sender address in a message's envelope.

The term queue is used to refer to the set of messages awaiting delivery, because this term is in widespread use in the context of MTAs. However, in Exim's case the reality is more like a pool than a queue, because there is normally no ordering of waiting messages.

The term queue runner is used to describe a process that scans the queue and attempts to deliver those messages whose retry times have come. This term is used by other MTAs, and also relates to the command runq, but in Exim the waiting messages are normally processed in an unpredictable order.

The term spool directory is used for a directory in which Exim keeps the messages on its queue – that is, those that it is in the process of delivering. This should not be confused with the directory in which local mailboxes are stored, which is called a “spool directory” by some people. In the Exim documentation, “spool” is always used in the first sense.


Next  Contents       (Exim 4.40 Specification)