LogWatchのメールのサイズがデカッ!

PostgreyとかAmavisとかをいれてメールサーバを動かしてると、LogWatchのPostfixの項目に「**Unmatched Entries**」が山ほどでてきて無駄に資源を使ってエコでないのでメモ
1通あたり10Mもあるのが何通も毎日送られてきた。。見てなかったけど(笑)

◆CentOS5のLogWatchの場合
デフォルトの定義(これは変更しない)

/usr/share/logwatch/default.conf/

オーバーライドするユーザ定義(こっちに追加する)

/etc/logwatch/

◆CentOS4のLogWatchの場合(ファイルを直接編集)

/etc/log.d/

例>CentOS5の場合でPostgreyのログを無視するようにしてみる。
postfixの定義をコピー

cd /etc/logwatch/conf/services
cp /usr/share/logwatch/default.conf/services/postfix.conf  ./

/etc/logwatch/conf/services/postfix.conf に以下を追記

*Remove = "NOQUEUE: reject: RCPT from "
*Remove = "^[A-Z0-9]*: reject: RCPT from "

Leave a Reply