Zimbra offers Open Source email server software and shared calendar for Linux and the Mac
Go Back   Zimbra :: Forums > Zimbra Collaboration Suite > Installation

Welcome to the Zimbra :: Forums!
Welcome, if you would like to post a comment please register. We also encourage you to explore all things Zimbra with our team and members of the community.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 03-10-2008, 06:20 PM
Senior Member
 
Posts: 72
Default How to install dspam in 5.0

Here is how I did it, for those of you wondering how to get dspam to work w/ 5.0

nano /opt/zimbra/conf/amavisd.conf.in

uncomment this line
#$dspam = '/opt/zimbra/dspam/bin/dspam';

Save

chown -R zimbra:zimbra /opt/zimbra/dspam-3.8.0


nano /opt/zimbra/bin/zmtrainsa

replace
for f in ${spamdir}/*; do
test -f ${f} && ${zimbra_home}/dspam/bin/dspam_corpus --addspam zimbra ${f}
done
for f in ${hamdir}/*; do
test -f ${f} && ${zimbra_home}/dspam/bin/dspam_corpus zimbra ${f}
done

with
${zimbra_home}/dspam/bin/dspam_train zimbra ${spamdir} ${hamdir}


That should do it....
Reply With Quote
  #2 (permalink)  
Old 03-11-2008, 06:58 AM
Senior Member
 
Posts: 71
Default

Great summary!

Additionally you should uncomment the Dspam cleanup lines in crontab.

crontab -e
Reply With Quote
  #3 (permalink)  
Old 03-11-2008, 07:21 AM
Zimbra Consultant & Moderator
 
Posts: 20,316
Default

..... and you also need the 'Feature Chained' changed to 'Tokenizer chain' in the dspam.conf.
__________________
Regards


Bill

Last edited by phoenix; 03-26-2008 at 04:35 AM..
Reply With Quote
  #4 (permalink)  
Old 03-11-2008, 07:53 AM
Senior Member
 
Posts: 71
Default

I looked at /opt/zimbra/bin/zmtrainsa and saw this lines:

Code:
  if [ x"$DSPAM" = "xenabled" ]; then
    timestampit "Starting dspam training"
        ${zimbra_home}/dspam/bin/dspam_train zimbra ${spamdir} ${hamdir}

    ${zimbra_home}/dspam/bin/dspam_clean -p0 $USER
    timestampit "Finished dspam training"
  fi

  if [ x"$DSPAM" = "xenabled" ]; then
    timestampit  "Starting dspam $MODE training for $USER using folder $FOLDER"
    if [ $MODE == "ham" ]; then
            MODE="innocent"
    fi

    ${zimbra_home}/dspam/bin/dspam --user zimbra --class=${MODE} --source=corpus --mode=teft \
      --feature=chained,noise --stdout

    ${zimbra_home}/dspam/bin/dspam_clean -p0 $USER
    timestampit  "Finished dspam $MODE training for $USER using folder $FOLDER"
  fi

Should $DSPAM be set to "enabled"? If yes where should I do it? In this file?
Reply With Quote
  #5 (permalink)  
Old 03-11-2008, 05:45 PM
Senior Member
 
Posts: 72
Default

Also found this in bugzilla

This problem still occurs in ZCA 5.x, relevant code from the zmfixperms script
is here:

if [ -L ${zimbra_home}/dspam ]; then
printMsg "Fixing ownership and permisions on ${zimbra_home}/dspam"
chown ${root_user}:${root_group} ${zimbra_home}/dspam-*
chown -R ${root_user}:${root_group} ${zimbra_home}/dspam/*
fi

ownership should be zimbra:zimbra for these directories/files.

This can be an annoying problem if you're doing a disaster recovery and apply
this script expecting that DSPAM to be working (obviously after enabling it in
current versions), unless you check the logs it can be easy to miss.

The corrected code for zmfizperms should be:

if [ -L ${zimbra_home}/dspam ]; then
printMsg "Fixing ownership and permisions on ${zimbra_home}/dspam"
chown ${zimbra_user}:${zimbra_group} ${zimbra_home}/dspam-*
chown -R ${zimbra_user}:${zimbra_group} ${zimbra_home}/dspam/*
fi
Reply With Quote
  #6 (permalink)  
Old 03-26-2008, 01:57 AM
jrh jrh is offline
Member
 
Posts: 11
Default

Shouldn't the last two lines in the crontab entry for log cleanup be the following instead?
Code:
/opt/zimbra/dspam/bin/dspam_logrotate -a 60 -l /opt/zimbra/dspam/var/dspam/system.log
/opt/zimbra/dspam/bin/dspam_logrotate -a 60 -d /opt/zimbra/dspam/var/dspam
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads

Why Join?

Registering let's you ask questions, makes it easier to search, displays any files attached to posts, and notifies you about replies.

blog.zimbra.com




 

SEO by vBSEO ©2011, Crawlability, Inc.