Virtualbox 메일 서버 postfix+dovecot

Virtualbox 메일 서버 postfix+dovecot

개발/테스트 목적으로(virtualBox 브리지 모드 사용) 메일 서버(ubuntu14.4 serverX64)를 설정 중이며 방금 완료했습니다.지도 시간 모든 것이 잘 진행되었습니다.
이제 다음 중 하나를 사용하여 이메일 서비스에 로그인/사용할 수 없습니다.

  • 썬더버드 클라이언트
  • 다람쥐 메일

Thunderbird는 다음을 표시합니다: 서버 로그인 실패, Squirrel은 "알 수 없는 사용자 또는 잘못된 비밀번호"를 표시합니다. , 내가 무엇을 놓치고 있나요?

이것은 내 접미사 main.cf입니다.

#See /usr/share/postfix/main.cf.dist for a commented, more complete version


# Debian specific:  Specifying a file name will cause the first
# line of that file to be used as the name.  The Debian default
# is /etc/mailname.
#myorigin = /etc/mailname

smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)
biff = no

# appending .domain is the MUA's job.
append_dot_mydomain = no

# Uncomment the next line to generate "delayed mail" warnings
#delay_warning_time = 4h

readme_directory = /usr/share/doc/postfix

# TLS parameters
smtpd_tls_cert_file = /etc/postfix/smtpd.cert
smtpd_tls_key_file = /etc/postfix/smtpd.key
smtpd_use_tls = yes
smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache

# See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for
# information on enabling SSL in the smtp client.

smtpd_relay_restrictions = permit_mynetworks permit_sasl_authenticated defer_unauth_destination
myhostname = mail.ely.net
#myhostname = 192.168.1.100
alias_maps = hash:/etc/aliases, hash:/var/lib/mailman/data/aliases
alias_database = hash:/etc/aliases, hash:/var/lib/mailman/data/aliases
myorigin = /etc/mailname
mydestination = mail.ely.net, localhost, localhost.localdomain
#mydestination = 192.168.1.100, localhost, localhost.localdomain
relayhost = 
mynetworks = 127.0.0.0/8 [::1]/128
mailbox_size_limit = 0
recipient_delimiter = +
inet_interfaces = all
html_directory = /usr/share/doc/postfix/html
virtual_alias_domains = 
virtual_alias_maps = hash:/var/lib/mailman/data/virtual-mailman, proxy:mysql:/etc/postfix/mysql-virtual_forwardings.cf, proxy:mysql:/etc/postfix/mysql-virtual_email2email.cf
virtual_mailbox_domains = proxy:mysql:/etc/postfix/mysql-virtual_domains.cf
virtual_mailbox_maps = proxy:mysql:/etc/postfix/mysql-virtual_mailboxes.cf
virtual_mailbox_base = /var/vmail
virtual_uid_maps = static:5000
virtual_gid_maps = static:5000
inet_protocols = all
smtpd_sasl_auth_enable = yes
broken_sasl_auth_clients = yes
smtpd_sasl_authenticated_header = yes
smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination, check_recipient_access mysql:/etc/postfix/mysql-virtual_recipient.cf
smtpd_tls_security_level = may
transport_maps = hash:/var/lib/mailman/data/transport-mailman, proxy:mysql:/etc/postfix/mysql-virtual_transports.cf
relay_domains = mysql:/etc/postfix/mysql-virtual_relaydomains.cf
relay_recipient_maps = mysql:/etc/postfix/mysql-virtual_relayrecipientmaps.cf
proxy_read_maps = $local_recipient_maps $mydestination $virtual_alias_maps $virtual_alias_domains $virtual_mailbox_maps $virtual_mailbox_domains $relay_recipient_maps $relay_domains $canonical_maps $sender_canonical_maps $recipient_canonical_maps $relocated_maps $transport_maps $mynetworks
smtpd_sender_restrictions = check_sender_access mysql:/etc/postfix/mysql-virtual_sender.cf
smtpd_client_restrictions = check_client_access mysql:/etc/postfix/mysql-virtual_client.cf
smtpd_client_message_rate_limit = 100
maildrop_destination_concurrency_limit = 1
maildrop_destination_recipient_limit = 1
virtual_transport = dovecot
header_checks = regexp:/etc/postfix/header_checks
mime_header_checks = regexp:/etc/postfix/mime_header_checks
nested_header_checks = regexp:/etc/postfix/nested_header_checks
body_checks = regexp:/etc/postfix/body_checks
owner_request_special = no
smtp_tls_security_level = may
dovecot_destination_recipient_limit = 1
smtpd_sasl_type = dovecot
smtpd_sasl_path = private/auth
content_filter = amavis:[127.0.0.1]:10024
receive_override_options = no_address_mappings
message_size_limit = 0

서버(virtualbox-ubuntuServer14.04X64)에서 nslookup을 수행하면 다음을 얻습니다.

root@mail:/etc/nginx# nslookup mail.ely.net
Server:     8.8.8.8
Address:    8.8.8.8#53

Non-authoritative answer:
mail.ely.net    canonical name = mail.netidentity.com.cust.hostedemail.com.
Name:   mail.netidentity.com.cust.hostedemail.com
Address: 216.40.42.5

호스트에서(우분투 데스크탑 14.04x64)

main@main:~$ nslookup mail.ely.net
Server:     127.0.1.1
Address:    127.0.1.1#53

Non-authoritative answer:
mail.ely.net    canonical name = mail.netidentity.com.cust.hostedemail.com.
Name:   mail.netidentity.com.cust.hostedemail.com
Address: 216.40.42.5

이것은 가상 머신이고 LAN 외부의 가상 머신을 보고 있기 때문에 완전히 정확합니다.

이제 ispconfig 메일 대기열 로그에 다음과 같은 흥미로운 내용이 있습니다.

Queue ID- --Size-- ----Arrival Time---- -Sender/Recipient-------
C73EE221A5A 2545 Wed Aug 6 01:31:51 [email protected]
(lost connection with mx.netidentity.com.cust.hostedemail.com[216.40.42.4] while receiving the initial server greeting)
[email protected]

따라서 여기서 문제는 IP에 관한 것입니다. IP가 내 가상 서버가 아닌 실제 mail.ely.net 호스트인 것처럼 보이기 때문입니다. 따라서 다음과 같은 질문이 발생합니다.

  1. 외부 세계(예: gmail/yahoo)에서 이메일을 보내고 받고 개인 메일 서버처럼 작동하도록 할 수 있습니까?
  2. 외부 세계와 잘 어울릴 수 있도록 conf를 어떻게 변경합니까?
  3. 위 튜토리얼을 완료한 후 사용자를 찾을 수 없음/로그인 문제가 발생하는 이유 또는 해결 방법이 있습니다.

관련 정보