我有在 CentOS 6.3 上运行的 postfix v2.6.6,主机名 priest.ocsl.local(私有,内部域)和一些别名
supportpeople: [email protected], [email protected], [email protected]
requests: "|/opt/rt4/bin/rt-mailgate --queue 'general' --action correspond --url http://localhost/", supportpeople
help: "|/opt/rt4/bin/rt-mailgate --queue 'help' --action correspond --url http://localhost/", supportpeople
如果我将 postfix 保留为其默认配置,那么别名将被正确解析/如我所料,这样传入的邮件,比如 [email protected] 将通过 rt-mailgate mailgate 命令通过管道传输并被传递(通过 ocsl.co.uk(一个可公开解析的域)的邮件服务器发送到 [email protected]、user2 等。
当我定义mydomain = ocsl.co.uk
in时出现问题/etc/postfix/main.cf
(意图是外发邮件来自,例如,[email protected])。当我这样做时,postfix 继续正确运行管道命令,但它不再像我预期的那样扩展嵌套别名:它不会尝试发送到 [email protected]、user2 等,而是尝试发送到 supportpeople@ ocsl.co.uk,它在上游邮件服务器上不存在并生成 NDR。postconf -n
对于非工作配置如下(工作配置仅“mydomain”行不同。
alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases
command_directory = /usr/sbin
config_directory = /etc/postfix
daemon_directory = /usr/libexec/postfix
data_directory = /var/lib/postfix
debug_peer_level = 2
html_directory = no
inet_interfaces = all
inet_protocols = all
mail_owner = postfix
mailq_path = /usr/bin/mailq.postfix
manpage_directory = /usr/share/man
mydestination = $myhostname, localhost.$mydomain, localhost
mydomain = ocsl.co.uk
newaliases_path = /usr/bin/newaliases.postfix
queue_directory = /var/spool/postfix
readme_directory = /usr/share/doc/postfix-2.6.6/README_FILES
sample_directory = /usr/share/doc/postfix-2.6.6/samples
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
unknown_local_recipient_reject_code = 550
在运行 Sendmail 的旧系统上,我们确实让事情按照我们预期/想要的方式工作。