25.02.2013 Views

TCP/IP Tutorial and Technical Overview - IBM Redbooks

TCP/IP Tutorial and Technical Overview - IBM Redbooks

TCP/IP Tutorial and Technical Overview - IBM Redbooks

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

TEST.MY.CORP. Instead, it must first query the name server to determine to<br />

which host (domain name) it needs to deliver the message.<br />

For message delivery, the name server stores resource records (RRs), known as<br />

Mail Exchange (MX) RRs. They map a domain name to two values:<br />

► A preference value. Because multiple MX resource records can exist for the<br />

same domain name, a preference (priority) is assigned to them. The lowest<br />

preference value corresponds to the most preferred record. This is useful<br />

whenever the most preferred host is unreachable; the sending SMTP then<br />

tries to contact the next preferred host.<br />

► A host name.<br />

It is also possible that the name server responds with an empty list of MX RRs.<br />

This means that the domain name is in the name server's authority, but has no<br />

MX assigned to it. In this case, the sending SMTP might try to establish the<br />

connection with the host name itself.<br />

An important recommendation is given in RFC 2821: After obtaining the MX<br />

records, the sending SMTP should query the name server for well-known<br />

services (WKS) records for this host <strong>and</strong> check that the referenced host has<br />

SMTP as a WKS entry.<br />

Note: Even though this is only a recommendation, it is widely used in most<br />

SMTP implementations.<br />

Here is an example containing MX resource records:<br />

mydiv.mycorp.com. IN MX 0 smtp1.mydiv.redbookscorp.com.<br />

IN MX 2 smtp2.mydiv.redbookscorp.com.<br />

IN MX 4 smtp3.mydiv.redbookscorp.com.<br />

IN WKS 10.12.34.56 <strong>TCP</strong> (SMTP)<br />

In this example, mail for mydiv.mycorp.com should be delivered to<br />

smtp1.mydiv.mycorp.com, because it has a preference of 0. If this host is<br />

unreachable, the mail should instead be delivered to the next preferred server,<br />

smtp2.mydiv.mycorp.com, which has a preference of 2. If this host is not<br />

available, the mail is delivered to the least preferred server,<br />

smtp3.mydiv.mycorp.com.<br />

A problem arises when using SMTP <strong>and</strong> MX records in mixed <strong>IP</strong>v4 <strong>and</strong> <strong>IP</strong>v6<br />

environments. Specifically, a user sending an e-mail does not necessarily know if<br />

all of the servers <strong>and</strong> gateways the message will traverse are all <strong>IP</strong>v4 or <strong>IP</strong>v6<br />

566 <strong>TCP</strong>/<strong>IP</strong> <strong>Tutorial</strong> <strong>and</strong> <strong>Technical</strong> <strong>Overview</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!