我的主要目标是通过 ZoneMinder 给我发送电子邮件。我设置了一个 FQDN,查看了许多不同的设置说明,包括这, 和这以及由于我的名声而无法列出的其他教程。包括我的邮件日志和设置。
我正在努力弄清楚我做错了什么,或者这是否与我的 ISP 有关。
我希望我已经提供了足够的信息。我还有一个 noip 帐户,可以在 LAN 之外进行访问。
Telnet 本地主机 25
尝试 ::1... 已连接到本地主机。转义字符为 '^]'。220 mydomain.com ESMTP Postfix(Ubuntu)
Telnet www.mydomain.com 25
尝试 69.254.72.165... 连接到 mydomain.com。转义字符为 '^]'。220 mydomain.com ESMTP Postfix(Ubuntu)
日志
> Jun 19 21:26:06 herbie postfix/pickup[3146]: 6A21F9C1229: uid=1000 from=<kirt>
Jun 19 21:26:06 herbie postfix/cleanup[3178]: 6A21F9C1229: message-id=<[email protected]>
Jun 19 21:26:06 herbie postfix/qmgr[2794]: 6A21F9C1229: from=<[email protected]>, size=349, nrcpt=1 (queue active)
Jun 19 21:26:06 herbie postfix/local[3184]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Jun 19 21:26:06 herbie postfix/local[3184]: 6A21F9C1229: to=<[email protected]>, orig_to=<kirt>, relay=local, delay=0.14, delays=0.07/0.02/0/0.05, dsn=2.0.0, st$
Jun 19 21:26:06 herbie postfix/qmgr[2794]: 6A21F9C1229: removed
Jun 19 21:26:11 herbie postfix/qmgr[2794]: 4BF039C0B83: from=<[email protected]>, size=350, nrcpt=2 (queue active)
Jun 19 21:26:22 herbie postfix/smtp[3172]: connect to mx4.hotmail.com[65.55.92.152]:25: Connection timed out
postfix 错误F。
smtpd_tls_cert_file = /etc/ssl/certs/smtpd.crt
smtpd_tls_key_file = /etc/ssl/private/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
smtpd_relay_restrictions = permit_mynetworks permit_sasl_authenticated defer_unauth_destination
myhostname = mydomain.com
virtual_alias_maps = hash:/etc/postfix/virtual
alias_database = hash:/etc/aliases
myorigin = /etc/mailname
mydestination = mydomain.com, herbie, localhost.localdomain, localhost
mydomain = mydomain.com
relayhost =
mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128
mailbox_command =
mailbox_size_limit = 0
recipient_delimiter = +
inet_interfaces = all
inet_protocols = all
html_directory = /usr/share/doc/postfix/html
home_mailbox = Maildir/
smtpd_sasl_local_domain =
smtpd_sasl_auth_enable = yes
smtpd_sasl_security_options = noanonymous
broken_sasl_auth_clients = yes
smtpd_recipient_restrictions = permit_sasl_authenticated,permit_mynetworks,reject_unauth_destination
smtp_tls_security_level = may
smtpd_tls_security_level = may
smtpd_tls_auth_only = no
smtp_tls_note_starttls_offer = yes
smtpd_tls_CAfile = /etc/ssl/certs/cacert.pem
答案1
使用 ubuntu 自带的这个包,设置 postfix 会变得更加容易。
sudo apt-get install mail-stack-delivery
应该会为您设置好一切 - postfix 和 dovecot。只需在 Linux 上创建另一个用户即可
adduser myname
它会自动为您设置一封电子邮件。
当然你必须设置 mx 记录来指向你的域名