MailScanner Installation Guide — MailScanner

My copy of MailScanner is installed under /opt/MailScanner so all references in the following text apply to that location. Note that version 3 usually installed into /opt/mailscanner so you should be able to leave the old version running on your system while you get the new version installed and configured.

Download the distribution and unpack it into the destination directory with a command such as

# cd /opt
# tar xvf MailScanner-4.01-1.tar
# ln -sf MailScanner-4.01-1 MailScanner

You will then need to check the paths for your particular system setup. Check the paths in each of these files:

/opt/MailScanner/bin/check_mailscanner
/opt/MailScanner/bin/MailScanner (just line 1)
/opt/MailScanner/lib/MailScanner/SystemDefs.pm
/opt/MailScanner/etc/virus.scanners.conf
/opt/MailScanner/etc/MailScanner.conf
/opt/MailScanner/lib/*

You should also compile the "tnef" binary for your system. The source code (and compiled versions for Solaris and Linux) are in the "bin" directory in the MailScanner tar file you downloaded. I advise you put the "tnef" program into somewhere such as /opt/MailScanner/bin/tnef. You will also need to check the MailScanner.conf file to ensure that the setting for "TNEF Expander" points to where you put the program.

The directories

    /var/spool/mqueue
    /var/spool/mqueue.in
must be in the same filesystem for MailScanner to work. If you are using Exim instead of sendmail, please see the Exim notes. Furthermore, the incoming and quarantine directories need to be writable by the "mail" user that Exim will be running as.

For extra reliability, I advise putting all the directories

    /var/spool/mqueue
    /var/spool/mqueue.in
    /var/spool/MailScanner/incoming
    /var/spool/MailScanner/quarantine
in the same filesystem. Then sendmail will ensure you don't run out of disk space, and handle the situation gracefully.

Configuration Options

These are all documented in a separate page of their own.

Starting it & Checking it

The check_mailscanner script mentioned above is used both to start it running and re-start it if it fails for some reason. It is best run as root by cron, a suitable crontab entry being

# 18/05/2000 JKF Ensure my e-mail virus scanner is still running
0,20,40 * * * * [ -x /opt/MailScanner/bin/check_mailscanner ] && /opt/MailScanner/bin/check_mailscanner >/dev/null 2>&1

Julian Field