阿里云-云小站(无限量代金券发放中)
【腾讯云】云服务器、云数据库、COS、CDN、短信等热卖云产品特惠抢购

SUSE 11 sp1 安装Postfix后配置

214次阅读
没有评论

共计 6343 个字符,预计需要花费 16 分钟才能阅读完成。

SUSE 11 sp1 安装好 Postfix 后,可以参考如下配置文件(去掉注释内容):

CentOS 6.4 下 Postfix 邮件服务安装和基本配置 http://www.linuxidc.com/Linux/2013-08/88977.htm

CentOS 5.5 下邮件服务器 Postfix 安装 http://www.linuxidc.com/Linux/2012-05/60010.htm

搭建 Red Hat Enterprise Linux 5.4 的 Postfix 邮件服务器 http://www.linuxidc.com/Linux/2012-12/77167.htm

Linux 下架构安全邮件服务器之 Postfix(认证)http://www.linuxidc.com/Linux/2012-09/70527.htm

sz-oms-email:#zypper install postfix
sz-oms-email:/etc/postfix #cat main.cf | grep -v “^#” | grep -v “^$”
queue_directory = /var/spool/postfix
command_directory = /usr/sbin
daemon_directory = /usr/lib/postfix
data_directory = /var/lib/postfix
mail_owner = postfix
myhostname = sz-oms-email #hostname
inet_interfaces = all
mydestination = $myhostname, localhost.$mydomain, localhost
unknown_local_recipient_reject_code = 550
mynetworks = 10.11.0.0/16, 127.0.0.0/8, 192.168.193.0/24,172.24.0.0/16
relay_domains = $mydestination,qq.com,hotmail.com,huawei.com,partner.huawei.com,163.com,126.com,yahoo.com.cn,gmail.com

debug_peer_level = 2
debugger_command =
PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin
ddd $daemon_directory/$process_name $process_id & sleep 5
sendmail_path = /usr/sbin/sendmail
newaliases_path = /usr/bin/newaliases
mailq_path = /usr/bin/mailq
setgid_group = maildrop
html_directory = /usr/share/doc/packages/postfix-doc/html
manpage_directory = /usr/share/man
sample_directory = /usr/share/doc/packages/postfix-doc/samples
readme_directory = /usr/share/doc/packages/postfix-doc/README_FILES
inet_protocols = all
biff = no
sz-oms-email:/etc/postfix #cat master.cf | grep -v “^#” | grep -v “^$”
smtp inet n – n – – smtpd
pickup fifo n – n 60 1 pickup
cleanup unix n – n – 0 cleanup
qmgr fifo n – n 300 1 qmgr
tlsmgr unix – – n 1000? 1 tlsmgr
rewrite unix – – n – – trivial-rewrite
bounce unix – – n – 0 bounce
defer unix – – n – 0 bounce
trace unix – – n – 0 bounce
verify unix – – n – 1 verify
flush unix n – n 1000? 0 flush
proxymap unix – – n – – proxymap
smtp unix – – n – – smtp
relay unix – – n – – smtp
-o fallback_relay=
showq unix n – n – – showq
error unix – – n – – error
discard unix – – n – – discard
local unix – n n – – local
virtual unix – n n – – virtual
lmtp unix – – n – – lmtp
anvil unix – – n – 1 anvil
scache unix – – n – 1 scache
maildrop unix – n n – – pipe
flags=DRhu user=vmail argv=/usr/local/bin/maildrop -d ${recipient}
cyrus unix – n n – – pipe
user=cyrus argv=/usr/lib/cyrus/bin/deliver -e -r ${sender} -m ${extension} ${user}
uucp unix – n n – – pipe
flags=Fqhu user=uucp argv=uux -r -n -z -a$sender – $nexthop!rmail ($recipient)
ifmail unix – n n – – pipe
flags=F user=ftn argv=/usr/lib/ifmail/ifmail -r $nexthop ($recipient)
bsmtp unix – n n – – pipe
flags=Fq. user=foo argv=/usr/local/sbin/bsmtp -f $sender $nexthop $recipient
procmail unix – n n – – pipe
flags=R user=nobody argv=/usr/bin/procmail -t -m /etc/procmailrc ${sender} ${recipient}
retry unix – – n – – error
proxywrite unix – – n – 1 proxymap

更多详情见请继续阅读下一页的精彩内容 :http://www.linuxidc.com/Linux/2014-06/102907p2.htm

Telnet telnet 192.168.193.138 25
如果正常,您将会看到以下来自 IMC 的响应:
220 matchdu.cn Esmtp

键入以下命令开始进行通讯:

EHLO root@bj-oms-email1.localdomain
EHLO root@sz-oms-email.localdomain
EHLO root@en-oms-email.localdomain
您应看到如下响应:
250 OK

键入以下命令来通知 IMC 邮件源于何处:
MAIL FROM: root@en-oms-email.localdomain
按 ENTER 您应得到如下响应:
250 OK

键入以下命令来通知 IMC 邮件的目标地址。
RCPT TO: a591244761@163.com
RCPT TO: lvyingxin@huawei.com
按 ENTER 您应看到如下响应:
250 OK

键入以下命令以通知 IMC 您已准备好发送数据:
DATA
按 ENTER 键您应看到如下响应:
354 Send data.

键入以下命令以添加主题行:
Subject: test message
然后按两次 Enter 键。
该命令看不到任何响应。
备注:两个 Enter 命令符合 RFC 822 规则,即 822 命令后必须跟空行。

键入以下命令来添加邮件正文:
This is a test message
i love you
.
您将看不到来自该命令的响应。
在紧接着的空行处键入句号,然后按 ENTER 键。
您应看到如下响应:
250 OK

注意有的 smtp 服务器是需要验证

pop3
telnet xxx.xxx.xxx.xxx 110
user **
+ok
pass **
+ok
list
+ok
1 264
2 549
acpt 1 (查询邮件)

RETR 1 (查询邮件)
quit

SMTP 命令包括:
我们通过 telnet 到邮件服务器 25 端口后, 就可以使用以下的命令来发送邮件了.
HELO 向服务器标识用户身份。发送者能进行欺骗,但一般情况下服务器都能检测到。
EHLO 向服务器标识用户身份。发送者能进行欺骗,但一般情况下服务器都能检测到。
MAIL FROM 命令中指定的地址是发件人地址
RCPT TO 标识单个的邮件接收人;可有多个 RCPT TO;常在 MAIL 命令后面。
DATA 在单个或多个 RCPT 命令后,表示所有的邮件接收人已标识,并初始化数据传输,以 CRLF.CRLF 结束
VRFY 用于验证指定的用户 / 邮箱是否存在;由于安全方面的原因,服务器常禁止此命令
EXPN 验证给定的邮箱列表是否存在,扩充邮箱列表,也常被禁用
HELP 查询服务器支持什么命令
NOOP 无操作,服务器响应 250 OK
RSET 重置会话,当前传输被取消,服务器响应 250 OK
QUIT 结束会话

Postfix 的详细介绍 :请点这里
Postfix 的下载地址 :请点这里

更多 SUSE 相关信息见 SUSE 专题页面 http://www.linuxidc.com/topicnews.aspx?tid=3

SUSE 11 sp1 安装好 Postfix 后,可以参考如下配置文件(去掉注释内容):

CentOS 6.4 下 Postfix 邮件服务安装和基本配置 http://www.linuxidc.com/Linux/2013-08/88977.htm

CentOS 5.5 下邮件服务器 Postfix 安装 http://www.linuxidc.com/Linux/2012-05/60010.htm

搭建 Red Hat Enterprise Linux 5.4 的 Postfix 邮件服务器 http://www.linuxidc.com/Linux/2012-12/77167.htm

Linux 下架构安全邮件服务器之 Postfix(认证)http://www.linuxidc.com/Linux/2012-09/70527.htm

sz-oms-email:#zypper install postfix
sz-oms-email:/etc/postfix #cat main.cf | grep -v “^#” | grep -v “^$”
queue_directory = /var/spool/postfix
command_directory = /usr/sbin
daemon_directory = /usr/lib/postfix
data_directory = /var/lib/postfix
mail_owner = postfix
myhostname = sz-oms-email #hostname
inet_interfaces = all
mydestination = $myhostname, localhost.$mydomain, localhost
unknown_local_recipient_reject_code = 550
mynetworks = 10.11.0.0/16, 127.0.0.0/8, 192.168.193.0/24,172.24.0.0/16
relay_domains = $mydestination,qq.com,hotmail.com,huawei.com,partner.huawei.com,163.com,126.com,yahoo.com.cn,gmail.com

debug_peer_level = 2
debugger_command =
PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin
ddd $daemon_directory/$process_name $process_id & sleep 5
sendmail_path = /usr/sbin/sendmail
newaliases_path = /usr/bin/newaliases
mailq_path = /usr/bin/mailq
setgid_group = maildrop
html_directory = /usr/share/doc/packages/postfix-doc/html
manpage_directory = /usr/share/man
sample_directory = /usr/share/doc/packages/postfix-doc/samples
readme_directory = /usr/share/doc/packages/postfix-doc/README_FILES
inet_protocols = all
biff = no
sz-oms-email:/etc/postfix #cat master.cf | grep -v “^#” | grep -v “^$”
smtp inet n – n – – smtpd
pickup fifo n – n 60 1 pickup
cleanup unix n – n – 0 cleanup
qmgr fifo n – n 300 1 qmgr
tlsmgr unix – – n 1000? 1 tlsmgr
rewrite unix – – n – – trivial-rewrite
bounce unix – – n – 0 bounce
defer unix – – n – 0 bounce
trace unix – – n – 0 bounce
verify unix – – n – 1 verify
flush unix n – n 1000? 0 flush
proxymap unix – – n – – proxymap
smtp unix – – n – – smtp
relay unix – – n – – smtp
-o fallback_relay=
showq unix n – n – – showq
error unix – – n – – error
discard unix – – n – – discard
local unix – n n – – local
virtual unix – n n – – virtual
lmtp unix – – n – – lmtp
anvil unix – – n – 1 anvil
scache unix – – n – 1 scache
maildrop unix – n n – – pipe
flags=DRhu user=vmail argv=/usr/local/bin/maildrop -d ${recipient}
cyrus unix – n n – – pipe
user=cyrus argv=/usr/lib/cyrus/bin/deliver -e -r ${sender} -m ${extension} ${user}
uucp unix – n n – – pipe
flags=Fqhu user=uucp argv=uux -r -n -z -a$sender – $nexthop!rmail ($recipient)
ifmail unix – n n – – pipe
flags=F user=ftn argv=/usr/lib/ifmail/ifmail -r $nexthop ($recipient)
bsmtp unix – n n – – pipe
flags=Fq. user=foo argv=/usr/local/sbin/bsmtp -f $sender $nexthop $recipient
procmail unix – n n – – pipe
flags=R user=nobody argv=/usr/bin/procmail -t -m /etc/procmailrc ${sender} ${recipient}
retry unix – – n – – error
proxywrite unix – – n – 1 proxymap

更多详情见请继续阅读下一页的精彩内容 :http://www.linuxidc.com/Linux/2014-06/102907p2.htm

正文完
星哥玩云-微信公众号
post-qrcode
 0
星锅
版权声明:本站原创文章,由 星锅 于2022-01-20发表,共计6343字。
转载说明:除特殊说明外本站文章皆由CC-4.0协议发布,转载请注明出处。
【腾讯云】推广者专属福利,新客户无门槛领取总价值高达2860元代金券,每种代金券限量500张,先到先得。
阿里云-最新活动爆款每日限量供应
评论(没有评论)
验证码
【腾讯云】云服务器、云数据库、COS、CDN、短信等云产品特惠热卖中