求救postfix+dovecot的 問題
用postfix+dovecot架設的郵件伺服器,用的是虛擬域名和虛擬用戶,現在的情況是可以接受所有的郵件,但是只能發送本域的郵件,發往外部域的郵件(OE做客戶端)出現日誌:May 29 07:03:55 ns2 postfix/smtpd: connect from unknown
May 29 07:03:55 ns2 postfix/smtpd: NOQUEUE: reject: RCPT from unknown: 554 5.7.1 <candy59839@yahoo.com.tw>: Relay access denied; from=<michael78694@MyMainServer.com> to=<candy59839@yahoo.com.tw> proto=SMTP helo=<www.MyMainServer.com>
May 29 07:03:55 ns2 postfix/smtpd: lost connection after RCPT from unknown
,配置文件內容分別為:
mail.cf
# postconf -n
broken_sasl_auth_clients = yes
command_directory = /usr/sbin
config_directory = /etc/postfix
daemon_directory = /usr/libexec/postfix
html_directory = no
inet_interfaces = all
mail_owner = postfix
mailbox_size_limit = 209715200
mailq_path = /usr/bin/mailq
message_size_limit = 52428800
mydestination = localhost $myhostname localhost.$mydomain mail.$mydomain
myhostname = ns2.b-ape.com
mynetworks = 127.0.0.0/8 60.191.33.0/29
myorigin = mail.$mydomain
queue_directory = /var/spool/postfix
readme_directory = /usr/share/doc/postfix-2.3.3/README_FILE:S
sample_directory = /etc/postfix
sendmail_path = /usr/sbin/sendmail
setgid_group = postdrop
smtp_helo_name = ns2.b-ape.com
smtpd_banner = $myhostname ESMTP "Version not Available"
smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain =
smtpd_sasl_path = /var/spool/postfix/private/auth
smtpd_sasl_security_options = noanonymous
smtpd_sasl_type = dovecot
virtual_alias_maps = hash:/etc/postfix/virtual
virtual_gid_maps = static:89
virtual_mailbox_base = /var/spool/vmail/
virtual_mailbox_domains = hash:/etc/postfix/vdomain
virtual_mailbox_limit = 209715200
virtual_mailbox_maps = hash:/etc/postfix/vbox
virtual_minimum_uid = 88
virtual_transport = virtual
virtual_uid_maps = static:89
dovecot.conf
base_dir = /var/run/dovecot/
protocols = imap pop3
listen = *
log_path = /var/log/dovecot.log
info_log_path = /var/log/dovecot.log
log_timestamp = "%b %d %H:%M:%S "
login_dir = /var/run/dovecot/login
login_user = dovecot
mail_location = maildir:/var/spool/vmail/%Ld/%Ln
mail_extra_groups = postfix
first_valid_uid = 88
mbox_read_locks = fcntl
protocol imap {
}
protocol pop3 {
pop3_uidl_format = %08Xu%08Xv
pop3_client_workarounds = outlook-no-nuls oe-ns-eoh
}
protocol lda {
mail_plugin_dir = /usr/lib/dovecot/lda
sendmail_path = /usr/lib/sendmail
auth_socket_path = /var/run/dovecot/auth-master
}
auth_verbose = yes
auth default {
mechanisms = plain
passdb pam {
}
passdb passwd-file {
args = /etc/postfix/passwd
}
userdb passwd {
}
userdb passwd-file {
args = /etc/postfix/passwd
}
user = root
socket listen {
client {
path = /var/spool/postfix/private/auth
mode = 0660
user = postfix
group = postfix
}
}
}
dict {
}
plugin {
}
#
請高手指教,非常感謝!!
[ 本帖最後由 wangdejiu 於 2008-5-29 09:23 編輯 ]
《解決方案》
回復 #1 wangdejiu 的帖子
自己先頂一個!!!!
《解決方案》
因為「你」不是postfix的「信任用戶」 所以postfix不會幫你relay這個郵件
可以通過設置mynetworks參數 或者 實現smtp auth來使得
「你」成為postfix的「信任用戶」
《解決方案》
回復 #3 sosogh 的帖子
都試了,但是還是不能成為"信任的用戶"請你幫我看看我的配置文件還存在那些問題?非常感謝
《解決方案》
都試了?
connect from unknown
mynetworks = 127.0.0.0/8 60.191.33.0/29
從以下記錄看來 你的outlook沒有提供驗證哦
May 29 07:03:55 ns2 postfix/smtpd: connect from unknown
May 29 07:03:55 ns2 postfix/smtpd: NOQUEUE: reject: RCPT from unknown: 554 5.7.1 <candy59839@yahoo.com.tw>: Relay access denied; from=<michael78694@MyMainServer.com> to=<candy59839@yahoo.com.tw> proto=SMTP helo=<www.MyMainServer.com>
May 29 07:03:55 ns2 postfix/smtpd: lost connection after RCPT from unknown
《解決方案》
回復 #5 sosogh 的帖子
outlook提供認證的,在其他郵件系統上能正常使用,繼續請教這個問題,我已經為這個問題耗費了5天
《解決方案》
OUTLOOK賬號設置里的'我的發送伺服器(smtp)要求驗證'沒打上勾?
有認證在伺服器上會有認證日誌的。
《解決方案》
回復 #7 xmbbx 的帖子
我的發送伺服器(smtp)要求驗證'沒打上勾?已經打上了,不是客戶端的問題,應該是伺服器配置的問題,我在網上論壇上找的有我同樣問題的 人發問,但是最後都是沒有結果,沒有人最後回答出正確的答案就結束掉,也不知道最後怎麼解決,所以我希望這次能得到一個答案,有經驗的請指點一下
《解決方案》
原帖由 wangdejiu 於 2008-5-29 13:10 發表 http://bbs.chinaunix.net/images/common/back.gif
outlook提供認證的,在其他郵件系統上能正常使用,繼續請教這個問題,我已經為這個問題耗費了5天
那你手動使用telnet 測試下 smtp auth