imip-agent

Annotated docs/wiki/MailIntegration--MTA

1024:48b37822d2a0
2016-01-29 Paul Boddie Moved common test initialisation into a separate script.
paul@984 1
= Mail Transfer Agents =
paul@984 2
paul@984 3
Although this documentation does not seek to cover the details of configuring
paul@984 4
mail transfer agent (MTA) software, some hints and tips are offered to help
paul@984 5
avoid frustration.
paul@984 6
paul@988 7
<<TableOfContents(2,3)>>
paul@988 8
paul@984 9
== General ==
paul@984 10
paul@984 11
Some general measures are presented below.
paul@984 12
paul@984 13
=== Hostname ===
paul@984 14
paul@984 15
The `hostname` command should provide a suitable hostname on the system, or MTAs
paul@984 16
may behave strangely. This can be tested with the following command:
paul@984 17
paul@984 18
{{{
paul@984 19
hostname -f
paul@984 20
}}}
paul@984 21
paul@984 22
It should report a fully-qualified hostname.
paul@984 23
paul@988 24
=== Mailname ===
paul@988 25
paul@988 26
The contents of `/etc/mailname` should probably be the fully-qualified hostname,
paul@988 27
at least for Exim and Postfix. See
paul@988 28
[[https://wiki.debian.org/EtcMailName|the Debian Wiki page]] for more details.
paul@988 29
paul@984 30
=== Interfaces ===
paul@984 31
paul@988 32
Some software attempts to listen on interfaces that may not be supported. For
paul@988 33
example, Exim may be configured to listen on both IPv4 and IPv6 interfaces, even
paul@988 34
in environments (such as User Mode Linux) where IPv6 interfaces may not be
paul@988 35
available.
paul@988 36
paul@988 37
=== Authentication ===
paul@988 38
paul@988 39
It is highly undesirable to allow anyone to connect to a mail server to send
paul@988 40
mail. However, it is highly convenient to allow imip-agent to connect to the
paul@988 41
mail server on the same host without having to provide credentials. Consequently,
paul@988 42
the configuration of an MTA must permit the latter without allowing the former.
paul@988 43
paul@988 44
Fortunately, many MTAs are configured to allow local connections because programs
paul@988 45
typically rely on such traditional behaviour, but this may be worth checking if
paul@988 46
mail server logs indicate authentication failures when imip-agent is attempting
paul@988 47
to send mail.
paul@984 48
paul@984 49
== Exim ==
paul@984 50
paul@984 51
On Debian, the following command can be run to adjust the configuration:
paul@984 52
paul@984 53
{{{
paul@984 54
dpkg-reconfigure exim4-config
paul@984 55
}}}
paul@984 56
paul@984 57
The following questions are especially interesting:
paul@984 58
paul@984 59
{{{{#!table
paul@984 60
'''Question''' || '''Remarks'''
paul@984 61
==
paul@984 62
IP-addresses to listen on for incoming SMTP connections
paul@984 63
|| Remove IPv6 interfaces in User Mode Linux or other environments without
paul@984 64
.. IPv6 support or Exim will not bother listening on IPv4 interfaces either.
paul@984 65
==
paul@984 66
System mail name
paul@984 67
|| State the fully-qualified hostname, not just the domain name, which is
paul@984 68
.. what the dialogue suggests is sufficient. For example:
paul@984 69
{{{
paul@984 70
mailserver.example.com
paul@984 71
}}}
paul@984 72
==
paul@984 73
Other destinations for which mail is accepted
paul@984 74
|| This is a colon-separated list that should indicate the local domain as
paul@984 75
.. well as the unqualified hostname. For example:
paul@984 76
{{{
paul@984 77
mailserver:example.com
paul@984 78
}}}
paul@984 79
}}}}