我在我的服务器上发送邮件时遇到问题。 我的主人告诉我,这是因为没有通过他们的继电器发送。 他们试图告诉我该怎么做,这里是他们的指示:
Edit /etc/mail/sendmail.cf or /etc/sendmail.cf depend on your operating system. and edit as # “Smart” relay host (may be null) DS<mailserver_hostname> exam. DSspamfilter.de.santrex.net:1001
这两个文件都不存在,他们正在采取永远的回应。 我希望这里有人可能知道一个解决scheme。
我在VPS上运行cPanel / WHM的CentOS5.5
在cpanel中可能有一个特定的方法,但为Exim提供一个普通的答案,你需要创build一个匹配所有非本地邮件的新路由器。 已经有一个名为“dnslookup”的默认eximconfiguration文件。 该路由器将所有非本地邮件路由到名为“remote_smtp”的传输,该传输使用DNS来决定将邮件发送到哪个服务器。
因此,为了向出站邮件服务器添加一个静态路由,在现有的dnslookup路由器上添加一个新的路由器(因为订单在路由器中很重要,你的邮件将由第一个匹配的邮件处理)。
下面是一个例子,在一个简单的configuration中(只有一个出站服务器,在端口25上,没有authentication)应该是正常工作:
static: driver = manualroute domains = ! +local_domains route_list = * <mailserver_hostname> transport = remote_smtp no_more no_verify
下面是一个稍微复杂一些的例子,使用身份validation将pobox.com作为中继,在端口587上进行configuration:
# This goes in ROUTERS section static: driver = manualroute domains = ! +local_domains route_list = * sasl.smtp.pobox.com::587 transport = auth_remote_smtp no_more no_verify # This goes in TRANSPORTS section auth_remote_smtp: driver = smtp hosts_require_auth = * # This goes in AUTHENICATORS section auth_plain: driver = plaintext public_name = plain client_send = ^MYUSERNAME^MYPASSWORD
(pobox只支持authtypes的LOGIN和PLAIN,但它支持Exim将使用的TLS,所以我的信誉只能通过TLS链接)。
以下是我使用上面的configuration在服务器上发送的邮件的日志示例:
2010-11-26 10:04:49 LCHZ81-0000HN-NN <= SENDERADDRESS H=localhost (g3) [127.0.0.1] P=esmtp S=441 2010-11-26 10:04:50 LCHZ81-0000HN-NN => RECIPADDRESS R=static T=auth_remote_smtp H=sasl.smtp.pobox.com [64.74.157.62] X=TLSv1:DHE-RSA-AES256-SHA:256 2010-11-26 10:04:50 LCHZ81-0000HN-NN Completed