Mail system for RHEL4.0 Total solution安裝筆記
--written by Dandy
*****************************************************
前言,Redhat Enterprise Linux 4.0(RHEL4.0)使用Kernel 2.6.9-5,代號為Nahant,相對應的Fedora版本應該是FC3,這次改版最主要有幾個地方:
虛擬記憶體系統處理讀寫方式的改變(memory IO變快,更適合用來跑database了),支援HT(Hyper Thread)的CPU, LVM2的增強,更好的電源管理,
還有對USB設備的大量支援,在軟體方面,初初接觸,改了不少東西,像pop3跟imap整合到dovecot跟cyrus-imapd(兩個都可以跑pop3/imap)等.
安裝完的目錄如下:
執行檔- binaries in /usr/local/bin
掃毒引擎- the shared library in /usr/local/lib
病毒碼- the virus data in /usr/local/sav
說明文件- manual pages in /usr/local/man
date >> $LOGFILE
if [ -f $SPAM ]; then
BOX=${SPAM}.processing
mv $SPAM $BOX
sleep 5 # Wait for writing current message to complete
$SALEARN --prefs-file=$PREFS --spam --mbox $BOX >> $LOGFILE 2>&1
rm -f $BOX
fi
if [ -f $NOTSPAM ]; then
BOX=${NOTSPAM}.processing
mv $NOTSPAM $BOX
sleep 5 # Wait for writing current message to complete
$SALEARN --prefs-file=$PREFS --ham --mbox $BOX >> $LOGFILE 2>&1
rm -f $BOX
fi
######################################
把以上的內容存成spam-learn。
] # chmod 755 spam-learn
] # mv spam-learn /etc/cron.daily
] # /etc/init.d/crond restart
<p.s.>後記--檢查一下經過Mailscanner所處理過的信件檔頭,應該會出現以下的訊息,若未出現host-MailScanner-SpamCheck,非廣告郵件, SpamAssassin 程式...的話,請檢查Detailed Spam Report = yes,
其中若分數一直=0沒變的話,表示spamassassin的設定檔錯誤,請檢查此兩項要取消
#SpamAssassin Local Rules Dir = /etc/mail/spamassassin
#SpamAssassin Default Rules Dir = /etc/mail/spamassassin
此項路徑要對:
SpamAssassin User State Dir =/var/spool/MailScanner/spamassassin
=======MailScanner處理過的信件檔頭===============
X-host-MailScanner-Information: Please contact the ISP for more information
X-host-MailScanner: Found to be clean
X-host-MailScanner-SpamCheck: 非廣告郵件, SpamAssassin 程式 (分數=3.8,
被需要 6, AWL 0.00, FORGED_MUA_OUTLOOK 3.48, RCVD_IN_ORBS 0.50,
RCVD_IN_OSIRUSOFT_COM 0.55, X_OSIRU_OPEN_RELAY 2.90)
X-host-MailScanner-SpamScore: 3
X-MailScanner-From: sender@host
Status:
========================================
com2sec local localhost public
com2sec mynetwork 192.168.0.0/24 public
group MyRWGroup v1 local
group MyROGroup v1 mynetwork
group MyRWGroup v2c local
view systemview included .1.3.6.1.2.1.1
view systemview included .1.3.6.1.2.1.25.1.1
view all included .1 80
access MyROGroup "" any noauth prefix all none none
access MyRWGroup "" any noauth prefix all all all
syslocation Unknown (edit /etc/snmp/snmpd.conf)
syscontact Root (configure /etc/snmp/snmp.local.conf)
pass .1.3.6.1.4.1.4413.4.1 /usr/bin/ucd5820stat
若Apache的MRTG出來的網頁以UTF為主,切換麻煩的話, 請修改/etc/httpd/conf/httpd.conf
將AddDefaultCharset ISO-8859-1修改如下
AddDefaultCharst Big5
語言順序
LanguagePriority en da nl et fr de el it ja kr no pl pt pt-br ltz ca es sv tw
改成
LanguagePriority tw en da nl et fr de el it ja kr no pl pt pt-br ltz ca es sv
由於在/var/log裡會有這兩行出現,
Mar 19 08:39:54 mail postfix/smtpd[3344]: sql_select option missing
Mar 19 08:39:54 mail postfix/smtpd[3344]: auxpropfunc error no mechanism availabl
查了一下是說如果SQL plugin有安裝,預設執會去檢查sql_select這個選項,可以把SQL plugin 給移除掉或者加入dummy sql_select option,