Author: Tim Lyons
Email: tlyons@digitalvoodoo.org
Web Page: http://www.digitalvoodoo.org/
Date Submitted: Tue, Jun 23, 1998
Status: New Entry

Releases: 5.0
Platform: intel
Category:  Email
Category Listing:  How do I setup Fetchmail to retrieve my POP mail

Issue

This should explain quite clearly how to setup fetchmail (in a 
single user scenario) to retrieve mail and also setup sendmail to 
masquerade your identity. 

Response

Here's how I setup my laptop (running sendmail) to get/send mail for me using fetchmail/pine.

1. Printed/read MAN Pages for fetchmail (man -t fetchmail | lpr)

2. went to package store for beer... (sorry, tension breaker)

3. Threw MAN pages i n corner with the rest of 'em (-:

4. first I created the file .fetchmailrc in my home directory (/home/timl)

5. Now open ~/.fetchmailrc in your favorite editor and add the following (subsituting the **variables** with your specific information):

#Default Fetchmail.rc file for **LOCALUSER**


# poll **MAILSERVER** proto POP3 user **MAILUSER** pass **MAILPASSWD**


#


# end .fetchmailrc

6. Now my big dilemma was figuring out how to get pine to stop saying who I really was. At first I just forced the correct reply-to in the custom-headers, but since this is a single user worksta! ! tion (and I SEND primarily from one account) I decided to add the following masquerading rules to end of my /etc/sendmail.cf:

# Masquerading rules


S1 Rtiml<@taz.bbn.com> $@ tlyons < @ digitalvoodoo.org>
Rtiml<@taz.bbn.com.> $@ tlyons < @ digit alvoodoo.org.>

This tells sendmail to convert the from address of every message sent from timl@taz.bbn.com to tlyons@digitalvoodoo.org (my primary identity).

(BTW - my sendmail.cw file is blank.)

7. Now - to check the mail you have th ree options:

a. while logged in as you run 'fetchmail -v' from the shell prompt when you want to check/retrieve mail (do this anytime)
b. while logged in as you run 'fetchmail -t 30 -d sss (sss being the number of seconds between polls) This pu ts fetchmail in "daemon" mode (running in the background and checking mail every sss seconds)
c. edit your crontab as follows: (my favorite)

taz% crontab -e (this will open your crontab in the default editor - add t! ! he following to check twice hour ly)

29,59 * * * * /usr/bin/fetchmail -s -t 30

You should now be getting all the mail destined for your remote POP account. Any questions, please ask...

References

(none)