前端之家收集整理的这篇文章主要介绍了
ubuntu Postfix安装使用,
前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
postfix安装
- sudo apt-get install postfix
- sudo apt-get install mailutils
- sudo useradd -m -s /bin/bash incoming
- sudo passwd incoming
启动postfix
- sudo postfix status
- sudo postfix start
测试
- telnet localhost 25
- ehlo localhost
- mail from: root@localhost
- rcpt to: incoming@localhost
- data
- Subject: Re: Some issue
-
- Sounds good!
- .
- quit
配置postfix使用Maildir-style mailBoxes
- sudo postconf -e "home_mailBox = Maildir/"
- sudo service postfix restart
- su - incoming
- mkdir /home/incoming/Maildir
- MAIL=/home/incoming/Maildir
- mail
postfix常用命令
- # 会列出当前在postfix发送队列中的所有邮件
- mailq
-
- # 删除当前等待发送队列的所有邮件,包括发送失败的退信
- postsuper -d ALL