Тема: Spamassassin bayes_toks вырос до 3.5Gb
Проблема переросла в переполнение раздела диска. Выяснилось что причина в bayes_toks . Он "подрос" и почти 4Гб на жестком диске. Что делать.
Вывод sa-learn с опцией дебага -D:
#sa-learn -D --sync --force-expire
............
[21068] dbg: replacetags: done replacing tags
[21068] dbg: bayes: tie-ing to DB file R/O /usr/local/etc/mail/spamassassin/bayesdb/bayes_toks
[21068] dbg: bayes: tie-ing to DB file R/O /usr/local/etc/mail/spamassassin/bayesdb/bayes_seen
[21068] dbg: bayes: found bayes db version 3
[21068] dbg: bayes: DB journal sync: last sync: 1449036229
[21068] dbg: config: score set 3 chosen.
[21068] dbg: learn: initializing learner
[21068] dbg: bayes: bayes journal sync starting
[21068] dbg: bayes: bayes journal sync completed
[21068] dbg: bayes: expiry starting
[21068] dbg: locker: safe_lock: created /usr/local/etc/mail/spamassassin/bayesdb/bayes.lock.localhost.21068
[21068] dbg: locker: safe_lock: trying to get lock on /usr/local/etc/mail/spamassassin/bayesdb/bayes with 0 retries
[21068] dbg: locker: safe_lock: link to /usr/local/etc/mail/spamassassin/bayesdb/bayes.lock: link ok
[21068] dbg: bayes: tie-ing to DB file R/W /usr/local/etc/mail/spamassassin/bayesdb/bayes_toks
[21068] dbg: bayes: tie-ing to DB file R/W /usr/local/etc/mail/spamassassin/bayesdb/bayes_seen
[21068] dbg: bayes: found bayes db version 3
[21068] dbg: locker: refresh_lock: refresh /usr/local/etc/mail/spamassassin/bayesdb/bayes.lock
[21068] dbg: bayes: expiry check keep size, 0.75 * max: 112500
[21068] dbg: bayes: token count: 354985, final goal reduction size: 242485
[21068] dbg: bayes: first pass? current: 1449038813, Last: 1449038771, atime: 0, count: 0, newdelta: 0, ratio: 0, period: 43200
[21068] dbg: bayes: can't use estimation method for expiry, unexpected result, calculating optimal atime delta (first pass)
[21068] dbg: bayes: expiry max exponent: 9
[21068] dbg: bayes: atime token reduction
[21068] dbg: bayes: ======== ===============
[21068] dbg: bayes: 43200 354861
[21068] dbg: bayes: 86400 354630
[21068] dbg: bayes: 172800 354333
[21068] dbg: bayes: 345600 353428
[21068] dbg: bayes: 691200 351931
[21068] dbg: bayes: 1382400 351627
[21068] dbg: bayes: 2764800 346411
[21068] dbg: bayes: 5529600 335734
[21068] dbg: bayes: 11059200 327519
[21068] dbg: bayes: 22118400 306208
[21068] dbg: bayes: couldn't find a good delta atime, need more token difference, skipping expire
[21068] dbg: bayes: expiry completed
[21068] dbg: bayes: untie-ing
[21068] dbg: bayes: files locked, now unlocking lock
[21068] dbg: locker: safe_unlock: unlink /usr/local/etc/mail/spamassassin/bayesdb/bayes.lock
Добавлено: 02-12-2015 07:53:10
Настройки из бейса:
use_bayes 1
#use_dcc 0
bayes_auto_learn 0
bayes_auto_expire 1
bayes_path /usr/local/etc/mail/spamassassin/bayesdb/bayes
bayes_expiry_max_db_size 150000
bayes_journal_max_size 102400
bayes_file_mode 0666
bayes_auto_learn_threshold_nonspam 0.5
bayes_auto_learn_threshold_spam 5.0
Добавлено: 02-12-2015 08:01:52
Мне думается проблема где то здесь...
[22327] dbg: bayes: first pass? current: 1449039635, Last: 1449039057, atime: 0, count: 0, newdelta: 0, ratio: 0, period: 43200
[22327] dbg: bayes: can't use estimation method for expiry, unexpected result, calculating optimal atime delta (first pass)
Но что с ней делать?