Released Postfix 3.1.0 With few fixs
Postfix是免费的,开源的,快速且流行的SMTP邮件传输代理(MTA),已广泛用作Sendmail的替代方法。 Postfix实现了高性能的并行邮件传递引擎。 Postfix通常与邮件列表软件(例如Mailman)结合使用。 Postfix可以在类似UNIX的系统上运行,包括AIX,BSD,HP-UX,Linux,MacOS X,Solaris等。 2016年2月24日发布的最新版本的Postfix 3.1.0修复了TLS错误,导致受影响的邮件累积在延迟队列中。
将主机名条目添加到/ etc / hosts文件中,以便在测试后缀时将发现主机名
组态。
1 2 | $ sudo nano /etc/hosts 192.168.0.100 mint.2daygeek.com |
1)安装Postfix span>
默认情况下,所有现代Linux发行版均在其自己的存储库中具有postfix二进制包,因此我们可以通过发出以下单个命令轻松地进行安装。 默认情况下,Sendmail安装了大多数发行版,因此在处理postfix安装之前将其删除。
1 2 3 4 5 | <span style="color:#848484">[Remove sendmail, if its not installed you can skip]</span> $ sudo purge sendmail <span style="color:#848484">[Install Postfix]</span> $ sudo apt-get install postfix |
阅读后缀配置信息,点击
选择Internet站点,然后单击
添加您的邮件主机名,然后单击
2)配置Postfix span>
编辑
1 2 | $ sudo nano /etc/postfix/main.cf home_mailbox = Maildir/ |
您可以通过运行以下命令来交叉检查并重新配置配置。
1 | $ sudo dpkg-reconfigure postfix |
3)重新启动Postfix span>
完成上述适当的更改后,只需触发以下命令即可重新启动postfix服务,以对新配置生效。
1 2 3 4 5 6 7 | <span style="color:#848484">[For SysVinit Systems]</span> $ sudo service postfix restart $ sudo chkconfig postfix on <span style="color:#848484">[For systemd Systems]</span> $ sudo systemctl restart postfix $ sudo systemctl enable postfix |
4)测试Postfix span>
现在,您可以测试您的postfix邮件服务是否正常运行,请使用以下技巧。
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | $ telnet localhost smtp Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. 220 mint.2daygeek.com ESMTP Postfix (Ubuntu) <span style="color: #00FF00;">ehlo localhost</span> 250-mint.2daygeek.com 250-PIPELINING 250-SIZE 10240000 250-VRFY 250-ETRN 250-STARTTLS 250-ENHANCEDSTATUSCODES 250-8BITMIME 250 DSN <span style="color: #00FF00;">quit</span> 221 2.0.0 Bye Connection closed by foreign host. |
5)使用用户测试Postfix span>
使用/ sbin / nologin shell创建用户以限制登录访问。
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | $ sudo useradd -m magi -s /sbin/nologin $ sudo passwd magi $ telnet localhost smtp Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. 220 mint.2daygeek.com ESMTP Postfix (Ubuntu) <span style="color: #00FF00;">ehlo localhost</span> 250-mint.2daygeek.com 250-PIPELINING 250-SIZE 10240000 250-VRFY 250-ETRN 250-STARTTLS 250-ENHANCEDSTATUSCODES 250-8BITMIME 250 DSN <span style="color: #00FF00;">mail from: <a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="214c404648614c484f550f134540584644444a0f424e4c">[emailprotected]</a></span> 250 2.1.0 Ok <span style="color: #00FF00;">rcpt to: <a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="ec818d8b85ac81858298c2de888d958b898987c28f8381">[emailprotected]</a></span> 250 2.1.5 Ok <span style="color: #00FF00;">data</span> 354 End data with <cr><lf>.<cr><lf> <span style="color: #00FF00;">Postfix mail server testing on LinuxMint 17.3 .</span> 250 2.0.0 Ok: queued as 1C86CC351F <span style="color: #00FF00;">quit</span> 221 2.0.0 Bye Connection closed by foreign host. </lf></cr></lf></cr> |
参见下面的输出。
1 2 3 4 5 6 7 8 9 10 11 12 | # cat /home/magi/Maildir/new/1456376003.V801I1422d3M520795.mint.2daygeek.com Return-Path: <[email protected].com> X-Original-To: <a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="aac7cbcdc3eac7c3c4de8498cecbd3cdcfcfc184c9c5c7">[emailprotected]</a> Delivered-To: <a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="a0cdc1c7c9e0cdc9ced48e92c4c1d9c7c5c5cb8ec3cfcd">[emailprotected]</a> Received: from localhost (localhost [127.0.0.1]) by mint.2daygeek.com (Postfix) with ESMTP id 1C86CC351F for <[email protected].com>; Thu, 25 Feb 2016 10:22:46 +0530 (IST) Message-Id: <<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="c2f0f2f3f4f2f0f0f7f2f6f7f0f7fbecf381faf48181f1f7f38482afabacb6ecf0a6a3bba5a7a7a9eca1adaf">[emailprotected]</a>> Date: Thu, 25 Feb 2016 10:22:46 +0530 (IST) From: <a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="5835393f31183531362c766a3c39213f3d3d33763b3735">[emailprotected]</a> Postfix mail server testing on LinuxMint 17.3</[email protected].com></[email protected].com> |
请享用…)