1.
apt install postfix
apt install dovecot-pop3d
systemctl restart dovecot
vim /etc/dovecot/dovecot.conf
vim /etc/dovecot/conf.d/10-mail.conf
vim /etc/dovecot/conf.d/10-ssl.conf
vim /etc/dovecot/conf.d/10-auth.conf
创建电子邮件系统的登录用户
useradd -m test1
passwd test1
useradd -m test2
passwd test2
-m:自动建立用户的登入目录。
useradd -d<登入目录> 指定用户登入时的起始目录
启动postfix服务,并设置开机自启动
systemctl restart postfix
systemctl enable postfix
配置dovecot服务
vim /etc/dovecot/dovecot.conf
vim /etc/dovecot/conf.d/10-auth.conf
systemctl restart dovecot
systemctl enable dovecot
(1)如果有其他的邮件服务器软件正在运行,应先停掉服务或卸载掉该邮件服务器,否则会影响Postfix的使用。
(2)添加POP和SMTP服务器时,也可以添加邮件服务器对应的IP地址。