Email

向不存在的使用者發送郵件,它應該去哪裡?

  • October 26, 2012

當我從命令行發送郵件時,它應該在哪裡結束?(我想從外部退回所有無效郵件,因為垃圾郵件。)有沒有辦法在它甚至要求主題之前給出錯誤說使用者不存在?

[root@308321 postfix]# mail notthere
Subject: should bounce
hello?
EOT

這是郵件日誌

Oct 26 05:29:23 308321 postfix/pickup[6510]: 72F51D4775: uid=0 from=<root>
Oct 26 05:29:23 308321 postfix/cleanup[6805]: 72F51D4775: message-id=<20121026052923.72F51D4775@mail.domain.com>
Oct 26 05:29:23 308321 postfix/qmgr[6511]: 72F51D4775: from=<root@domain.com>, size=432, nrcpt=1 (queue active)
Oct 26 05:29:23 308321 postfix/virtual[6808]: 72F51D4775: to=<notthere@domain.com>, orig_to=<notthere>, relay=virtual, delay=0.74, delays=0.48/0.01/0/0.25, dsn=5.1.1, status=bounced (unknown user: "notthere@domain.com")
Oct 26 05:29:23 308321 postfix/cleanup[6805]: F277DD4776: message-id=<20121026052923.F277DD4776@mail.domain.com>
Oct 26 05:29:24 308321 postfix/qmgr[6511]: F277DD4776: from=<>, size=2225, nrcpt=1 (queue active)
Oct 26 05:29:24 308321 postfix/bounce[6809]: 72F51D4775: sender non-delivery notification: F277DD4776
Oct 26 05:29:24 308321 postfix/qmgr[6511]: 72F51D4775: removed
Oct 26 05:29:24 308321 postfix/virtual[6808]: F277DD4776: to=<root@domain.com>, relay=virtual, delay=0.56, delays=0.22/0/0/0.35, dsn=5.1.1, status=bounced (unknown user: "root@domain.com")
Oct 26 05:29:24 308321 postfix/qmgr[6511]: F277DD4776: removed

一旦檢查收件人,郵件就會被拒絕。如果您真的想確切地看到伺服器拒絕它的時間,請嘗試使用

telnet server 25

而不是郵件程序。

http://james.apache.org/server/rfclist/smtp/rfc0821.txt 在這裡您可以了解如何操作。

在這裡 ( http://wiki.centos.org/HowTos/postfix_restrictions ) 你可以找到 postfix 在什麼時候檢查你設置的不同限制。

引用自:https://serverfault.com/questions/442570