我可以将 Google Apps 用于域电子邮件并仍使用“sendmail”吗? 服务器发送电子邮件?

发布于 2024-07-10 13:39:53 字数 530 浏览 8 评论 0原文

我正在使用 Google Apps for Domain 来托管来自我的域的电子邮件,并且我已根据 Google 文档在我的网站上设置了 MX 记录。 我还可以使用“sendmail”服务器从我的网络服务器发送其他电子邮件,而不与 Google APPS 发生冲突吗?

具体问题: 1) 我想将我的 sendmail 服务器的 MX 记录添加到我的网站主机,以避免从我的 sendmail 服务器发送的邮件被标记为垃圾邮件(通过 IP 查找)。Google Apps 的 MX 记录和我的 sendmail 服务器会发生冲突吗? 2) 如果我运行单独的 sendmail 服务器,Google Apps 电子邮件是否仍能正常工作? 我希望 Google Apps 电子邮件接收我的所有电子邮件,并且只想从我的 sendmail 服务器发送额外的邮件。

主要原因是对我发送的电子邮件数量没有限制(目前我的 Google Apps 电子邮件限制我每个电子邮件帐户每天只能发送 250 封电子邮件。)

我想要拥有自己的 sendmail 服务器的 已经做到了这一点,请说出来!

I am using Google Apps for domain to host the email from my domain and I've setup the MX records on my site according to the Google documentation. Can I also use a "sendmail" server to send additional emails from my webserver without there being a conflict with Google APPS?

Specific questions:
1) I want to add MX records for my sendmail server to my webhost to avoid getting mail sent from my sendmail server marked as SPAM (via an IP lookup.) Will the MX records for Google Apps and my sendmail server conflict in any way?
2) Will Google Apps email still work correctly if I have a seperate sendmail server operating? I want Google Apps email to receive all of my emails, and only want to send extra mail from my sendmail server.

The main reason I want to have my own sendmail server is to have no limits on the number of emails I send out (currently my Google Apps email limits me to 250 sent emails a day per email account.)

If there is anyone out there who has done exactly this, please speak up!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

网白 2024-07-17 13:39:53

MX 记录仅影响接收邮件。 尝试向您的域发送电子邮件的场外服务器使用 MX 记录来确定将邮件发送到的主机。 您可以设置 sendmail 主机来发送邮件,而不会对您的 MX 记录或接收邮件产生任何影响。 (SPF 记录确实会影响发送邮件;如果您使用 SPF,则需要更新它以列出您的 Google Apps 主机和 sendmail 主机。)

编辑:由于您的 sendmail 主机仅用于发送邮件时,不应将其列为 MX 记录。 将其列为 MX 记录有几个缺点:

  • 它可能会收到发往您的 Google Apps 主机的邮件。 (即使您给它设置较低的优先级,如果您的 Google Apps 主机关闭,或者出现间歇性 DNS 或网络故障,或者...)
  • 它也可能会收到垃圾邮件,因此您必须进行设置sendmail 主机上的垃圾邮件过滤器,或者您必须重新配置 Google Apps 垃圾邮件过滤器以信任 sendmail 主机(否则它们将无法识别垃圾邮件的真正发件人)。
  • 如果您阻止 SMTP 发送到您的 sendmail 主机,以避免前两个问题,那么您可能会受到垃圾邮件过滤器的惩罚(如 jasonrm 提到的),并且您可能会延迟合法电子邮件的传送(如果有人尝试向您的 sendmail 主机发送电子邮件以进行任何操作)原因并被阻止)。

正如 Zoredache 提到的,未在 MX 记录中列出 sendmail 主机可能会导致某些垃圾邮件过滤器对您造成轻微惩罚,但设置 SPF 应该可以避免这种情况。 (任何精心设计的垃圾邮件过滤器都会尊重 SPF 而非 MX 记录。)

如果您的 sendmail 主机将向您自己的用户发送任何电子邮件,您还需要确保将其配置为将您用户的电子邮件转发到您的 Google Apps主持人。

MX records only affect receiving mail. Off-site servers trying to send email to your domain use MX records to determine which host(s) to send the mail to. You can set up a sendmail host to send mail without it having any effect at all on your MX records or your receiving mail. (SPF records do affect sending mail; if you use SPF, then you'll need to update it to list both your Google Apps hosts and your sendmail hosts.)

EDIT: Since your sendmail host is only for sending mail, it should not be listed as an MX record. Listing it as an MX record has several disadvantages:

  • It may receive mail that's intended for your Google Apps host. (Even if you give it a lower priority, it may receive mail if your Google Apps host is down, or if there's an intermittent DNS or network failure, or...)
  • It will receive spam, so you'll have to set up spam filters on the sendmail host, or you'll have to reconfigure your Google Apps spam filters to trust the sendmail host (otherwise they won't recognize the real sender of the spam).
  • If you block SMTP to your sendmail host, to avoid the first two problems, then you may be penalized by spam filters (as jasonrm mentioned), and you may delay the delivery of legitimate email (if someone tries to email your sendmail host for whatever reason and is blocked).

Not listing a sendmail host in your MX records may cause some spam filters to slightly penalize you, as Zoredache mentioned, but setting up SPF instead should avoid this. (Any well-designed spam filters will honor SPF over MX records.)

If your sendmail host will be sending any email to your own users, you'll also need to make sure to configure it to relay email for your users to your Google Apps host.

亣腦蒛氧 2024-07-17 13:39:53

我还可以使用“sendmail”服务器从我的网络服务器发送其他电子邮件,而不与 Google APPS 发生冲突吗?

是的

我想将我的 sendmail 服务器的 MX 记录添加到我的网站主机,以避免从我的 sendmail 服务器发送的邮件被标记为垃圾邮件(通过 IP 查找)。

不,您不想这样做。 相反,您可能应该考虑设置 SPF 记录

Google Apps 的 MX 记录和我的 sendmail 服务器会发生冲突吗?

如果您为两者设置相同名称 (domain.org) 的 MX 记录,那么是的,它们会发生冲突,邮件将发送到其中之一。 无论哪一个优先级最低并且在发送 MTA 尝试传送时可用,都可能会收到该邮件。

Can I also use a "sendmail" server to send additional emails from my webserver without there being a conflict with Google APPS?

Yes

I want to add MX records for my sendmail server to my webhost to avoid getting mail sent from my sendmail server marked as SPAM (via an IP lookup.)

No, you don't want to do that. Instead you probably should look at setting up an SPF record

Will the MX records for Google Apps and my sendmail server conflict in any way?

If you set MX records for the same name (domain.org) for both, then yes, they will conflict, mail will go to one or the other. Whichever has the lowest preference and is available at the time the sending MTA attempts to deliver will probably receive the message.

屋檐 2024-07-17 13:39:53

还没有完全按照你的要求去做,但是从什么时候开始人们就不再提供建议了呢? ;)

1) 只要您为“仅发送”服务器添加优先级非常低的 MX 记录(例如 50,所有 gmail 服务器都小于 20),除非邮件程序实施不当或 gmail 已关闭,任何邮件程序都不应尝试与您的低优先级服务器通信。 如果您只关心 MX 记录,端口也会阻止到这些服务器的入站 SMTP,以进一步确保邮件永远不会发送到错误的位置。 如果他们主动尝试连接回源 sendmail,这可能会导致某些垃圾邮件检测方案失效,但我认为这种情况并不常见。 您始终还可以运行本地重定向,因此如果邮件由于某种原因确实进入,您可以尽快将其推回 Gmail。

2)看不出有什么不可以的理由。 如果您从不允许将电子邮件发送到您的外发服务器并执行低优先级,则应该可以正常工作。

另外,请确保在 SPF 文本记录中包含所有可能发送邮件的服务器。 垃圾邮件过滤器应该至少像 MX 记录一样检查和信任这一点,因为并非所有公司都使用相同的入站服务器进行出站。

Haven't done exactly what you're asking, but since when does that stop folks from giving advice? ;)

1) So long as you add the MX records for your "send only" servers with really low priority (50 for example, where all the gmail servers are less than 20), unless there is a badly implemented mailer or gmail is down, no mailer should ever try and talk to your low priority servers. If all you care about is MX records, port block inbound SMTP to those servers as well to further ensure the mail never goes to the wrong spot. That might throw off some spam detection schemes if they actively try and connect back to the source sendmail, but I don't think that is common. You always could run a local redirect also, so if mail does come in for some reason, you can then push it right back out to gmail as soon as possible.

2) Can't see any reason why not. If you never allow email to be delivered to your outgoing servers and do the low priority, should work just fine.

Also, make sure to include all the servers that might send mail in your SPF text record. A spam filter should be checking and trusting that at least as much as MX records, as not all companies use the same inbound server for outbound.

所有深爱都是秘密 2024-07-17 13:39:53

您可以使用以下文本在 DNS 中添加新的 TXT 记录:

v=spf1 include:_spf.google.com include:_spf.myhoster.com ~all

然后您可以使用任何 DNS 检查器(在线服务)测试结果。
例如:

https://mxtoolbox.com/SuperTool.aspx?action=spf%3aexample.com&run=toolpage

然后转到主机上的服务器控制台并执行下一个命令:

mail -s "Test mail form console" [email protected] < /some_file.txt
sendmail [email protected] < /some_file.txt
php -r "mail('[email protected]', 'Test PHP mail()', 'Test message');"
php -r "mail('[email protected]', 'Test PHP mail()', 'Test message', 'From: [email protected]');"

如果您收到来自“[email protected]" 然后修改 PHP.ini 中的下一个参数:

mail.force_extra_parameters = [email protected]

You can add new TXT record in DNS with the next text:

v=spf1 include:_spf.google.com include:_spf.myhoster.com ~all

Then you can test the result with any DNS checker (online service).
For example:

https://mxtoolbox.com/SuperTool.aspx?action=spf%3aexample.com&run=toolpage

Then go to server console on your hosting and execute the next command:

mail -s "Test mail form console" [email protected] < /some_file.txt
sendmail [email protected] < /some_file.txt
php -r "mail('[email protected]', 'Test PHP mail()', 'Test message');"
php -r "mail('[email protected]', 'Test PHP mail()', 'Test message', 'From: [email protected]');"

If you got message from "[email protected]" then modify the next parameter in PHP.ini:

mail.force_extra_parameters = [email protected]
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文