Setting up Mail in Linux

Jason White jason at
Sun Jan 9 07:38:45 UTC 2011

RiverWind <riverwind at> writes:

> I have a fully functional Linux box, except for the mail. I have
> alpine on my system, but I have no earthly idea how to go ab out
> setting up incoming and outgoing mail. I am told that it is a
> dreadfully complicated undertaking. 

It isn't difficult to do. I would suggest installing Postfix, as it is
relatively easy to configure for basic tasks. If you're using Debian,
the installation script will ask a few questions and set up the basics
for you automatically.

After that, have a look at Fetchmail and write a ~/.fetchmailrc file. It
is best to use IMAP if the server from which you retrieve mail supports

There should be a Fetchmail HOWTO available on the Web; I'm sure you
know how to use your favourite search engine to full advantage.

Once you have a basic configuration working, then it's time to
investigate the joys of Procmail, spam filtering, and so forth.

When you're ready to configure Procmail to deliver incoming messages to
various folders, remove spam, delete duplicate messages, etc., the Web
site that I recommend is:
Procmail Quick Start: An introduction to email filtering with a focus on
procmail by Nancy McGough

Modern mail transfer agents such as Postfix can deliver messages with
Procmail. For Postfix, you'll need the following line in your
/etc/postfix/ file:
mailbox_command = /usr/bin/procmail -d ${USER}

I first configured Procmail in the mid 90s on a UNIX account. Since
then, it has saved me many hours of work, since I have never had to sort
my mail manually. Whenever I subscribe to a new mailing list I simply
add a Procmail recipe for it.

More information about the Blinux-list mailing list