服务器搭建手册之FREEBSDUNIX邮件服务器建设(五)

2、安装postfix

#cd /usr/ports/mail/postfix

#make install clean

正确选择:

 

回答下面的两问题:

You need user “postfix” added to group “mail”.[是否将postfix用户加到mail用户组]

 

Would you like me to add it [y]? y

 

Would you like to activate Postfix in /etc/mail/mailer.conf [n]? n

 

3、在/etc/rc.conf中加入postfix启动所需的启动选项

 

在/etc/rc.conf中加入:

sendmail_enable=”YES”

 

sendmail_flags=”-bd”

 

sendmail_pidfile=”/var/spool/postfix/pid/master.pid”

 

sendmail_procname=”/usr/local/libexec/postfix/master”

 

sendmail_outbound_enable=”NO”

 

sendmail_submit_enable=”NO”

 

sendmail_msp_queue_enable=”NO”

 

4、设置postfix启动所需

# cd /usr/local/etc/rc.d

# ln -s /usr/local/sbin/postfix postfix.sh

(注:这一步可以做,也可以不做,postfix都可以启动)

# ln -s /usr/local/sbin/sendmail /usr/sbin/sendmail

(注:如果/usr/sbin/sendmail存在就删再做上链接,如果升级内核和升级系统后要重新做这一步)

# echo ‘postfix: root’ >> /etc/aliases
# /usr/local/bin/newaliases
# chown postfix:postfix /etc/opiekeys

E、安装expect

用于Web客户端建立邮件用户。

# cd /usr/ports/lang/expect

# make install clean

     

如果这文章对你有帮助,请扫左上角微信支付-支付宝,给于打赏,以助博客运营

发表评论

您的电子邮箱地址不会被公开。 必填项已用*标注