|
CentOS Linux Server Guide |
Postfix Mail System- Step by Step GuidePart 9: Getting Email from another Mail server (aka Mail Fetcher/ Mail Redirection) |
|||||||||
|
Sometimes, you might need to download email from other mail server or mail provider such as Gmail or Hotmail to your local server' mailbox. For example, I have multiple email accounts hosted at other hosting companys and I want to download all of them via POP3 to my local mailbox.
The easiest way to perform mail redirection is using fecthmail.
Step 1 fecthmail InstallationInstall fetchmail using yum command.
Step2 Create a fetchmailrc.confSince fectchmail does not come with fetchmail configuration file. We need to create a configuration file under /etc.
Next, according your needs copy the following configuration to the /etc/fetchmailrc.conf
Step3 Create a fetchmail init scriptAgain, the fetchmail we installed earlier does not come with init script. we need to create manually
First, we need to create a fetchmail file
Next, copy all the lines into the /etc/init.d/fetchmail file. Note: I google the following script earlier but forget the author name, if you know who is author, please send me an email, so that I can put his name here.
Step4 Enable fecthmail startup in Linux Box processYou need to add the fecthmail initd script created earlier into chkconfig
Next, don't forget turn it on, so that the fecthmail can autostart at boot level 3-5
Step5 Start your fecthmail scriptNow let us start the script using service command.
Step6 Verify the mail redirection processNow, lets have a look at pop3 mail downloading process. The "tail -f" command allow you to see the maillong in real time. Wait for few minutes and see if any mail downloaded. The following shows that there were 11 mails downloaded from mailserver.myISPMail.com mail server into my mailbox. Check your email now via webmail or outlook/thunderbird, there should be email downloaded.
|
|||||||||
|
Back to Step by Step Guide on CentOS Linux Postfix Mail Server |
|
Copyright 2011 http://www.1a-centosserver.com All Rights Reserved All trademarks are the property of their respective owners. Contact Us | Terms of Use | Privacy Policy |