資源描述:
《51cto下載-rhel+5[1].0+postfix+dovecot+openwebmail+郵件服務(wù)器》由會員上傳分享,免費(fèi)在線閱讀,更多相關(guān)內(nèi)容在行業(yè)資料-天天文庫。
1、RHEL5.0postfixdovecotopenwebmail郵件服務(wù)器一、先卸載sendmain[root@ser~]#yumremovesendmail二、安裝postfix,dovecot,cyrus-sasl[root@ser~]#yum-yinstallpostfix[root@ser~]#yum-yinstalldovecot[root@ser~]#yum-yinstallcyrus-sasl四、修改postfix的配置文件[root@ser~]#vim/etc/postfix/main.cfmyhostname=mail.yjw.commydomain=yjw.c
2、ommyorigin=yjw.cominet_interfaces=allmynetworks=192.168.1.0/24relay_domains=yjw.com,$mydomainmydestination=$myhostname,localhost.$mydomain,localhost,$mydomain,mail.$mydomain,www.$mydomain,ftp.$mydomain重啟 postfix服務(wù)[root@ser~]#servicepostfixrestartShuttingdownpostfix:[OK]Startingpostfix:[OK][ro
3、ot@ser~]#chkconfigpostfixon[root@ser~]#chkconfigdovecoton修改dovecot的配置文件vim/etc/dovecot.confprotocols=imapimapspop3pop3slisten=*在iptables 里開放25,110,143端口[root@ser~]#vim/etc/sysconfig/iptables-ARH-Firewall-1-INPUT-mstate--stateNEW-mtcp-ptcp--dport110-jACCEPT-ARH-Firewall-1-INPUT-mstate--stateNE
4、W-mtcp-ptcp--dport25-jACCEPT-ARH-Firewall-1-INPUT-mstate--stateNEW-mtcp-ptcp--dport143-jACCEPT重啟iptables[root@ser~]#serviceiptablesrestartFlushingfirewallrules:[OK]SettingchainstopolicyACCEPT:filter[OK]Unloadingiptablesmodules:[OKApplyingiptablesfirewallrules:[OK]Loadingadditionaliptablesmodu
5、les:ip_conntrack_netbios_n[OK]ntrack_ftp[root@ser~]#yum-yinstallcyrus-sasl[root@ser~]#chkconfigsaslauthdon修改/etc/sysconfig/saslauthd[root@ser~]#vim/etc/sysconfig/saslauthd#Directoryinwhichtoplacesaslauthd'slisteningsocket,pidfile,andso#on.Thisdirectorymustalreadyexist.SOCKETDIR=/var/run/sasla
6、uthd#Mechanismtousewhencheckingpasswords.Run"saslauthd-v"togetalist#ofwhichmechanismyourinstallationwascompiledwiththeablitytouse.MECH=shadow#Additionalflagstopasstosaslauthdonthecommandline.Seesaslauthd(8)#forthelistofacceptedflags.FLAGS=修改/usr/lib/sasl2/smtpd.conf[root@ser~]#vim/usr/lib/sas
7、l2/smtpd.confpwcheck_method:saslauthd測試saslauthd[root@ser~]#servicesaslauthdrestart[root@ser~]#testsaslautd-uyjw-p'020304'0:OK"Success."在postfix的配置文件中,添加以下內(nèi)容,使其支持SMTP認(rèn)證[root@ser~]#vim/etc/postfix/main.cfmessage_size_limit=1073741824#郵件的大小為10M