試驗環境為:redhat6.2、sendmail.8.11.4、qpopper4.0.3。
三、軟件下載
分別從以下地址下載sendmail和qpopper:
sendmail.8.11.4.tar.gz http://www.sendmail.org/current-release.html
qpopper4.0.3.tar.gz http://www.eudora.com/qpopper_general/
四、Sendmail的配置和安裝
Sendmail是目前使用最為廣泛的一種E-Mail服務器。當前其最新的穩定版本為8.11.4。下載得到tar.gz格式的壓縮包以后,將其存放在/usr/src目錄下。
解壓軟件包:
[root@email src]# tar xvfz sendmail.8.11.4.tar.gz
[root@email src]# cd sendmail-8.11.4
編譯安裝:
[root@email sendmail-8.11.4]# cd sendmail
[root@email sendmail]# sh Build
生成配置文件:
[root@email sendmail]#cd /usr/src/sendmail-8.11.4/cf/cf/
一般該目錄下應該有config.mc的文件,如果沒有則創建新文件config.mc,內容為:
divert(-1)
dnl This is the macro config file used to generate the /etc/sendmail.cf
dnl file. If you modify thei file you will have to regenerate the
dnl /etc/sendmail.cf by running this macro config through the m4
dnl preprocessor:
dnl m4 /etc/sendmail.mc > /etc/sendmail.cf
dnl You will need to have the Sendmail-cf package installed for this to work.
include(`/usr/src/sendmail-8.11.4/cf')
define(`confDEF_USER_ID',`8:12')
OSTYPE(`linux')
undefine(`UUCP_RELAY')
undefine(`BITNET_RELAY')
define(`confAUTO_REBUILD')
define(`confTO_CONNECT', `1m')
define(`confTRY_NULL_MX_LIST',true)
define(`confDONT_PROBE_INTERFACES',true)
define(`PROCMAIL_MAILER_PATH',`/usr/bin/procmail')
FEATURE(`smrsh',`/usr/sbin/smrsh')
FEATURE(`mailertable',`hash -o /etc/mail/mailertable')
FEATURE(`virtusertable',`hash -o /etc/mail/virtusertable')
FEATURE(redirect)
FEATURE(always_add_domain)
FEATURE(use_cw_file)
FEATURE(local_procmail)
MAILER(smtp)
MAILER(procmail)
FEATURE(`access_db')
FEATURE(`blacklist_recipients')
dnl We strongly recommend to comment this one out if you want to protect
dnl yourself from spam. However, the laptop and users on computers that do
dnl not hav 24x7 DNS do need this.
FEATURE(`accept_unresolvable_domains')
dnl FEATURE(`relay_based_on_MX')
新聞熱點
疑難解答