SuSE GmbH

SuSE Support Database

Title: Receiving Mails from your provider

----------

Mainpage o Searchform o History o Versions o Categories o Contents
Deutsch

----------

Receiving Mails from your provider

Applies to

SuSE Linux: Versions since 4.4
fetchmail: Version 3.3 pl 1 - 4.3.3

Question:

How do I receive mail from a server using the POP3 protocol and deliver it to a local mail host?

Solution:

This can be achieved by using fetchmail (package pop, series n).

The advantage of using fetchmail and not the older popclient is that your password is not shown in the process table. Only your mail server and the POP3 client exchange the password, which is stored in a file on your local host.

Installation:

There are several ways to accomplish this, so this is just an example:

Your mail server is mail.provider.de. You have two accounts there, asterix and obelix. They are called eva and maria on your local machine. Their respective passwords on the mail server are adam and josef.

Multidrop mode:

Some providers do compile mails for multiple users on one POP3 account. Using the solution detailed above, you can receive mail then, but it would be delivered to only one local account.

For multidrop mode it is important wether your provider just leaves the destination address alone or replaces it e.g. with the address of the POP3 account.

Destination address is not replaced:

fetchmail can then just forward the messages to sendmail. Fetchmail only has to know its local domain names, e.g. if your domain is domain.de then your .fetchmailrc might look like this:
poll mail.provider.de protocol POP3 localdomains domain.de user asterix password adam is *
There is nothing special about using sendmail with fetchmail, local aliases can be defined in /etc/aliases; non-deliverable mails will usually be send to postmaster (which in most cases is an alias for root).

Destination address is replaced:

In this case, fetchmail has no way (at least known to me) for knowing the recipient. The only way would then be parsing the header.

One way to accomplish this is to create a local user (e.g. mailer), which processes all incoming mail using his ~/.procmailrc to deliver mail to the correct users.

----------

See also:

----------

Keywords: FETCHMAIL, POP3, SENDMAIL, MAIL, PPP, ISDN

----------

Categories: Email , Applications

----------

Feedback welcome: Send Mail to kfr@suse.de (Please give the following subject: SDB-fetchmail)

----------

Mainpage o Searchform o History o Versions o Categories o Contents
Deutsch

----------

SDB-fetchmail, Copyright SuSE GmbH, Nuremberg, Germany - Version:
SuSE GmbH - Last generated: 07. Oct 1999 16:39:29 by maddin with sdb_gen 1.00.0