The Caboteria / Tech Web / TechNotes > UnixNotes / PostfixComcastAol (14 May 2004, TobyCabot)

AOL Sucks!

Those bastards arbitrarily decided to stop receiving email from machines with dynamic IP addresses. Many GNU/Linux users (like me) like to have their machines deliver mail directly to the recipient's server rather than use the ISP's flaky infrastructure, so we'd prefer to not have to route all of our email through Comcast's email servers.

I use the Postfix MTA and it turns out to be pretty easy to set up to relay email for AOL through the Comcast server and still deliver everything else directly. Here are some hints on how it's done:

The feature that controls how Postfix relays mail is called the "Transport Map" and you can get more details on it by looking at the transport(5) man page.

I use comcast cable modem service, which I'm not all that happy with but it sucks less than other mid-priced alternatives. To get AOL mail relayed through their servers (which will only work if you're on their network), add the following lines to the end of the /etc/postfix/transport file. The file might be in some other location; but that's where it lives in a Debian system.

aol.com :smtp.comcast.net
.aol.com :smtp.comcast.net
cs.com :smtp.comcast.net
.cs.com :smtp.comcast.net

My naive understanding is that you need two lines; one for the AOL domain and one for all subdomains. Since Compuserve is also AOL you need to add entries for them, too.

Postfix is designed to be a high-performance mailer so it reads map files like the transport file as indexed databases so you need to translate the text file into the database format that Postfix likes. You use the postmap command to do this. On my machine the following command works fine:

 # cd /etc/postfix
 # postmap transport

You can check to see if the output map file (called transport.db) is as new or newer than transport. If so then you just need to tell Postfix to look for the transport map by adding a line to /etc/postfix/main.cf like:

transport_maps = hash:/etc/postfix/transport

Then run (as root) postfix check to make sure than Postfix is happy with its configuration and then postfix reload to tell it to use the new configuration.

Now you should see email for AOL relaying through comcast's email servers. You can check your /var/log/mail.info and you should see entries like:

Apr 19 09:53:54 poohpa postfix/smtp[3933]: CB6A015C031: to=<UnfortunateAolUser@aol.com>, relay=smtp.comcast.net[24.153.64.2], delay=3, status=sent (250 2.5.0 Ok.)

2004-05-14 - I dropped this technique because it got too painful to keep up with adding servers to the transport map, and I changed ISP's to RCN who seemed to be able to keep their email servers running. I went back to relaying through RCN until today when I found out that they've been blacklisted by spamcop. Damn. Looks like I'm back to a hand-maintained transport map.

-- TobyCabot - 14 May 2004

Edit | Attach | Print version | History: r3 < r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions
Copyright © 2008-2017 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding The Caboteria? Send feedback