Debian下使用让Exim4通过Gmail发邮件
November 25th, 2010 4:23 PM 57 Comments Filed under: 鸡贼 Feed for this Entry
准备工作:
apt-get install -y exim4 apt-get install -y mutt
其实debian一般默认安装是有exim4的,不保准有的精简安装版没有,apt-get一下吧。
配置:
dpkg-reconfigure exim4-config
第一步:布拉布拉布拉,OK
第二步:mail sent by smarthost; received via SMTP or fetchmail ,OK
第三步:System mail name: 输入本机域名:malegebi.com,OK
第四步: Please enter a semicolon-separated list of IP addresses. The Exim SMTP listener daemon will listen on all IP addresses listed here. ,继续OK
第五步: IP-addresses to listen on for incoming SMTP connections: 输入127.0.0.1,继续OK
第六步: Other destinations for which mail is accepted: 留空,继续OK
第七步:Machines to relay mail for: 留空,继续OK
第八步:IP address or host name of the outgoing smarthost: 输入smtp.gmail.com::587,继续OK
第九步:Hide local mail name in outgoing mail? ,选NO
第十步:布拉布拉布拉,OK
第十一步:Keep number of DNS-queries minimal (Dial-on-Demand)?,选NO
第十二步:Delivery method for local mail: 选mbox format in /var/mail/ ,继续OK
第十三步:Split configuration into small files? ,选YES
第十四步:布拉布拉布拉,OK
第十五步: Root and postmaster mail recipient:留空,继续OK
第十六步:exim4这时自动重启。
继续
第十七步:
vim /etc/exim4/passwd.client
加入
*.google.com:你的Gmail邮箱用户名@gmail.com:你的密码
第十八步:
chown root:Debian-exim /etc/exim4/passwd.client
第十九步:
vim /etc/exim4/conf.d/transport/30_exim4-config_remote_smtp_smarthost
在“remote_smtp_smarthost:”这段最后一个“}”下添加:
port=587
第二十步:
echo 'YOUR-USER-NAME@LocalHost: 你的gmail邮箱用户名@gmail.com' >> /etc/exim4/email-addresses
第二十一步:
update-exim4.conf
搞定!
测试
echo "邮件正文" | mutt -s "标题" [email protected] #改[email protected]为期望接收到邮件的邮箱。
57 Comments
May 6th, 2012 at 07:46 pm
Good site,
phentermine , buy zolpidem , buy valium , buy xanax ,
May 5th, 2012 at 04:18 pm
Sorry but,
buy xanax online ,
May 3rd, 2012 at 10:40 pm
Sorry but,
cheap phentermine ,
May 2nd, 2012 at 02:41 pm
Perfect!
buy adipex p ,
April 26th, 2012 at 07:36 pm
Hi there!
cialis , buy viagra online , propecia ,
April 23rd, 2012 at 04:22 pm
Hi there!
vimax , vigrx ,
April 20th, 2012 at 03:31 pm
Good site,ription ,
cheap viagra , cheap viagra no presc
April 17th, 2012 at 07:54 pm
Hi there!ription ,
ambien , valium , xanax no presc
April 6th, 2012 at 12:15 am
Perfect!
sildenafil online , cialis online , vigrx online , buy vimax ,
March 31st, 2012 at 08:37 pm
Hello!
brand xanax , generic klonopin , buy valium , ativan online ,
March 29th, 2012 at 10:17 pm
Good site,
viagra pills , cialis online ,
March 26th, 2012 at 09:52 pm
Good site,
brand ambien ,
March 23rd, 2012 at 11:10 pm
Very nice site!
March 23rd, 2012 at 11:07 pm
Hello! ebeegbk interesting ebeegbk site! I'm really like it! Very, very ebeegbk good!
March 22nd, 2012 at 11:53 pm
Very nice site! cheap cialis http://opeyixa.com/qoaxqo/4.html
March 22nd, 2012 at 11:52 pm
Hello! decfgba interesting decfgba site! I'm really like it! Very, very decfgba good!
March 19th, 2012 at 04:31 pm
Hi there!
March 18th, 2012 at 05:17 pm
Hello!
March 15th, 2012 at 08:41 pm
Perfect!
March 14th, 2012 at 09:27 pm
Aloha!
Leave a comment