星期五, 8月 18, 2006

Linux Boot process

This link is good for understanding the Linux boot up process
http://www.comptechdoc.org/os/linux/howlinuxworks/index.html

Redhat 9.x can not find the ETH0 in VMWare 4.x or 5.0

When booting the system, the eth0 can not be found. The following is the solution,

Find
/etc/sysconfig/network-scripts/ifcfg-eth
/etc/sysconfig/networking/devices/ifcfg-eth

And then edit the file
/etc/sysconfig/networking/profiles/default/ifcfg-eth0
add the following
check_link_down () {
return 1;
}

then reboot it. Execute "ifup eth0" does not work...it will show "/sbin/ifup: line 268: [: : integer expression expected" and I do not know why. But anyway, reboot will get the satisfied result.



Another article mentioned that

locate
/etc/sysconfig/network-scripts/network-functions

And then modify the function "check_link_down()"

check_link_down() {
return 1
:
:
}

Execute this command "service network restart" ------ not tried.

Redhat 8.0 is O.K.

星期四, 8月 17, 2006

無法送email

在linux server 上發生無法deliver mail的現象,原來是因為硬碟滿了,但是為什麼好端端的會造成硬碟爆炸呢? (用 du -h /var/spool/mqueue/ 檢查空間)

原來是在/root/.spamassassin累積了無數的bayes_tok.expire*檔案,這群垃圾是由Spamassassin生成的,據說解決方法是禁制 Bayes auto-expiry(spam.assassin.prefs.conf中可以設定)同時再於重新安排MailScanner中的Bayes時程(MailScanner.conf).

範例(尚未實驗),

- edit /etc/MailScanner/spam.assassin.prefs.conf
bayes_auto_expire 0

- edit /etc/MailScanner/MailScanner.conf:
SpamAssassin Timeout = 120
Rebuild Bayes Every = 14400 (秒為單位)
Wait During Bayes Rebuild = yes

- /etc/init.d/MailScanner stop
- sa-learn --sync
- /etc/init.d/MailScanner start





待續﹍